diff --git a/compiler/rustc_parse/src/parser/item.rs b/compiler/rustc_parse/src/parser/item.rs index d2fea5583b8..994e7c5d2db 100644 --- a/compiler/rustc_parse/src/parser/item.rs +++ b/compiler/rustc_parse/src/parser/item.rs @@ -128,14 +128,10 @@ pub(super) fn parse_item_common( Some(item.into_inner()) }); - let item = - self.collect_tokens_trailing_token(attrs, force_collect, |this: &mut Self, attrs| { - let item = - this.parse_item_common_(attrs, mac_allowed, attrs_allowed, fn_parse_mode); - Ok((item?, TrailingToken::None)) - })?; - - Ok(item) + self.collect_tokens_trailing_token(attrs, force_collect, |this, attrs| { + let item = this.parse_item_common_(attrs, mac_allowed, attrs_allowed, fn_parse_mode)?; + Ok((item, TrailingToken::None)) + }) } fn parse_item_common_(