mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-27 01:04:03 +00:00
27 lines
527 B
Rust
27 lines
527 B
Rust
#![deny(nonstandard_style)]
|
|
#![allow(dead_code)]
|
|
|
|
fn CamelCase() {} //~ ERROR should have a snake
|
|
|
|
#[allow(nonstandard_style)]
|
|
mod test {
|
|
fn CamelCase() {}
|
|
|
|
#[forbid(nonstandard_style)]
|
|
mod bad {
|
|
fn CamelCase() {} //~ ERROR should have a snake
|
|
|
|
static bad: isize = 1; //~ ERROR should have an upper
|
|
}
|
|
|
|
mod warn {
|
|
#![warn(nonstandard_style)]
|
|
|
|
fn CamelCase() {} //~ WARN should have a snake
|
|
|
|
struct snake_case; //~ WARN should have an upper camel
|
|
}
|
|
}
|
|
|
|
fn main() {}
|