pub struct Specs {
pub(crate) items: UnordMap<OwnerId, Item>,
pub(crate) trait_items: UnordMap<OwnerId, TraitItemFn>,
pub(crate) impl_items: UnordMap<OwnerId, ImplItemFn>,
pub flux_items_by_parent: FxIndexMap<OwnerId, Vec<FluxItem>>,
pub(crate) dummy_extern: UnordSet<LocalDefId>,
pub(crate) extern_id_to_local_id: UnordMap<DefId, LocalDefId>,
pub(crate) local_id_to_extern_id: UnordMap<LocalDefId, DefId>,
}
Fields§
§items: UnordMap<OwnerId, Item>
§trait_items: UnordMap<OwnerId, TraitItemFn>
§impl_items: UnordMap<OwnerId, ImplItemFn>
§flux_items_by_parent: FxIndexMap<OwnerId, Vec<FluxItem>>
§dummy_extern: UnordSet<LocalDefId>
Set of dummy items generated by the extern spec macro we must completely ignore. This is not the same as ignored items because, for ignored items, we still need to return errors for queries and handle them gracefully in order to report them at the use it.
If an item is in this set, all its descendants are also consider dummy (but they may not be in the set).
extern_id_to_local_id: UnordMap<DefId, LocalDefId>
§local_id_to_extern_id: UnordMap<LocalDefId, DefId>
Implementations§
Source§impl Specs
impl Specs
pub fn insert_extern_spec_id_mapping( &mut self, local_id: LocalDefId, extern_id: DefId, ) -> Result<(), ExternSpecMappingErr>
pub fn insert_dummy(&mut self, def_id: LocalDefId)
pub fn get_item(&self, owner_id: OwnerId) -> Option<&Item>
pub fn insert_item(&mut self, owner_id: OwnerId, item: Item) -> Option<Item>
pub fn get_trait_item(&self, owner_id: OwnerId) -> Option<&TraitItemFn>
pub fn insert_trait_item( &mut self, owner_id: OwnerId, trait_item: TraitItemFn, ) -> Option<TraitItemFn>
pub fn get_impl_item(&self, owner_id: OwnerId) -> Option<&ImplItemFn>
pub fn insert_impl_item( &mut self, owner_id: OwnerId, impl_item: ImplItemFn, ) -> Option<ImplItemFn>
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Specs
impl RefUnwindSafe for Specs
impl Send for Specs
impl Sync for Specs
impl Unpin for Specs
impl UnwindSafe for Specs
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more