[−][src]Static rustc_lint::non_ascii_idents::NON_ASCII_IDENTS

pub static NON_ASCII_IDENTS: &Lint

The non_ascii_idents lint detects non-ASCII identifiers.

Example

ⓘThis example deliberately fails to compile
#![feature(non_ascii_idents)]
#![deny(non_ascii_idents)]
fn main() {
    let föö = 1;
}

{{produces}}

Explanation

Currently on stable Rust, identifiers must contain ASCII characters. The non_ascii_idents nightly-only feature allows identifiers to contain non-ASCII characters. This lint allows projects that wish to retain the limit of only using ASCII characters to switch this lint to "forbid" (for example to ease collaboration or for security reasons). See RFC 2457 for more details.