diff options
| author | bors <bors@rust-lang.org> | 2013-07-28 00:19:21 -0700 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2013-07-28 00:19:21 -0700 |
| commit | 20454da2db9903688dfd60b826cc704de79767bc (patch) | |
| tree | a20efcf40ca3c0473aca0b8c42383cd0bcf65ce1 /src/test/run-pass | |
| parent | 9325535b41fa5a7cfac697e86ae86bd1384542e6 (diff) | |
| parent | b147d70b08f93ea0a13a5331f413d547819b2f4c (diff) | |
auto merge of #8069 : erickt/rust/maikklein, r=erickt
Good evening, This is a superset of @MaikKlein's #7969 commit, that I've fixed up to compile. I had a couple commits I wanted to do on top of @MaikKlein's work that I didn't want to bitrot.
Diffstat (limited to 'src/test/run-pass')
| -rw-r--r-- | src/test/run-pass/cleanup-copy-mode.rs | 4 | ||||
| -rw-r--r-- | src/test/run-pass/issue-4016.rs | 3 |
2 files changed, 3 insertions, 4 deletions
diff --git a/src/test/run-pass/cleanup-copy-mode.rs b/src/test/run-pass/cleanup-copy-mode.rs index 2446e9057c2..45375efe9d6 100644 --- a/src/test/run-pass/cleanup-copy-mode.rs +++ b/src/test/run-pass/cleanup-copy-mode.rs @@ -16,7 +16,7 @@ use std::task; fn adder(x: @int, y: @int) -> int { return *x + *y; } fn failer() -> @int { fail!(); } pub fn main() { - assert!(result::is_err(&task::try(|| { + assert!(task::try(|| { adder(@2, failer()); () - }))); + }).is_err()); } diff --git a/src/test/run-pass/issue-4016.rs b/src/test/run-pass/issue-4016.rs index 6b0dd6cb947..c4178961d9e 100644 --- a/src/test/run-pass/issue-4016.rs +++ b/src/test/run-pass/issue-4016.rs @@ -11,14 +11,13 @@ extern mod extra; -use std::result; use extra::json; use extra::serialize::Decodable; trait JD : Decodable<json::Decoder> { } fn exec<T: JD>() { - let doc = result::unwrap(json::from_str("")); + let doc = json::from_str("").unwrap(); let mut decoder = json::Decoder(doc); let _v: T = Decodable::decode(&mut decoder); fail!() |
