diff --git a/src/test/run-pass/fn-pattern-expected-type.rs b/src/test/run-pass/fn-pattern-expected-type.rs new file mode 100644 index 00000000000..7041878234f --- /dev/null +++ b/src/test/run-pass/fn-pattern-expected-type.rs @@ -0,0 +1,8 @@ +fn main() { + let f: fn((int,int)) = |(x, y)| { + assert x == 1; + assert y == 2; + }; + f((1, 2)); +} +