//@ run-pass macro_rules! test { ( fn fun() -> Option>; ) => { fn fun(x: $t) -> Option> { Some(Box::new(x)) } } } test! { fn fun() -> Option>; } fn main() { println!("{}", fun(0).unwrap()); }