rust/src/test/run-pass/closure-inference2.rs
2012-02-05 10:37:07 -08:00

8 lines
121 B
Rust

// Test a rather underspecified example:
fn main() {
let f = {|i| i};
assert f(2) == 2;
assert f(5) == 5;
}