diff options
| author | bors <bors@rust-lang.org> | 2022-08-20 10:26:54 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2022-08-20 10:26:54 +0000 |
| commit | dd01122b5c62a04e64b4109c5576eeea9ae4145b (patch) | |
| tree | 4ccafcd2b6bc8eb482472acf34022d2dd4b83679 /compiler/rustc_builtin_macros/src | |
| parent | 36e530cb08950f1d03ab733e43ecec2802d099cf (diff) | |
| parent | eafd0dfd05cca581d66d83aab9549612ba2ed543 (diff) | |
| download | rust-dd01122b5c62a04e64b4109c5576eeea9ae4145b.tar.gz rust-dd01122b5c62a04e64b4109c5576eeea9ae4145b.zip | |
Auto merge of #100564 - nnethercote:box-ast-MacCall, r=spastorino
Box the `MacCall` in various types. r? `@spastorino`
Diffstat (limited to 'compiler/rustc_builtin_macros/src')
| -rw-r--r-- | compiler/rustc_builtin_macros/src/assert.rs | 4 | ||||
| -rw-r--r-- | compiler/rustc_builtin_macros/src/assert/context.rs | 4 | ||||
| -rw-r--r-- | compiler/rustc_builtin_macros/src/edition_panic.rs | 4 |
3 files changed, 6 insertions, 6 deletions
diff --git a/compiler/rustc_builtin_macros/src/assert.rs b/compiler/rustc_builtin_macros/src/assert.rs index 925c36edb51..119724b5049 100644 --- a/compiler/rustc_builtin_macros/src/assert.rs +++ b/compiler/rustc_builtin_macros/src/assert.rs @@ -52,7 +52,7 @@ pub fn expand_assert<'cx>( let expr = if let Some(tokens) = custom_message { let then = cx.expr( call_site_span, - ExprKind::MacCall(MacCall { + ExprKind::MacCall(P(MacCall { path: panic_path(), args: P(MacArgs::Delimited( DelimSpan::from_single(call_site_span), @@ -60,7 +60,7 @@ pub fn expand_assert<'cx>( tokens, )), prior_type_ascription: None, - }), + })), ); expr_if_not(cx, call_site_span, cond_expr, then, None) } diff --git a/compiler/rustc_builtin_macros/src/assert/context.rs b/compiler/rustc_builtin_macros/src/assert/context.rs index c04d04020cc..d30fd479015 100644 --- a/compiler/rustc_builtin_macros/src/assert/context.rs +++ b/compiler/rustc_builtin_macros/src/assert/context.rs @@ -177,7 +177,7 @@ impl<'cx, 'a> Context<'cx, 'a> { }); self.cx.expr( self.span, - ExprKind::MacCall(MacCall { + ExprKind::MacCall(P(MacCall { path: panic_path, args: P(MacArgs::Delimited( DelimSpan::from_single(self.span), @@ -185,7 +185,7 @@ impl<'cx, 'a> Context<'cx, 'a> { initial.into_iter().chain(captures).collect::<TokenStream>(), )), prior_type_ascription: None, - }), + })), ) } diff --git a/compiler/rustc_builtin_macros/src/edition_panic.rs b/compiler/rustc_builtin_macros/src/edition_panic.rs index ea0e768a58f..3f1a8b3bc2c 100644 --- a/compiler/rustc_builtin_macros/src/edition_panic.rs +++ b/compiler/rustc_builtin_macros/src/edition_panic.rs @@ -48,7 +48,7 @@ fn expand<'cx>( MacEager::expr( cx.expr( sp, - ExprKind::MacCall(MacCall { + ExprKind::MacCall(P(MacCall { path: Path { span: sp, segments: cx @@ -64,7 +64,7 @@ fn expand<'cx>( tts, )), prior_type_ascription: None, - }), + })), ), ) } |
