[−][src]Enum rustc_middle::lint::LintSource

pub enum LintSource {
    Default,
    Node(Symbol, Span, Option<Symbol>),
    CommandLine(Symbol, Level),
}

How a lint level was set.

Variants

Default

Lint is at the default level as declared in rustc or a plugin.

Node(Symbol, Span, Option<Symbol>)

Lint level was set by an attribute.

CommandLine(Symbol, Level)

Lint level was set by a command-line flag. The provided Level is the level specified on the command line - the actual level may be lower due to --cap-lints

Implementations

impl LintSource[src]

pub fn name(&self) -> Symbol[src]

pub fn span(&self) -> Span[src]

Trait Implementations

impl Clone for LintSource[src]

impl Copy for LintSource[src]

impl Eq for LintSource[src]

impl<'__ctx> HashStable<StableHashingContext<'__ctx>> for LintSource[src]

impl PartialEq<LintSource> for LintSource[src]

impl StructuralEq for LintSource[src]

impl StructuralPartialEq for LintSource[src]

Auto Trait Implementations

impl RefUnwindSafe for LintSource

impl !Send for LintSource

impl !Sync for LintSource

impl Unpin for LintSource

impl UnwindSafe for LintSource

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized, 
[src]

impl<'tcx, T> ArenaAllocatable<'tcx, ()> for T where
    T: Copy, 
[src]

impl<T> Borrow<T> for T where
    T: ?Sized, 
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized, 
[src]

impl<'a, T> Captures<'a> for T where
    T: ?Sized, 
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> MaybeResult<T> for T[src]

type Error = !

impl<T> ToOwned for T where
    T: Clone, 
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> WithConstness for T[src]