LL | #[non_exhaustive(anything)]
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: must be of the form: `#[non_exhaustive]`
-error[E0701]: attribute can only be applied to a struct or enum
+error[E0701]: attribute should be applied to a struct or enum
--> $DIR/invalid-attribute.rs:5:1
|
LL | #[non_exhaustive]
LL | trait Bar { }
| ------------- not a struct or enum
-error[E0701]: attribute can only be applied to a struct or enum
+error[E0701]: attribute should be applied to a struct or enum
--> $DIR/invalid-attribute.rs:9:1
|
LL | #[non_exhaustive]