Skip to content

Commit 02faee6

Browse files
authored
Rollup merge of #146781 - joshtriplett:mbe-derive-fix-feature-gate, r=wesleywiser
mbe: Fix feature gate for `macro_derive`
2 parents dc3c62a + 3ab89ab commit 02faee6

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

compiler/rustc_expand/src/mbe/macro_rules.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -702,7 +702,7 @@ pub fn compile_declarative_macro(
702702
kinds |= MacroKinds::DERIVE;
703703
let derive_keyword_span = p.prev_token.span;
704704
if !features.macro_derive() {
705-
feature_err(sess, sym::macro_attr, span, "`macro_rules!` derives are unstable")
705+
feature_err(sess, sym::macro_derive, span, "`macro_rules!` derives are unstable")
706706
.emit();
707707
}
708708
if let Some(guar) = check_no_eof(sess, &p, "expected `()` after `derive`") {

tests/ui/feature-gates/feature-gate-macro-derive.stderr

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@ error[E0658]: `macro_rules!` derives are unstable
44
LL | macro_rules! MyDerive { derive() {} => {} }
55
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
66
|
7-
= note: see issue #83527 <https://github.com/rust-lang/rust/issues/83527> for more information
8-
= help: add `#![feature(macro_attr)]` to the crate attributes to enable
7+
= note: see issue #143549 <https://github.com/rust-lang/rust/issues/143549> for more information
8+
= help: add `#![feature(macro_derive)]` to the crate attributes to enable
99
= note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
1010

1111
error: aborting due to 1 previous error

0 commit comments

Comments
 (0)