Struct RootDatabase
pub struct RootDatabase { /* private fields */ }
Implementations§
§impl RootDatabase
impl RootDatabase
pub fn request_cancellation(&mut self)
pub fn apply_change(&mut self, change: ChangeWithProcMacros)
pub fn per_query_memory_usage(&mut self) -> Vec<(String, Bytes, usize)>
§impl RootDatabase
impl RootDatabase
pub fn new(lru_capacity: Option<u16>) -> RootDatabase
pub fn enable_proc_attr_macros(&mut self)
pub fn update_base_query_lru_capacities(&mut self, _lru_capacity: Option<u16>)
pub fn update_lru_capacities( &mut self, _lru_capacities: &HashMap<Box<str>, u16, FxBuildHasher>, )
Trait Implementations§
§impl Clone for RootDatabase
impl Clone for RootDatabase
§fn clone(&self) -> RootDatabase
fn clone(&self) -> RootDatabase
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read more§impl Database for RootDatabase
impl Database for RootDatabase
§fn salsa_event(&self, _event: &dyn Fn() -> Event)
fn salsa_event(&self, _event: &dyn Fn() -> Event)
This function is invoked by the salsa runtime at various points during execution.
You can customize what happens by implementing the [
UserData
][] trait.
By default, the event is logged at level debug using tracing facade. Read more§fn trigger_lru_eviction(&mut self)
fn trigger_lru_eviction(&mut self)
Enforces current LRU limits, evicting entries if necessary. Read more
§fn synthetic_write(&mut self, durability: Durability)
fn synthetic_write(&mut self, durability: Durability)
A “synthetic write” causes the system to act as though some
input of durability
durability
has changed, triggering a new revision.
This is mostly useful for profiling scenarios. Read more§fn report_untracked_read(&self)
fn report_untracked_read(&self)
Reports that the query depends on some state unknown to salsa. Read more
§fn ingredient_debug_name(
&self,
ingredient_index: IngredientIndex,
) -> Cow<'_, str>
fn ingredient_debug_name( &self, ingredient_index: IngredientIndex, ) -> Cow<'_, str>
Return the “debug name” (i.e., the struct name, etc) for an “ingredient”,
which are the fine-grained components we use to track data. This is intended
for debugging and the contents of the returned string are not semver-guaranteed. Read more
§fn unwind_if_revision_cancelled(&self)
fn unwind_if_revision_cancelled(&self)
Starts unwinding the stack if the current revision is cancelled. Read more
§impl Debug for RootDatabase
impl Debug for RootDatabase
§impl Default for RootDatabase
impl Default for RootDatabase
§fn default() -> RootDatabase
fn default() -> RootDatabase
Returns the “default value” for a type. Read more
§impl SourceDatabase for RootDatabase
impl SourceDatabase for RootDatabase
§fn source_root(&self, source_root_id: SourceRootId) -> SourceRootInput
fn source_root(&self, source_root_id: SourceRootId) -> SourceRootInput
Source root of the file.
fn set_file_text(&mut self, file_id: FileId, text: &str)
fn set_file_text_with_durability( &mut self, file_id: FileId, text: &str, durability: Durability, )
§fn set_source_root_with_durability(
&mut self,
source_root_id: SourceRootId,
source_root: Arc<SourceRoot>,
durability: Durability,
)
fn set_source_root_with_durability( &mut self, source_root_id: SourceRootId, source_root: Arc<SourceRoot>, durability: Durability, )
Source root of the file.
fn file_source_root(&self, id: FileId) -> FileSourceRootInput
fn set_file_source_root_with_durability( &mut self, id: FileId, source_root_id: SourceRootId, durability: Durability, )
fn resolve_path(&self, path: AnchoredPath<'_>) -> Option<FileId>
impl RefUnwindSafe for RootDatabase
Auto Trait Implementations§
impl !Freeze for RootDatabase
impl Send for RootDatabase
impl !Sync for RootDatabase
impl Unpin for RootDatabase
impl !UnwindSafe for RootDatabase
Blanket Implementations§
§impl<T> AsDynDatabase for Twhere
T: Database,
impl<T> AsDynDatabase for Twhere
T: Database,
fn as_dyn_database(&self) -> &(dyn Database + 'static)
fn as_dyn_database_mut(&mut self) -> &mut (dyn Database + 'static)
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> Cast for T
impl<T> Cast for T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<DB> DefDatabase for DBwhere
DB: InternDatabase + ExpandDatabase + SourceDatabase,
impl<DB> DefDatabase for DBwhere
DB: InternDatabase + ExpandDatabase + SourceDatabase,
fn expand_proc_attr_macros(&self) -> bool
fn file_item_tree(&self, file_id: HirFileId) -> Arc<ItemTree>
fn block_item_tree(&self, block_id: BlockId) -> Arc<ItemTree>
fn macro_def(&self, m: MacroId) -> MacroDefId
fn variant_fields_with_source_map( &self, id: VariantId, ) -> (Arc<VariantFields>, Arc<ExpressionStoreSourceMap>)
fn enum_variants(&self, id: EnumId) -> Arc<EnumVariants>
fn enum_variants_with_diagnostics( &self, id: EnumId, ) -> (Arc<EnumVariants>, Option<Arc<ThinVec<InactiveEnumVariantCode>>>)
fn impl_items(&self, e: ImplId) -> Arc<ImplItems>
fn impl_items_with_diagnostics( &self, e: ImplId, ) -> (Arc<ImplItems>, DefDiagnostics)
fn trait_items(&self, e: TraitId) -> Arc<TraitItems>
fn trait_items_with_diagnostics( &self, tr: TraitId, ) -> (Arc<TraitItems>, DefDiagnostics)
fn variant_fields(&self, id: VariantId) -> Arc<VariantFields>
fn trait_signature(&self, trait_: TraitId) -> Arc<TraitSignature>
fn impl_signature(&self, impl_: ImplId) -> Arc<ImplSignature>
fn struct_signature(&self, struct_: StructId) -> Arc<StructSignature>
fn union_signature(&self, union_: UnionId) -> Arc<UnionSignature>
fn enum_signature(&self, e: EnumId) -> Arc<EnumSignature>
fn const_signature(&self, e: ConstId) -> Arc<ConstSignature>
fn static_signature(&self, e: StaticId) -> Arc<StaticSignature>
fn function_signature(&self, e: FunctionId) -> Arc<FunctionSignature>
fn trait_alias_signature(&self, e: TraitAliasId) -> Arc<TraitAliasSignature>
fn type_alias_signature(&self, e: TypeAliasId) -> Arc<TypeAliasSignature>
fn trait_signature_with_source_map( &self, trait_: TraitId, ) -> (Arc<TraitSignature>, Arc<ExpressionStoreSourceMap>)
fn impl_signature_with_source_map( &self, impl_: ImplId, ) -> (Arc<ImplSignature>, Arc<ExpressionStoreSourceMap>)
fn struct_signature_with_source_map( &self, struct_: StructId, ) -> (Arc<StructSignature>, Arc<ExpressionStoreSourceMap>)
fn union_signature_with_source_map( &self, union_: UnionId, ) -> (Arc<UnionSignature>, Arc<ExpressionStoreSourceMap>)
fn enum_signature_with_source_map( &self, e: EnumId, ) -> (Arc<EnumSignature>, Arc<ExpressionStoreSourceMap>)
fn const_signature_with_source_map( &self, e: ConstId, ) -> (Arc<ConstSignature>, Arc<ExpressionStoreSourceMap>)
fn static_signature_with_source_map( &self, e: StaticId, ) -> (Arc<StaticSignature>, Arc<ExpressionStoreSourceMap>)
fn function_signature_with_source_map( &self, e: FunctionId, ) -> (Arc<FunctionSignature>, Arc<ExpressionStoreSourceMap>)
fn trait_alias_signature_with_source_map( &self, e: TraitAliasId, ) -> (Arc<TraitAliasSignature>, Arc<ExpressionStoreSourceMap>)
fn type_alias_signature_with_source_map( &self, e: TypeAliasId, ) -> (Arc<TypeAliasSignature>, Arc<ExpressionStoreSourceMap>)
fn body_with_source_map( &self, def: DefWithBodyId, ) -> (Arc<Body>, Arc<BodySourceMap>)
fn body(&self, def: DefWithBodyId) -> Arc<Body>
fn expr_scopes(&self, def: DefWithBodyId) -> Arc<ExprScopes>
fn generic_params(&self, def: GenericDefId) -> Arc<GenericParams>
fn generic_params_and_store( &self, def: GenericDefId, ) -> (Arc<GenericParams>, Arc<ExpressionStore>)
fn generic_params_and_store_and_source_map( &self, def: GenericDefId, ) -> (Arc<GenericParams>, Arc<ExpressionStore>, Arc<ExpressionStoreSourceMap>)
fn fields_attrs(&self, def: VariantId) -> Arc<ArenaMap<Idx<FieldData>, Attrs>>
fn fields_attrs_source_map( &self, def: VariantId, ) -> Arc<ArenaMap<Idx<FieldData>, AstPtr<Either<TupleField, RecordField>>>>
fn attrs(&self, def: AttrDefId) -> Attrs
fn lang_attr(&self, def: AttrDefId) -> Option<LangItem>
fn import_map(&self, krate: Crate) -> Arc<ImportMap>
fn field_visibilities( &self, var: VariantId, ) -> Arc<ArenaMap<Idx<FieldData>, Visibility>>
fn function_visibility(&self, def: FunctionId) -> Visibility
fn const_visibility(&self, def: ConstId) -> Visibility
fn type_alias_visibility(&self, def: TypeAliasId) -> Visibility
fn notable_traits_in_deps(&self, krate: Crate) -> Arc<[Arc<[TraitId]>]>
fn crate_notable_traits(&self, krate: Crate) -> Option<Arc<[TraitId]>>
fn crate_supports_no_std(&self, crate_id: Crate) -> bool
fn include_macro_invoc( &self, crate_id: Crate, ) -> Arc<[(MacroCallId, EditionedFileId)]>
fn set_expand_proc_attr_macros(&mut self, __value: bool)
fn set_expand_proc_attr_macros_with_durability( &mut self, __value: bool, durability: Durability, )
§impl<DB> ExpandDatabase for DBwhere
DB: RootQueryDb,
impl<DB> ExpandDatabase for DBwhere
DB: RootQueryDb,
fn proc_macros(&self) -> Arc<ProcMacros>
fn proc_macros_for_crate(&self, krate: Crate) -> Option<Arc<CrateProcMacros>>
fn ast_id_map(&self, file_id: HirFileId) -> Arc<AstIdMap>
fn parse_or_expand(&self, file_id: HirFileId) -> SyntaxNode<RustLanguage>
fn parse_macro_expansion( &self, macro_file: MacroCallId, ) -> ValueResult<(Parse<SyntaxNode<RustLanguage>>, Arc<SpanMap<SyntaxContext>>), ExpandError>
fn span_map(&self, file_id: HirFileId) -> SpanMap
fn expansion_span_map( &self, file_id: MacroCallId, ) -> Arc<SpanMap<SyntaxContext>>
fn real_span_map(&self, file_id: EditionedFileId) -> Arc<RealSpanMap>
fn intern_macro_call(&self, macro_call: MacroCallLoc) -> MacroCallId
fn lookup_intern_macro_call(&self, macro_call: MacroCallId) -> MacroCallLoc
fn macro_arg( &self, id: MacroCallId, ) -> (Arc<TopSubtree<SpanData<SyntaxContext>>>, SyntaxFixupUndoInfo, SpanData<SyntaxContext>)
fn macro_arg_considering_derives( &self, id: MacroCallId, kind: &MacroCallKind, ) -> (Arc<TopSubtree<SpanData<SyntaxContext>>>, SyntaxFixupUndoInfo, SpanData<SyntaxContext>)
fn macro_expander(&self, id: MacroDefId) -> TokenExpander
fn decl_macro_expander( &self, def_crate: Crate, id: InFileWrapper<HirFileId, FileAstId<Macro>>, ) -> Arc<DeclarativeMacroExpander>
fn expand_proc_macro( &self, call: MacroCallId, ) -> ValueResult<Arc<TopSubtree<SpanData<SyntaxContext>>>, ExpandError>
fn proc_macro_span( &self, fun: InFileWrapper<HirFileId, FileAstId<Fn>>, ) -> SpanData<SyntaxContext>
fn parse_macro_expansion_error( &self, macro_call: MacroCallId, ) -> Option<Arc<ValueResult<Arc<[SyntaxError]>, ExpandError>>>
fn syntax_context(&self, file: HirFileId, edition: Edition) -> SyntaxContext
fn set_proc_macros(&mut self, __value: Arc<ProcMacros>)
fn set_proc_macros_with_durability( &mut self, __value: Arc<ProcMacros>, durability: Durability, )
§impl<DB> HirDatabase for DBwhere
DB: DefDatabase + Debug,
impl<DB> HirDatabase for DBwhere
DB: DefDatabase + Debug,
fn infer(&self, def: DefWithBodyId) -> Arc<InferenceResult>
fn mir_body(&self, def: DefWithBodyId) -> Result<Arc<MirBody>, MirLowerError>
fn mir_body_for_closure( &self, def: InternedClosureId, ) -> Result<Arc<MirBody>, MirLowerError>
fn monomorphized_mir_body( &self, def: DefWithBodyId, subst: Substitution<Interner>, env: Arc<TraitEnvironment>, ) -> Result<Arc<MirBody>, MirLowerError>
fn monomorphized_mir_body_for_closure( &self, def: InternedClosureId, subst: Substitution<Interner>, env: Arc<TraitEnvironment>, ) -> Result<Arc<MirBody>, MirLowerError>
fn borrowck( &self, def: DefWithBodyId, ) -> Result<Arc<[BorrowckResult]>, MirLowerError>
fn const_eval( &self, def: GeneralConstId, subst: Substitution<Interner>, trait_env: Option<Arc<TraitEnvironment>>, ) -> Result<Const<Interner>, ConstEvalError>
fn const_eval_static( &self, def: StaticId, ) -> Result<Const<Interner>, ConstEvalError>
fn const_eval_discriminant( &self, def: EnumVariantId, ) -> Result<i128, ConstEvalError>
fn lookup_impl_method( &self, env: Arc<TraitEnvironment>, func: FunctionId, fn_subst: Substitution<Interner>, ) -> (FunctionId, Substitution<Interner>)
fn layout_of_adt( &self, def: AdtId, subst: Substitution<Interner>, env: Arc<TraitEnvironment>, ) -> Result<Arc<LayoutData<RustcFieldIdx, RustcEnumVariantIdx>>, LayoutError>
fn layout_of_ty( &self, ty: Ty<Interner>, env: Arc<TraitEnvironment>, ) -> Result<Arc<LayoutData<RustcFieldIdx, RustcEnumVariantIdx>>, LayoutError>
fn target_data_layout( &self, krate: Crate, ) -> Result<Arc<TargetDataLayout>, Arc<str>>
fn dyn_compatibility_of_trait( &self, trait_: TraitId, ) -> Option<DynCompatibilityViolation>
fn ty(&self, def: TyDefId) -> Binders<Ty<Interner>>
fn type_for_type_alias_with_diagnostics( &self, def: TypeAliasId, ) -> (Binders<Ty<Interner>>, Option<ThinArc<(), TyLoweringDiagnostic>>)
fn value_ty(&self, def: ValueTyDefId) -> Option<Binders<Ty<Interner>>>
fn impl_self_ty_with_diagnostics( &self, def: ImplId, ) -> (Binders<Ty<Interner>>, Option<ThinArc<(), TyLoweringDiagnostic>>)
fn impl_self_ty(&self, def: ImplId) -> Binders<Ty<Interner>>
fn const_param_ty_with_diagnostics( &self, def: ConstParamId, ) -> (Ty<Interner>, Option<ThinArc<(), TyLoweringDiagnostic>>)
fn const_param_ty(&self, def: ConstParamId) -> Ty<Interner>
fn impl_trait_with_diagnostics( &self, def: ImplId, ) -> Option<(Binders<TraitRef<Interner>>, Option<ThinArc<(), TyLoweringDiagnostic>>)>
fn impl_trait(&self, def: ImplId) -> Option<Binders<TraitRef<Interner>>>
fn field_types_with_diagnostics( &self, var: VariantId, ) -> (Arc<ArenaMap<Idx<FieldData>, Binders<Ty<Interner>>>>, Option<ThinArc<(), TyLoweringDiagnostic>>)
fn field_types( &self, var: VariantId, ) -> Arc<ArenaMap<Idx<FieldData>, Binders<Ty<Interner>>>>
fn callable_item_signature(&self, def: CallableDefId) -> Binders<CallableSig>
fn return_type_impl_traits( &self, def: FunctionId, ) -> Option<Arc<Binders<ImplTraits>>>
fn type_alias_impl_traits( &self, def: TypeAliasId, ) -> Option<Arc<Binders<ImplTraits>>>
fn generic_predicates_for_param( &self, def: GenericDefId, param_id: TypeOrConstParamId, assoc_name: Option<Name>, ) -> GenericPredicates
fn generic_predicates(&self, def: GenericDefId) -> GenericPredicates
fn generic_predicates_without_parent_with_diagnostics( &self, def: GenericDefId, ) -> (GenericPredicates, Option<ThinArc<(), TyLoweringDiagnostic>>)
fn generic_predicates_without_parent( &self, def: GenericDefId, ) -> GenericPredicates
fn trait_environment_for_body( &self, def: DefWithBodyId, ) -> Arc<TraitEnvironment>
fn trait_environment(&self, def: GenericDefId) -> Arc<TraitEnvironment>
fn generic_defaults_with_diagnostics( &self, def: GenericDefId, ) -> (GenericDefaults, Option<ThinArc<(), TyLoweringDiagnostic>>)
fn generic_defaults(&self, def: GenericDefId) -> GenericDefaults
fn inherent_impls_in_crate(&self, krate: Crate) -> Arc<InherentImpls>
fn inherent_impls_in_block(&self, block: BlockId) -> Option<Arc<InherentImpls>>
fn incoherent_inherent_impl_crates( &self, krate: Crate, fp: TyFingerprint, ) -> SmallVec<[Crate; 2]>
fn trait_impls_in_crate(&self, krate: Crate) -> Arc<TraitImpls>
fn trait_impls_in_block(&self, block: BlockId) -> Option<Arc<TraitImpls>>
fn trait_impls_in_deps(&self, krate: Crate) -> Arc<[Arc<TraitImpls>]>
fn intern_callable_def( &self, callable_def: CallableDefId, ) -> InternedCallableDefId
fn intern_type_or_const_param_id( &self, param_id: TypeOrConstParamId, ) -> InternedTypeOrConstParamId
fn intern_lifetime_param_id( &self, param_id: LifetimeParamId, ) -> InternedLifetimeParamId
fn intern_impl_trait_id(&self, id: ImplTraitId) -> InternedOpaqueTyId
fn intern_closure(&self, id: InternedClosure) -> InternedClosureId
fn intern_coroutine(&self, id: InternedCoroutine) -> InternedCoroutineId
fn associated_ty_data( &self, id: TypeAliasId, ) -> Arc<AssociatedTyDatum<Interner>>
fn trait_datum( &self, krate: Crate, trait_id: TraitId<Interner>, ) -> Arc<TraitDatum<Interner>>
fn adt_datum( &self, krate: Crate, struct_id: AdtId<Interner>, ) -> Arc<AdtDatum<Interner>>
fn impl_datum( &self, krate: Crate, impl_id: ImplId<Interner>, ) -> Arc<ImplDatum<Interner>>
fn fn_def_datum(&self, fn_def_id: CallableDefId) -> Arc<FnDefDatum<Interner>>
fn fn_def_variance(&self, fn_def_id: CallableDefId) -> Variances<Interner>
fn adt_variance(&self, adt_id: AdtId) -> Variances<Interner>
fn variances_of(&self, def: GenericDefId) -> Option<Arc<[Variance]>>
fn associated_ty_value( &self, krate: Crate, id: AssociatedTyValueId<Interner>, ) -> Arc<AssociatedTyValue<Interner>>
fn normalize_projection( &self, projection: ProjectionTy<Interner>, env: Arc<TraitEnvironment>, ) -> Ty<Interner>
fn trait_solve( &self, krate: Crate, block: Option<BlockId>, goal: Canonical<InEnvironment<Goal<Interner>>>, ) -> Option<Solution<Interner>>
fn program_clauses_for_chalk_env( &self, krate: Crate, block: Option<BlockId>, env: Environment<Interner>, ) -> ProgramClauses<Interner>
fn has_drop_glue( &self, ty: Ty<Interner>, env: Arc<TraitEnvironment>, ) -> DropGlue
fn lookup_intern_callable_def(&self, id: InternedCallableDefId) -> CallableDefId
fn lookup_intern_type_or_const_param_id( &self, id: InternedTypeOrConstParamId, ) -> TypeOrConstParamId
fn lookup_intern_lifetime_param_id( &self, id: InternedLifetimeParamId, ) -> LifetimeParamId
fn lookup_intern_impl_trait_id(&self, id: InternedOpaqueTyId) -> ImplTraitId
fn lookup_intern_closure(&self, id: InternedClosureId) -> InternedClosure
fn lookup_intern_coroutine(&self, id: InternedCoroutineId) -> InternedCoroutine
§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>
§impl<DB> InternDatabase for DBwhere
DB: RootQueryDb,
impl<DB> InternDatabase for DBwhere
DB: RootQueryDb,
fn intern_use(&self, loc: ItemLoc<Use>) -> UseId
fn intern_extern_crate(&self, loc: ItemLoc<ExternCrate>) -> ExternCrateId
fn intern_function(&self, loc: AssocItemLoc<Function>) -> FunctionId
fn intern_struct(&self, loc: ItemLoc<Struct>) -> StructId
fn intern_union(&self, loc: ItemLoc<Union>) -> UnionId
fn intern_enum(&self, loc: ItemLoc<Enum>) -> EnumId
fn intern_enum_variant(&self, loc: EnumVariantLoc) -> EnumVariantId
fn intern_const(&self, loc: AssocItemLoc<Const>) -> ConstId
fn intern_static(&self, loc: AssocItemLoc<Static>) -> StaticId
fn intern_trait(&self, loc: ItemLoc<Trait>) -> TraitId
fn intern_trait_alias(&self, loc: ItemLoc<TraitAlias>) -> TraitAliasId
fn intern_type_alias(&self, loc: AssocItemLoc<TypeAlias>) -> TypeAliasId
fn intern_impl(&self, loc: ItemLoc<Impl>) -> ImplId
fn intern_extern_block(&self, loc: ItemLoc<ExternBlock>) -> ExternBlockId
fn intern_macro2(&self, loc: Macro2Loc) -> Macro2Id
fn intern_proc_macro(&self, loc: ProcMacroLoc) -> ProcMacroId
fn intern_macro_rules(&self, loc: MacroRulesLoc) -> MacroRulesId
fn intern_block(&self, loc: BlockLoc) -> BlockId
fn lookup_intern_use(&self, id: UseId) -> ItemLoc<Use>
fn lookup_intern_extern_crate(&self, id: ExternCrateId) -> ItemLoc<ExternCrate>
fn lookup_intern_function(&self, id: FunctionId) -> AssocItemLoc<Function>
fn lookup_intern_struct(&self, id: StructId) -> ItemLoc<Struct>
fn lookup_intern_union(&self, id: UnionId) -> ItemLoc<Union>
fn lookup_intern_enum(&self, id: EnumId) -> ItemLoc<Enum>
fn lookup_intern_enum_variant(&self, id: EnumVariantId) -> EnumVariantLoc
fn lookup_intern_const(&self, id: ConstId) -> AssocItemLoc<Const>
fn lookup_intern_static(&self, id: StaticId) -> AssocItemLoc<Static>
fn lookup_intern_trait(&self, id: TraitId) -> ItemLoc<Trait>
fn lookup_intern_trait_alias(&self, id: TraitAliasId) -> ItemLoc<TraitAlias>
fn lookup_intern_type_alias(&self, id: TypeAliasId) -> AssocItemLoc<TypeAlias>
fn lookup_intern_impl(&self, id: ImplId) -> ItemLoc<Impl>
fn lookup_intern_extern_block(&self, id: ExternBlockId) -> ItemLoc<ExternBlock>
fn lookup_intern_macro2(&self, id: Macro2Id) -> Macro2Loc
fn lookup_intern_proc_macro(&self, id: ProcMacroId) -> ProcMacroLoc
fn lookup_intern_macro_rules(&self, id: MacroRulesId) -> MacroRulesLoc
fn lookup_intern_block(&self, id: BlockId) -> BlockLoc
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