pub struct ParseCtx<'a> {
pub session: &'a Session,
pub scope: Scope<'a>,
pub rules: ParsePatternRules,
}
Fields§
§session: &'a Session
§scope: Scope<'a>
§rules: ParsePatternRules
Implementations§
source§impl<'a> ParseCtx<'a>
impl<'a> ParseCtx<'a>
pub fn with_scope(&self, scope: Scope<'a>) -> ParseCtx<'a>
pub fn with_rules(&self, rules: ParsePatternRules) -> ParseCtx<'a>
pub fn create_child_scope(&self, typ: ScopeType) -> Scope<'a>
sourcepub fn create_node_with_flags(
&self,
loc: SourceRange<'a>,
stx: Syntax<'a>,
flags: Flags<NodeFlag>
) -> Node<'a>
pub fn create_node_with_flags( &self, loc: SourceRange<'a>, stx: Syntax<'a>, flags: Flags<NodeFlag> ) -> Node<'a>
This node will be created in the current scope.
sourcepub fn create_node_with_flag(
&self,
loc: SourceRange<'a>,
stx: Syntax<'a>,
flag: NodeFlag
) -> Node<'a>
pub fn create_node_with_flag( &self, loc: SourceRange<'a>, stx: Syntax<'a>, flag: NodeFlag ) -> Node<'a>
This node will be created in the current scope.
sourcepub fn create_node(&self, loc: SourceRange<'a>, stx: Syntax<'a>) -> Node<'a>
pub fn create_node(&self, loc: SourceRange<'a>, stx: Syntax<'a>) -> Node<'a>
This node will be created in the current scope.
Trait Implementations§
Auto Trait Implementations§
impl<'a> !RefUnwindSafe for ParseCtx<'a>
impl<'a> !Send for ParseCtx<'a>
impl<'a> !Sync for ParseCtx<'a>
impl<'a> Unpin for ParseCtx<'a>
impl<'a> !UnwindSafe for ParseCtx<'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