Closed
Description
quote_expr!(self.cx, { $result_name = Some($expr); break $loop_label; })
failed with error: expected one of
.,
;,
}, or an operator, found
'__hoare_2``(__hoare_2
is the expected value of`$loop_label`). This failed in expansion so I couldn't get an expanded AST to find out what was going on.
The work around:
let stmts = vec![quote_stmt!(self.cx, $result_name = Some($expr);).unwrap(),
quote_stmt!(self.cx, break $loop_label;).unwrap()];
self.cx.expr_block(self.cx.block(stmts[0].span, stmts, None))
worked fine