Function rustc::middle::typeck::collect::instantiate_trait_ref[src]
pub fn instantiate_trait_ref(ccx: &CrateCtxt, ast_trait_ref: &TraitRef, self_ty: t) -> Rc<TraitRef>
Instantiates the path for the given trait reference, assuming that it's bound to a valid trait type. Returns the def_id for the defining trait. Fails if the type is a type other than a trait type.