rustc: Remove matching on ~str from the language

The `~str` type is not long for this world as it will be superseded by the
soon-to-come DST changes for the language. The new type will be
`~Str`, and matching over the allocation will no longer be supported.
Matching on `&str` will continue to work, in both a pre and post DST world.
This commit is contained in:
Michael Darakananda
2014-03-07 16:15:50 -05:00
parent 3316a0e6b2
commit f079c94f72
17 changed files with 57 additions and 110 deletions

View File

@@ -387,8 +387,8 @@ fn test_back_to_the_future_result() {
fn test_try_success() {
match try(proc() {
~"Success!"
}) {
result::Ok(~"Success!") => (),
}).as_ref().map(|s| s.as_slice()) {
result::Ok("Success!") => (),
_ => fail!()
}
}