pub struct TypeNodeChecker<'a, 'ctx> {
pub ctx: &'a mut CheckerContext<'ctx>,
/* private fields */
}Expand description
Type node checker that operates on the shared context.
This is a stateless checker that borrows the context mutably. All type resolution for type nodes goes through this checker.
Fields§
§ctx: &'a mut CheckerContext<'ctx>Implementations§
Source§impl<'a, 'ctx> TypeNodeChecker<'a, 'ctx>
impl<'a, 'ctx> TypeNodeChecker<'a, 'ctx>
Sourcepub const fn new(ctx: &'a mut CheckerContext<'ctx>) -> Self
pub const fn new(ctx: &'a mut CheckerContext<'ctx>) -> Self
Create a new type node checker with a mutable context reference.
Sourcepub fn check(&mut self, idx: NodeIndex) -> TypeId
pub fn check(&mut self, idx: NodeIndex) -> TypeId
Check a type node and return its type.
This is the main entry point for type node resolution. It handles caching and dispatches to specific type node handlers.
Sourcepub const fn context(&self) -> &CheckerContext<'ctx>
pub const fn context(&self) -> &CheckerContext<'ctx>
Get the context reference (for read-only access).
Auto Trait Implementations§
impl<'a, 'ctx> Freeze for TypeNodeChecker<'a, 'ctx>
impl<'a, 'ctx> !RefUnwindSafe for TypeNodeChecker<'a, 'ctx>
impl<'a, 'ctx> !Send for TypeNodeChecker<'a, 'ctx>
impl<'a, 'ctx> !Sync for TypeNodeChecker<'a, 'ctx>
impl<'a, 'ctx> Unpin for TypeNodeChecker<'a, 'ctx>
impl<'a, 'ctx> UnsafeUnpin for TypeNodeChecker<'a, 'ctx>
impl<'a, 'ctx> !UnwindSafe for TypeNodeChecker<'a, 'ctx>
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