Struct erg_compiler::module::impls::TraitImpls
source · pub struct TraitImpls { /* private fields */ }
Expand description
Caches checked modules. In addition to being queried here when re-imported, it is also used when linking (Erg links all scripts defined in erg and outputs them to a single pyc file).
Implementations§
source§impl TraitImpls
impl TraitImpls
pub fn new() -> Self
pub fn get<P: Eq + Hash + ?Sized>(&self, path: &P) -> Option<&Set<TraitImpl>>where Str: Borrow<P>,
pub fn get_mut<Q: Eq + Hash + ?Sized>( &mut self, path: &Q ) -> Option<&mut Set<TraitImpl>>where Str: Borrow<Q>,
pub fn register(&mut self, name: Str, impls: Set<TraitImpl>)
pub fn remove<Q: Eq + Hash + ?Sized>( &mut self, path: &Q ) -> Option<Set<TraitImpl>>where Str: Borrow<Q>,
pub fn initialize(&mut self)
Trait Implementations§
source§impl Debug for TraitImpls
impl Debug for TraitImpls
source§impl Default for TraitImpls
impl Default for TraitImpls
source§fn default() -> TraitImpls
fn default() -> TraitImpls
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl !RefUnwindSafe for TraitImpls
impl !Send for TraitImpls
impl !Sync for TraitImpls
impl Unpin for TraitImpls
impl !UnwindSafe for TraitImpls
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