rustc_errors::diagnostic

Trait IntoDiagArg

Source
pub trait IntoDiagArg {
    // Required method
    fn into_diag_arg(self) -> DiagArgValue;
}
Expand description

Converts a value of a type into a DiagArg (typically a field of an Diag struct). Implemented as a custom trait rather than From so that it is implemented on the type being converted rather than on DiagArgValue, which enables types from other rustc_* crates to implement this.

Required Methods§

Implementations on Foreign Types§

Source§

impl IntoDiagArg for &TargetTuple

Source§

impl IntoDiagArg for ParamKindOrd

Source§

impl IntoDiagArg for TokenKind

Source§

impl IntoDiagArg for Namespace

Source§

impl IntoDiagArg for ConstContext

Source§

impl IntoDiagArg for Target

Source§

impl IntoDiagArg for Level

Source§

impl IntoDiagArg for Edition

Source§

impl IntoDiagArg for PanicStrategy

Source§

impl IntoDiagArg for SplitDebuginfo

Source§

impl IntoDiagArg for StackProtector

Source§

impl IntoDiagArg for ClosureKind

Source§

impl IntoDiagArg for FloatTy

Source§

impl IntoDiagArg for bool

Source§

impl IntoDiagArg for char

Source§

impl IntoDiagArg for i8

Source§

impl IntoDiagArg for i16

Source§

impl IntoDiagArg for i32

Source§

impl IntoDiagArg for i64

Source§

impl IntoDiagArg for i128

Source§

impl IntoDiagArg for isize

Source§

impl IntoDiagArg for u8

Source§

impl IntoDiagArg for u16

Source§

impl IntoDiagArg for u32

Source§

impl IntoDiagArg for u64

Source§

impl IntoDiagArg for u128

Source§

impl IntoDiagArg for usize

Source§

impl IntoDiagArg for Expr

Source§

impl IntoDiagArg for Path

Source§

impl IntoDiagArg for Visibility

Source§

impl IntoDiagArg for Token

Source§

impl IntoDiagArg for SmallCStr

Source§

impl IntoDiagArg for Ident

Source§

impl IntoDiagArg for MacroRulesNormalizedIdent

Source§

impl IntoDiagArg for Symbol

Source§

impl IntoDiagArg for Box<dyn Error>

Source§

impl IntoDiagArg for CString

Source§

impl IntoDiagArg for String

Source§

impl IntoDiagArg for Vec<char>

Source§

impl IntoDiagArg for ParseIntError

Source§

impl IntoDiagArg for NonZero<u32>

Source§

impl IntoDiagArg for Backtrace

Source§

impl IntoDiagArg for Error

Source§

impl IntoDiagArg for PathBuf

Source§

impl IntoDiagArg for ExitStatus

Source§

impl<'a> IntoDiagArg for &'a str

Source§

impl<'a> IntoDiagArg for &'a Path

Source§

impl<'a> IntoDiagArg for Cow<'a, str>

Source§

impl<'a, T: Clone + IntoDiagArg> IntoDiagArg for &'a T

Source§

impl<I: Interner> IntoDiagArg for UnevaluatedConst<I>

Source§

impl<I: Interner> IntoDiagArg for ExistentialTraitRef<I>

Source§

impl<I: Interner> IntoDiagArg for TraitRef<I>

Source§

impl<I: Interner> IntoDiagArg for FnSig<I>

Source§

impl<I: Interner, T> IntoDiagArg for Binder<I, T>
where T: IntoDiagArg,

Source§

impl<Id> IntoDiagArg for Res<Id>

Implementors§