Function rustc_middle::ty::elaborate::supertrait_def_ids

source ยท
pub fn supertrait_def_ids<I>(
    cx: I,
    trait_def_id: <I as Interner>::DefId,
) -> impl Iterator<Item = <I as Interner>::DefId>
where I: Interner,
Expand description

Computes the def-ids of the transitive supertraits of trait_def_id. This (intentionally) does not compute the full elaborated super-predicates but just the set of def-ids. It is used to identify which traits may define a given associated type to help avoid cycle errors, and to make size estimates for vtable layout computation.