Ungate the UNKNOWN_OR_MALFORMED_DIAGNOSTIC_ATTRIBUTES
lint
This was missed during stablisation of the `#[diagnostic]` attribute namespace. Fixes #122446
This commit is contained in:
parent
6f3eb1ce3d
commit
25411113c1
@ -4341,7 +4341,6 @@
|
|||||||
pub UNKNOWN_OR_MALFORMED_DIAGNOSTIC_ATTRIBUTES,
|
pub UNKNOWN_OR_MALFORMED_DIAGNOSTIC_ATTRIBUTES,
|
||||||
Warn,
|
Warn,
|
||||||
"unrecognized or malformed diagnostic attribute",
|
"unrecognized or malformed diagnostic attribute",
|
||||||
@feature_gate = sym::diagnostic_namespace;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
declare_lint! {
|
declare_lint! {
|
||||||
|
@ -0,0 +1,7 @@
|
|||||||
|
#![deny(unknown_or_malformed_diagnostic_attributes)]
|
||||||
|
|
||||||
|
#[diagnostic::unknown_attribute]
|
||||||
|
//~^ERROR unknown diagnostic attribute
|
||||||
|
struct Foo;
|
||||||
|
|
||||||
|
fn main() {}
|
@ -0,0 +1,14 @@
|
|||||||
|
error: unknown diagnostic attribute
|
||||||
|
--> $DIR/deny_malformed_attribute.rs:3:15
|
||||||
|
|
|
||||||
|
LL | #[diagnostic::unknown_attribute]
|
||||||
|
| ^^^^^^^^^^^^^^^^^
|
||||||
|
|
|
||||||
|
note: the lint level is defined here
|
||||||
|
--> $DIR/deny_malformed_attribute.rs:1:9
|
||||||
|
|
|
||||||
|
LL | #![deny(unknown_or_malformed_diagnostic_attributes)]
|
||||||
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||||
|
|
||||||
|
error: aborting due to 1 previous error
|
||||||
|
|
Loading…
Reference in New Issue
Block a user