Function rustc_trait_selection::traits::object_safety::object_ty_for_trait
source · [−]fn object_ty_for_trait<'tcx>(
tcx: TyCtxt<'tcx>,
trait_def_id: DefId,
lifetime: Region<'tcx>
) -> Ty<'tcx>
Expand description
Creates the object type for the current trait. For example,
if the current trait is Deref
, then this will be
dyn Deref<Target = Self::Target> + 'static
.