collect_opaque_types

Function collect_opaque_types 

Source
fn collect_opaque_types(
    genv: GlobalEnv<'_, '_>,
    owner_id: MaybeExternId<OwnerId>,
) -> Result<Option<LocalDefId>, ErrorGuaranteed>
Expand description

Traverses the hir for an item and collects the def_id of any opaque type (i.e., impl Trait or async) Currently, we only support up to one opaque type and we report an error if there’s more than one.