pub struct LanguageInfoStore { /* private fields */ }Expand description
Store for language info registered by modules during init.
Modules register their LanguageInfo here, and bootstrap extracts them
to build a concrete LanguageRegistry after module initialization.
Implementations§
Source§impl LanguageInfoStore
impl LanguageInfoStore
Sourcepub fn add(&self, info: LanguageInfo)
pub fn add(&self, info: LanguageInfo)
Add language info to the store.
Called by syntax modules during init().
Sourcepub fn take_all(&self) -> Vec<LanguageInfo>
pub fn take_all(&self) -> Vec<LanguageInfo>
Take all registered language info entries.
Called by bootstrap after all modules have initialized. This drains the store, so subsequent calls return empty vec.
Trait Implementations§
Source§impl Debug for LanguageInfoStore
impl Debug for LanguageInfoStore
Source§impl Default for LanguageInfoStore
impl Default for LanguageInfoStore
Source§fn default() -> LanguageInfoStore
fn default() -> LanguageInfoStore
Returns the “default value” for a type. Read more
impl Service for LanguageInfoStore
Auto Trait Implementations§
impl !Freeze for LanguageInfoStore
impl !RefUnwindSafe for LanguageInfoStore
impl Send for LanguageInfoStore
impl Sync for LanguageInfoStore
impl Unpin for LanguageInfoStore
impl UnsafeUnpin for LanguageInfoStore
impl UnwindSafe for LanguageInfoStore
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