pub struct CompileCtx<'a> {
pub interner: &'a Interner,
pub type_ctx: &'a TypeContext,
pub symbol_table: &'a SymbolTable,
pub strings: &'a RefCell<StringTableBuilder>,
pub node_types: Option<&'a IndexMap<Symbol, NodeTypeId>>,
pub node_fields: Option<&'a IndexMap<Symbol, NodeFieldId>>,
}Expand description
Compilation context bundling all shared compilation state.
Uses RefCell for strings to allow interior mutability while
sharing the context across compilation phases.
Fields§
§interner: &'a Interner§type_ctx: &'a TypeContext§symbol_table: &'a SymbolTable§strings: &'a RefCell<StringTableBuilder>§node_types: Option<&'a IndexMap<Symbol, NodeTypeId>>§node_fields: Option<&'a IndexMap<Symbol, NodeFieldId>>Auto Trait Implementations§
impl<'a> Freeze for CompileCtx<'a>
impl<'a> !RefUnwindSafe for CompileCtx<'a>
impl<'a> !Send for CompileCtx<'a>
impl<'a> !Sync for CompileCtx<'a>
impl<'a> Unpin for CompileCtx<'a>
impl<'a> !UnwindSafe for CompileCtx<'a>
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