Struct rustc_trans::lint::Lint
[−]
[src]
pub struct Lint { pub name: &'static str, pub default_level: Level, pub desc: &'static str, }
rustc_private
)Specification of a single lint.
Fields
name: &'static str
rustc_private
)A string identifier for the lint.
This identifies the lint in attributes and in command-line arguments.
In those contexts it is always lowercase, but this field is compared
in a way which is case-insensitive for ASCII characters. This allows
declare_lint!()
invocations to follow the convention of upper-case
statics without repeating the name.
The name is written with underscores, e.g. "unused_imports". On the command line, underscores become dashes.
default_level: Level
rustc_private
)Default level for the lint.
desc: &'static str
rustc_private
)Description of the lint or the issue it detects.
e.g. "imports that are never used"
Methods
impl Lint
fn name_lower(&self) -> String
[−]
rustc_private
)Get the lint's name, with ASCII letters converted to lowercase.
Trait Implementations
Derived Implementations
impl Debug for Lint
fn fmt(&self, __arg_0: &mut Formatter) -> Result<(), Error>
[−]
Formats the value using the given formatter.
impl Clone for Lint
fn clone(&self) -> Lint
[−]
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[−]
Performs copy-assignment from source
. Read more