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); }