2011-07-13 18:46:50 -07:00
|
|
|
// xfail-stage0
|
2011-07-21 16:47:47 -07:00
|
|
|
//error-pattern:is an expr, expected an identifier
|
2011-06-20 17:26:17 -07:00
|
|
|
fn main() {
|
2011-07-27 14:48:34 +02:00
|
|
|
#macro([#mylambda(x, body), {fn f(x: int) -> int {ret body}; f}]);
|
2011-07-13 15:44:09 -07:00
|
|
|
|
2011-07-27 14:48:34 +02:00
|
|
|
assert(#mylambda(y*1, y*2)(8) == 16);
|
2011-06-20 17:26:17 -07:00
|
|
|
}
|