mirror of
https://github.com/rust-lang/rust-clippy
synced 2024-11-17 18:28:40 +00:00
24 lines
450 B
Rust
Executable file
24 lines
450 B
Rust
Executable file
#![feature(plugin)]
|
||
#![plugin(clippy)]
|
||
|
||
#[deny(zero_width_space)]
|
||
fn zero() {
|
||
print!("Here >< is a ZWS, and another");
|
||
//~^ ERROR zero-width space detected
|
||
}
|
||
|
||
#[deny(unicode_not_nfc)]
|
||
fn canon() {
|
||
print!("̀àh?"); //~ERROR non-nfc unicode sequence detected
|
||
}
|
||
|
||
#[deny(non_ascii_literal)]
|
||
fn uni() {
|
||
print!("Üben!"); //~ERROR literal non-ASCII character detected
|
||
}
|
||
|
||
fn main() {
|
||
zero();
|
||
uni();
|
||
canon();
|
||
}
|