rust/src/test/run-pass/macro-2.rs
2011-07-27 15:54:33 +02:00

7 lines
138 B
Rust

// xfail-stage0
fn main() {
#macro([#mylambda(x,body), {fn f(x: int) -> int { ret body }; f}]);
assert(#mylambda(y,y*2)(8) == 16);
}