Struct rustc::middle::ty::TraitDefExperimental [-]  [+] [src]

pub struct TraitDef<'tcx> {
    pub generics: Generics<'tcx>,
    pub bounds: ParamBounds<'tcx>,
    pub trait_ref: Rc<TraitRef<'tcx>>,
}

As Polytype but for a trait ref.

Fields

generics

Generic type definitions. Note that Self is listed in here as having a single bound, the trait itself (e.g., in the trait Eq, there is a single bound Self : Eq). This is so that default methods get to assume that the Self parameters implements the trait.

bounds

The "supertrait" bounds.

trait_ref

Trait Implementations

impl<'tcx> Repr<'tcx> for TraitDef<'tcx>

fn repr(&self, tcx: &ctxt<'tcx>) -> String