rust/tests/ui/expr/block-fn.rs

10 lines
142 B
Rust
Raw Normal View History

//@ run-pass
fn test_fn() {
fn ten() -> isize { return 10; }
2015-01-02 22:32:54 +00:00
let rs = ten;
assert_eq!(rs(), 10);
}
pub fn main() { test_fn(); }