Skip to content

Commit 0b67d14

Browse files
Fix #[rustc_macro_transparency] giving two errors
Signed-off-by: Jonathan Brouwer <jonathantbrouwer@gmail.com>
1 parent 149bdde commit 0b67d14

File tree

3 files changed

+69
-75
lines changed

3 files changed

+69
-75
lines changed

compiler/rustc_parse/src/validate_attr.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -304,6 +304,7 @@ fn emit_malformed_attribute(
304304
| sym::track_caller
305305
| sym::link_name
306306
| sym::export_name
307+
| sym::rustc_macro_transparency
307308
) {
308309
return;
309310
}

tests/ui/attributes/malformed-attrs.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,6 @@
4444
//~| WARN this was previously accepted by the compiler
4545
#[rustc_macro_transparency]
4646
//~^ ERROR malformed
47-
//~| ERROR malformed
4847
#[repr]
4948
//~^ ERROR malformed
5049
#[rustc_as_ptr = 5]

0 commit comments

Comments
 (0)