]> git.lizzy.rs Git - rust.git/blob - tests/ui/lint/lint-group-nonstandard-style.rs
Auto merge of #106884 - clubby789:fieldless-enum-debug, r=michaelwoerister
[rust.git] / tests / ui / lint / lint-group-nonstandard-style.rs
1 #![deny(nonstandard_style)]
2 #![allow(dead_code)]
3
4 fn CamelCase() {} //~ ERROR should have a snake
5
6 #[allow(nonstandard_style)]
7 mod test {
8     fn CamelCase() {}
9
10     #[forbid(nonstandard_style)]
11     mod bad {
12         fn CamelCase() {} //~ ERROR should have a snake
13
14         static bad: isize = 1; //~ ERROR should have an upper
15     }
16
17     mod warn {
18         #![warn(nonstandard_style)]
19
20         fn CamelCase() {} //~ WARN should have a snake
21
22         struct snake_case; //~ WARN should have an upper camel
23     }
24 }
25
26 fn main() {}