syn
syn copied to clipboard
Consider adding a Stmt::Macro variant
In something like:
fn main() {
thread_local! { static FOO: i32 = 1; }
println! { "{}", FOO.with(i32::clone) }
}
it's syntactically ambiguous whether the macros represent an expression or an item. Currently this syntax is arbitrarily disambiguated to Stmt::Item by syn (as opposed to Stmt::Expr) but perhaps it would be clearer not to do that so arbitrarily.