Closed
Description
This is a passing Rust program:
fn plus_one(f: block() -> int) -> int {
ret f() + 1;
}
fn ret_plus_one() -> fn(block() -> int) -> int {
ret plus_one;
}
fn main() {
let z = (ret_plus_one()) {|| 2};
assert z == 3;
}
The pretty-printer omits the parens around the call in main, so the result of pretty-printing does not compile.