fork/rust
git clone https://git.julia.blue/fork/rust
3bcad65fbf6
master
1error: expected `{`, found `foo` 2 --> $DIR/issue-39848.rs:3:21 3 | 4LL | if $tgt.has_$field() {} 5 | ^^^^^^ expected `{` 6... 7LL | get_opt!(bar, foo); 8 | ------------------ in this macro invocation 9 | 10note: the `if` expression is missing a block after this condition 11 --> $DIR/issue-39848.rs:3:12 12 | 13LL | if $tgt.has_$field() {} 14 | ^^^^^^^^^ 15... 16LL | get_opt!(bar, foo); 17 | ------------------ in this macro invocation 18 = note: this error originates in the macro `get_opt` (in Nightly builds, run with -Z macro-backtrace for more info) 19help: try placing this code inside a block 20 | 21LL | if $tgt.has_{ $field() } {} 22 | + + 23 24error: aborting due to previous error 25