mirror of
https://github.com/rust-lang/rust.git
synced 2024-12-09 15:13:57 +00:00
Do not set inside_macro flag when converting try!() to '?'
This will keep rustfmt idempotent when using 'use_try_shorthand' config option.
This commit is contained in:
parent
42726906f7
commit
90383d7426
@ -118,6 +118,7 @@ pub fn rewrite_macro(
|
||||
context.inside_macro = true;
|
||||
if context.config.use_try_shorthand() {
|
||||
if let Some(expr) = convert_try_mac(mac, context) {
|
||||
context.inside_macro = false;
|
||||
return expr.rewrite(context, shape);
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user