diff options
| author | Jorge Aparicio <japaricious@gmail.com> | 2015-01-05 16:02:07 -0500 |
|---|---|---|
| committer | Jorge Aparicio <japaricious@gmail.com> | 2015-01-05 17:22:18 -0500 |
| commit | a55011e788e3523cc37c1fca47fc334a74682369 (patch) | |
| tree | 96fbfbbf3e28cbc2e131a3c157ba242ae804d81c | |
| parent | ec11f66dbf68c7d0a958b28e520f547c885a3fde (diff) | |
| download | rust-a55011e788e3523cc37c1fca47fc334a74682369.tar.gz rust-a55011e788e3523cc37c1fca47fc334a74682369.zip | |
fix tests
| -rw-r--r-- | src/test/compile-fail/unboxed-closures-type-mismatch.rs | 2 | ||||
| -rw-r--r-- | src/test/run-pass/overloaded-calls-object-zero-args.rs | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/src/test/compile-fail/unboxed-closures-type-mismatch.rs b/src/test/compile-fail/unboxed-closures-type-mismatch.rs index a25d6464867..61f13172832 100644 --- a/src/test/compile-fail/unboxed-closures-type-mismatch.rs +++ b/src/test/compile-fail/unboxed-closures-type-mismatch.rs @@ -14,6 +14,6 @@ use std::ops::FnMut; pub fn main() { let mut f = |&mut: x: int, y: int| -> int { x + y }; - let z = f(1u, 2); //~ ERROR type mismatch + let z = f(1u, 2); //~ ERROR mismatched types println!("{}", z); } diff --git a/src/test/run-pass/overloaded-calls-object-zero-args.rs b/src/test/run-pass/overloaded-calls-object-zero-args.rs index 442df1e664c..b38f8213b4a 100644 --- a/src/test/run-pass/overloaded-calls-object-zero-args.rs +++ b/src/test/run-pass/overloaded-calls-object-zero-args.rs @@ -11,11 +11,11 @@ // Tests calls to closure arguments where the closure takes 0 arguments. // This is a bit tricky due to rust-call ABI. -fn foo(f: &mut FnMut()) -> int { +fn foo(f: &mut FnMut() -> int) -> int { f() } fn main() { - let z = foo(|| 22); + let z = foo(&mut || 22); assert_eq!(z, 22); } |
