]> git.lizzy.rs Git - rust.git/blob - compiler/rustc_error_codes/src/error_codes/E0452.md
Rollup merge of #93556 - dtolnay:trailingcomma, r=cjgillot
[rust.git] / compiler / rustc_error_codes / src / error_codes / E0452.md
1 An invalid lint attribute has been given.
2
3 Erroneous code example:
4
5 ```compile_fail,E0452
6 #![allow(foo = "")] // error: malformed lint attribute
7 ```
8
9 Lint attributes only accept a list of identifiers (where each identifier is a
10 lint name). Ensure the attribute is of this form:
11
12 ```
13 #![allow(foo)] // ok!
14 // or:
15 #![allow(foo, foo2)] // ok!
16 ```