hir_def::src

Trait HasChildSource

Source
pub trait HasChildSource<ChildId> {
    type Value;

    // Required method
    fn child_source(
        &self,
        db: &dyn DefDatabase,
    ) -> InFile<ArenaMap<ChildId, Self::Value>>;
}

Required Associated Types§

Required Methods§

Source

fn child_source( &self, db: &dyn DefDatabase, ) -> InFile<ArenaMap<ChildId, Self::Value>>

Implementors§

Source§

impl HasChildSource<Idx<TypeOrConstParamData>> for GenericDefId

Source§

type Value = Either<TypeOrConstParam, TraitOrAlias>

Source§

impl HasChildSource<Idx<FieldData>> for VariantId

Source§

type Value = Either<TupleField, RecordField>

Source§

impl HasChildSource<Idx<LifetimeParamData>> for GenericDefId

Source§

type Value = LifetimeParam

Source§

impl HasChildSource<Idx<UseTree>> for UseId

Source§

type Value = UseTree