[−][src]Enum rustc_mir::borrow_check::diagnostics::region_name::RegionNameHighlight

pub(crate) enum RegionNameHighlight {
    MatchedHirTy(Span),
    MatchedAdtAndSegment(Span),
    CannotMatchHirTy(Span, String),
}

Describes what to highlight to explain to the user that we're giving an anonymous region a synthesized name, and how to highlight it.

Variants

MatchedHirTy(Span)

The anonymous region corresponds to a reference that was found by traversing the type in the HIR.

MatchedAdtAndSegment(Span)

The anonymous region corresponds to a '_ in the generics list of a struct/enum/union.

CannotMatchHirTy(Span, String)

The anonymous region corresponds to a region where the type annotation is completely missing from the code, e.g. in a closure arguments |x| { ... }, where x is a reference.

Trait Implementations

impl Clone for RegionNameHighlight[src]

impl Debug for RegionNameHighlight[src]

Auto Trait Implementations

impl RefUnwindSafe for RegionNameHighlight

impl !Send for RegionNameHighlight

impl !Sync for RegionNameHighlight

impl Unpin for RegionNameHighlight

impl UnwindSafe for RegionNameHighlight

Blanket Implementations

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

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

impl<T> BorrowMut<T> 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> 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]