Enum lib_ruby_parser::nodes::Node [−][src]
#[repr(C)]
pub enum Node {
Show 124 variants
Alias(Alias),
AndAsgn(AndAsgn),
And(And),
Arg(Arg),
Args(Args),
Array(Array),
ArrayPattern(ArrayPattern),
ArrayPatternWithTail(ArrayPatternWithTail),
BackRef(BackRef),
Begin(Begin),
Block(Block),
BlockPass(BlockPass),
Blockarg(Blockarg),
Break(Break),
Case(Case),
CaseMatch(CaseMatch),
Casgn(Casgn),
Cbase(Cbase),
Class(Class),
Complex(Complex),
Const(Const),
ConstPattern(ConstPattern),
CSend(CSend),
Cvar(Cvar),
Cvasgn(Cvasgn),
Def(Def),
Defined(Defined),
Defs(Defs),
Dstr(Dstr),
Dsym(Dsym),
EFlipFlop(EFlipFlop),
EmptyElse(EmptyElse),
Encoding(Encoding),
Ensure(Ensure),
Erange(Erange),
False(False),
File(File),
FindPattern(FindPattern),
Float(Float),
For(For),
ForwardArg(ForwardArg),
ForwardedArgs(ForwardedArgs),
Gvar(Gvar),
Gvasgn(Gvasgn),
Hash(Hash),
Kwargs(Kwargs),
HashPattern(HashPattern),
Heredoc(Heredoc),
If(If),
IfGuard(IfGuard),
IfMod(IfMod),
IfTernary(IfTernary),
IFlipFlop(IFlipFlop),
MatchPattern(MatchPattern),
MatchPatternP(MatchPatternP),
InPattern(InPattern),
Index(Index),
IndexAsgn(IndexAsgn),
Int(Int),
Irange(Irange),
Ivar(Ivar),
Ivasgn(Ivasgn),
Kwarg(Kwarg),
KwBegin(KwBegin),
Kwnilarg(Kwnilarg),
Kwoptarg(Kwoptarg),
Kwrestarg(Kwrestarg),
Kwsplat(Kwsplat),
Lambda(Lambda),
Line(Line),
Lvar(Lvar),
Lvasgn(Lvasgn),
Masgn(Masgn),
MatchAlt(MatchAlt),
MatchAs(MatchAs),
MatchCurrentLine(MatchCurrentLine),
MatchNilPattern(MatchNilPattern),
MatchRest(MatchRest),
MatchVar(MatchVar),
MatchWithLvasgn(MatchWithLvasgn),
Mlhs(Mlhs),
Module(Module),
Next(Next),
Nil(Nil),
NthRef(NthRef),
Numblock(Numblock),
OpAsgn(OpAsgn),
Optarg(Optarg),
Or(Or),
OrAsgn(OrAsgn),
Pair(Pair),
Pin(Pin),
Postexe(Postexe),
Preexe(Preexe),
Procarg0(Procarg0),
Rational(Rational),
Redo(Redo),
RegOpt(RegOpt),
Regexp(Regexp),
Rescue(Rescue),
RescueBody(RescueBody),
Restarg(Restarg),
Retry(Retry),
Return(Return),
SClass(SClass),
Self_(Self_),
Send(Send),
Shadowarg(Shadowarg),
Splat(Splat),
Str(Str),
Super(Super),
Sym(Sym),
True(True),
Undef(Undef),
UnlessGuard(UnlessGuard),
Until(Until),
UntilPost(UntilPost),
When(When),
While(While),
WhilePost(WhilePost),
XHeredoc(XHeredoc),
Xstr(Xstr),
Yield(Yield),
ZSuper(ZSuper),
}
Expand description
Generic combination of all known nodes.
Variants
Alias(Alias)
Tuple Fields of Alias
0: Alias
AndAsgn(AndAsgn)
Tuple Fields of AndAsgn
0: AndAsgn
And(And)
Tuple Fields of And
0: And
Arg(Arg)
Tuple Fields of Arg
0: Arg
Args(Args)
Tuple Fields of Args
0: Args
Array(Array)
Tuple Fields of Array
0: Array
ArrayPattern(ArrayPattern)
Tuple Fields of ArrayPattern
0: ArrayPattern
ArrayPatternWithTail(ArrayPatternWithTail)
Tuple Fields of ArrayPatternWithTail
BackRef(BackRef)
Tuple Fields of BackRef
0: BackRef
Begin(Begin)
Tuple Fields of Begin
0: Begin
Block(Block)
Tuple Fields of Block
0: Block
BlockPass(BlockPass)
Tuple Fields of BlockPass
0: BlockPass
Blockarg(Blockarg)
Tuple Fields of Blockarg
0: Blockarg
Break(Break)
Tuple Fields of Break
0: Break
Case(Case)
Tuple Fields of Case
0: Case
CaseMatch(CaseMatch)
Tuple Fields of CaseMatch
0: CaseMatch
Casgn(Casgn)
Tuple Fields of Casgn
0: Casgn
Cbase(Cbase)
Tuple Fields of Cbase
0: Cbase
Class(Class)
Tuple Fields of Class
0: Class
Complex(Complex)
Tuple Fields of Complex
0: Complex
Const(Const)
Tuple Fields of Const
0: Const
ConstPattern(ConstPattern)
Tuple Fields of ConstPattern
0: ConstPattern
CSend(CSend)
Tuple Fields of CSend
0: CSend
Cvar(Cvar)
Tuple Fields of Cvar
0: Cvar
Cvasgn(Cvasgn)
Tuple Fields of Cvasgn
0: Cvasgn
Def(Def)
Tuple Fields of Def
0: Def
Defined(Defined)
Tuple Fields of Defined
0: Defined
Defs(Defs)
Tuple Fields of Defs
0: Defs
Dstr(Dstr)
Tuple Fields of Dstr
0: Dstr
Dsym(Dsym)
Tuple Fields of Dsym
0: Dsym
EFlipFlop(EFlipFlop)
Tuple Fields of EFlipFlop
0: EFlipFlop
EmptyElse(EmptyElse)
Tuple Fields of EmptyElse
0: EmptyElse
Encoding(Encoding)
Tuple Fields of Encoding
0: Encoding
Ensure(Ensure)
Tuple Fields of Ensure
0: Ensure
Erange(Erange)
Tuple Fields of Erange
0: Erange
False(False)
Tuple Fields of False
0: False
File(File)
Tuple Fields of File
0: File
FindPattern(FindPattern)
Tuple Fields of FindPattern
0: FindPattern
Float(Float)
Tuple Fields of Float
0: Float
For(For)
Tuple Fields of For
0: For
ForwardArg(ForwardArg)
Tuple Fields of ForwardArg
0: ForwardArg
ForwardedArgs(ForwardedArgs)
Tuple Fields of ForwardedArgs
Gvar(Gvar)
Tuple Fields of Gvar
0: Gvar
Gvasgn(Gvasgn)
Tuple Fields of Gvasgn
0: Gvasgn
Hash(Hash)
Tuple Fields of Hash
0: Hash
Kwargs(Kwargs)
Tuple Fields of Kwargs
0: Kwargs
HashPattern(HashPattern)
Tuple Fields of HashPattern
0: HashPattern
Heredoc(Heredoc)
Tuple Fields of Heredoc
0: Heredoc
If(If)
Tuple Fields of If
0: If
IfGuard(IfGuard)
Tuple Fields of IfGuard
0: IfGuard
IfMod(IfMod)
Tuple Fields of IfMod
0: IfMod
IfTernary(IfTernary)
Tuple Fields of IfTernary
0: IfTernary
IFlipFlop(IFlipFlop)
Tuple Fields of IFlipFlop
0: IFlipFlop
MatchPattern(MatchPattern)
Tuple Fields of MatchPattern
0: MatchPattern
MatchPatternP(MatchPatternP)
Tuple Fields of MatchPatternP
InPattern(InPattern)
Tuple Fields of InPattern
0: InPattern
Index(Index)
Tuple Fields of Index
0: Index
IndexAsgn(IndexAsgn)
Tuple Fields of IndexAsgn
0: IndexAsgn
Int(Int)
Tuple Fields of Int
0: Int
Irange(Irange)
Tuple Fields of Irange
0: Irange
Ivar(Ivar)
Tuple Fields of Ivar
0: Ivar
Ivasgn(Ivasgn)
Tuple Fields of Ivasgn
0: Ivasgn
Kwarg(Kwarg)
Tuple Fields of Kwarg
0: Kwarg
KwBegin(KwBegin)
Tuple Fields of KwBegin
0: KwBegin
Kwnilarg(Kwnilarg)
Tuple Fields of Kwnilarg
0: Kwnilarg
Kwoptarg(Kwoptarg)
Tuple Fields of Kwoptarg
0: Kwoptarg
Kwrestarg(Kwrestarg)
Tuple Fields of Kwrestarg
0: Kwrestarg
Kwsplat(Kwsplat)
Tuple Fields of Kwsplat
0: Kwsplat
Lambda(Lambda)
Tuple Fields of Lambda
0: Lambda
Line(Line)
Tuple Fields of Line
0: Line
Lvar(Lvar)
Tuple Fields of Lvar
0: Lvar
Lvasgn(Lvasgn)
Tuple Fields of Lvasgn
0: Lvasgn
Masgn(Masgn)
Tuple Fields of Masgn
0: Masgn
MatchAlt(MatchAlt)
Tuple Fields of MatchAlt
0: MatchAlt
MatchAs(MatchAs)
Tuple Fields of MatchAs
0: MatchAs
MatchCurrentLine(MatchCurrentLine)
Tuple Fields of MatchCurrentLine
MatchNilPattern(MatchNilPattern)
Tuple Fields of MatchNilPattern
MatchRest(MatchRest)
Tuple Fields of MatchRest
0: MatchRest
MatchVar(MatchVar)
Tuple Fields of MatchVar
0: MatchVar
MatchWithLvasgn(MatchWithLvasgn)
Tuple Fields of MatchWithLvasgn
Mlhs(Mlhs)
Tuple Fields of Mlhs
0: Mlhs
Module(Module)
Tuple Fields of Module
0: Module
Next(Next)
Tuple Fields of Next
0: Next
Nil(Nil)
Tuple Fields of Nil
0: Nil
NthRef(NthRef)
Tuple Fields of NthRef
0: NthRef
Numblock(Numblock)
Tuple Fields of Numblock
0: Numblock
OpAsgn(OpAsgn)
Tuple Fields of OpAsgn
0: OpAsgn
Optarg(Optarg)
Tuple Fields of Optarg
0: Optarg
Or(Or)
Tuple Fields of Or
0: Or
OrAsgn(OrAsgn)
Tuple Fields of OrAsgn
0: OrAsgn
Pair(Pair)
Tuple Fields of Pair
0: Pair
Pin(Pin)
Tuple Fields of Pin
0: Pin
Postexe(Postexe)
Tuple Fields of Postexe
0: Postexe
Preexe(Preexe)
Tuple Fields of Preexe
0: Preexe
Procarg0(Procarg0)
Tuple Fields of Procarg0
0: Procarg0
Rational(Rational)
Tuple Fields of Rational
0: Rational
Redo(Redo)
Tuple Fields of Redo
0: Redo
RegOpt(RegOpt)
Tuple Fields of RegOpt
0: RegOpt
Regexp(Regexp)
Tuple Fields of Regexp
0: Regexp
Rescue(Rescue)
Tuple Fields of Rescue
0: Rescue
RescueBody(RescueBody)
Tuple Fields of RescueBody
0: RescueBody
Restarg(Restarg)
Tuple Fields of Restarg
0: Restarg
Retry(Retry)
Tuple Fields of Retry
0: Retry
Return(Return)
Tuple Fields of Return
0: Return
SClass(SClass)
Tuple Fields of SClass
0: SClass
Self_(Self_)
Tuple Fields of Self_
0: Self_
Send(Send)
Tuple Fields of Send
0: Send
Shadowarg(Shadowarg)
Tuple Fields of Shadowarg
0: Shadowarg
Splat(Splat)
Tuple Fields of Splat
0: Splat
Str(Str)
Tuple Fields of Str
0: Str
Super(Super)
Tuple Fields of Super
0: Super
Sym(Sym)
Tuple Fields of Sym
0: Sym
True(True)
Tuple Fields of True
0: True
Undef(Undef)
Tuple Fields of Undef
0: Undef
UnlessGuard(UnlessGuard)
Tuple Fields of UnlessGuard
0: UnlessGuard
Until(Until)
Tuple Fields of Until
0: Until
UntilPost(UntilPost)
Tuple Fields of UntilPost
0: UntilPost
When(When)
Tuple Fields of When
0: When
While(While)
Tuple Fields of While
0: While
WhilePost(WhilePost)
Tuple Fields of WhilePost
0: WhilePost
XHeredoc(XHeredoc)
Tuple Fields of XHeredoc
0: XHeredoc
Xstr(Xstr)
Tuple Fields of Xstr
0: Xstr
Yield(Yield)
Tuple Fields of Yield
0: Yield
ZSuper(ZSuper)
Tuple Fields of ZSuper
0: ZSuper
Implementations
Casts &Node
to Option<&mut nodes::Alias>
Casts self
to nodes::Alias
, panics if variant doesn’t match
Returns true if self
is Node::AndAsgn
Casts &Node
to Option<&nodes::AndAsgn>
Casts &Node
to Option<&mut nodes::AndAsgn>
Casts self
to nodes::AndAsgn
, panics if variant doesn’t match
Casts &Node
to Option<&mut nodes::And>
Casts &Node
to Option<&mut nodes::Arg>
Casts &Node
to Option<&mut nodes::Args>
Casts &Node
to Option<&mut nodes::Array>
Casts self
to nodes::Array
, panics if variant doesn’t match
Returns true if self
is Node::ArrayPattern
Casts &Node
to Option<&nodes::ArrayPattern>
Casts &Node
to Option<&mut nodes::ArrayPattern>
Casts self
to nodes::ArrayPattern
, panics if variant doesn’t match
Returns true if self
is Node::ArrayPatternWithTail
Casts &Node
to Option<&nodes::ArrayPatternWithTail>
Casts &Node
to Option<&mut nodes::ArrayPatternWithTail>
Casts self
to nodes::ArrayPatternWithTail
, panics if variant doesn’t match
Returns true if self
is Node::BackRef
Casts &Node
to Option<&nodes::BackRef>
Casts &Node
to Option<&mut nodes::BackRef>
Casts self
to nodes::BackRef
, panics if variant doesn’t match
Casts &Node
to Option<&mut nodes::Begin>
Casts self
to nodes::Begin
, panics if variant doesn’t match
Casts &Node
to Option<&mut nodes::Block>
Casts self
to nodes::Block
, panics if variant doesn’t match
Returns true if self
is Node::BlockPass
Casts &Node
to Option<&nodes::BlockPass>
Casts &Node
to Option<&mut nodes::BlockPass>
Casts self
to nodes::BlockPass
, panics if variant doesn’t match
Returns true if self
is Node::Blockarg
Casts &Node
to Option<&nodes::Blockarg>
Casts &Node
to Option<&mut nodes::Blockarg>
Casts self
to nodes::Blockarg
, panics if variant doesn’t match
Casts &Node
to Option<&mut nodes::Break>
Casts self
to nodes::Break
, panics if variant doesn’t match
Casts &Node
to Option<&mut nodes::Case>
Returns true if self
is Node::CaseMatch
Casts &Node
to Option<&nodes::CaseMatch>
Casts &Node
to Option<&mut nodes::CaseMatch>
Casts self
to nodes::CaseMatch
, panics if variant doesn’t match
Casts &Node
to Option<&mut nodes::Casgn>
Casts self
to nodes::Casgn
, panics if variant doesn’t match
Casts &Node
to Option<&mut nodes::Cbase>
Casts self
to nodes::Cbase
, panics if variant doesn’t match
Casts &Node
to Option<&mut nodes::Class>
Casts self
to nodes::Class
, panics if variant doesn’t match
Returns true if self
is Node::Complex
Casts &Node
to Option<&nodes::Complex>
Casts &Node
to Option<&mut nodes::Complex>
Casts self
to nodes::Complex
, panics if variant doesn’t match
Casts &Node
to Option<&mut nodes::Const>
Casts self
to nodes::Const
, panics if variant doesn’t match
Returns true if self
is Node::ConstPattern
Casts &Node
to Option<&nodes::ConstPattern>
Casts &Node
to Option<&mut nodes::ConstPattern>
Casts self
to nodes::ConstPattern
, panics if variant doesn’t match
Casts &Node
to Option<&mut nodes::CSend>
Casts self
to nodes::CSend
, panics if variant doesn’t match
Casts &Node
to Option<&mut nodes::Cvar>
Casts &Node
to Option<&mut nodes::Cvasgn>
Casts self
to nodes::Cvasgn
, panics if variant doesn’t match
Casts &Node
to Option<&mut nodes::Def>
Returns true if self
is Node::Defined
Casts &Node
to Option<&nodes::Defined>
Casts &Node
to Option<&mut nodes::Defined>
Casts self
to nodes::Defined
, panics if variant doesn’t match
Casts &Node
to Option<&mut nodes::Defs>
Casts &Node
to Option<&mut nodes::Dstr>
Casts &Node
to Option<&mut nodes::Dsym>
Returns true if self
is Node::EFlipFlop
Casts &Node
to Option<&nodes::EFlipFlop>
Casts &Node
to Option<&mut nodes::EFlipFlop>
Casts self
to nodes::EFlipFlop
, panics if variant doesn’t match
Returns true if self
is Node::EmptyElse
Casts &Node
to Option<&nodes::EmptyElse>
Casts &Node
to Option<&mut nodes::EmptyElse>
Casts self
to nodes::EmptyElse
, panics if variant doesn’t match
Returns true if self
is Node::Encoding
Casts &Node
to Option<&nodes::Encoding>
Casts &Node
to Option<&mut nodes::Encoding>
Casts self
to nodes::Encoding
, panics if variant doesn’t match
Casts &Node
to Option<&mut nodes::Ensure>
Casts self
to nodes::Ensure
, panics if variant doesn’t match
Casts &Node
to Option<&mut nodes::Erange>
Casts self
to nodes::Erange
, panics if variant doesn’t match
Casts &Node
to Option<&mut nodes::False>
Casts self
to nodes::False
, panics if variant doesn’t match
Casts &Node
to Option<&mut nodes::File>
Returns true if self
is Node::FindPattern
Casts &Node
to Option<&nodes::FindPattern>
Casts &Node
to Option<&mut nodes::FindPattern>
Casts self
to nodes::FindPattern
, panics if variant doesn’t match
Casts &Node
to Option<&mut nodes::Float>
Casts self
to nodes::Float
, panics if variant doesn’t match
Casts &Node
to Option<&mut nodes::For>
Returns true if self
is Node::ForwardArg
Casts &Node
to Option<&nodes::ForwardArg>
Casts &Node
to Option<&mut nodes::ForwardArg>
Casts self
to nodes::ForwardArg
, panics if variant doesn’t match
Returns true if self
is Node::ForwardedArgs
Casts &Node
to Option<&nodes::ForwardedArgs>
Casts &Node
to Option<&mut nodes::ForwardedArgs>
Casts self
to nodes::ForwardedArgs
, panics if variant doesn’t match
Casts &Node
to Option<&mut nodes::Gvar>
Casts &Node
to Option<&mut nodes::Gvasgn>
Casts self
to nodes::Gvasgn
, panics if variant doesn’t match
Casts &Node
to Option<&mut nodes::Hash>
Casts &Node
to Option<&mut nodes::Kwargs>
Casts self
to nodes::Kwargs
, panics if variant doesn’t match
Returns true if self
is Node::HashPattern
Casts &Node
to Option<&nodes::HashPattern>
Casts &Node
to Option<&mut nodes::HashPattern>
Casts self
to nodes::HashPattern
, panics if variant doesn’t match
Returns true if self
is Node::Heredoc
Casts &Node
to Option<&nodes::Heredoc>
Casts &Node
to Option<&mut nodes::Heredoc>
Casts self
to nodes::Heredoc
, panics if variant doesn’t match
Returns true if self
is Node::IfGuard
Casts &Node
to Option<&nodes::IfGuard>
Casts &Node
to Option<&mut nodes::IfGuard>
Casts self
to nodes::IfGuard
, panics if variant doesn’t match
Casts &Node
to Option<&mut nodes::IfMod>
Casts self
to nodes::IfMod
, panics if variant doesn’t match
Returns true if self
is Node::IfTernary
Casts &Node
to Option<&nodes::IfTernary>
Casts &Node
to Option<&mut nodes::IfTernary>
Casts self
to nodes::IfTernary
, panics if variant doesn’t match
Returns true if self
is Node::IFlipFlop
Casts &Node
to Option<&nodes::IFlipFlop>
Casts &Node
to Option<&mut nodes::IFlipFlop>
Casts self
to nodes::IFlipFlop
, panics if variant doesn’t match
Returns true if self
is Node::MatchPattern
Casts &Node
to Option<&nodes::MatchPattern>
Casts &Node
to Option<&mut nodes::MatchPattern>
Casts self
to nodes::MatchPattern
, panics if variant doesn’t match
Returns true if self
is Node::MatchPatternP
Casts &Node
to Option<&nodes::MatchPatternP>
Casts &Node
to Option<&mut nodes::MatchPatternP>
Casts self
to nodes::MatchPatternP
, panics if variant doesn’t match
Returns true if self
is Node::InPattern
Casts &Node
to Option<&nodes::InPattern>
Casts &Node
to Option<&mut nodes::InPattern>
Casts self
to nodes::InPattern
, panics if variant doesn’t match
Casts &Node
to Option<&mut nodes::Index>
Casts self
to nodes::Index
, panics if variant doesn’t match
Returns true if self
is Node::IndexAsgn
Casts &Node
to Option<&nodes::IndexAsgn>
Casts &Node
to Option<&mut nodes::IndexAsgn>
Casts self
to nodes::IndexAsgn
, panics if variant doesn’t match
Casts &Node
to Option<&mut nodes::Int>
Casts &Node
to Option<&mut nodes::Irange>
Casts self
to nodes::Irange
, panics if variant doesn’t match
Casts &Node
to Option<&mut nodes::Ivar>
Casts &Node
to Option<&mut nodes::Ivasgn>
Casts self
to nodes::Ivasgn
, panics if variant doesn’t match
Casts &Node
to Option<&mut nodes::Kwarg>
Casts self
to nodes::Kwarg
, panics if variant doesn’t match
Returns true if self
is Node::KwBegin
Casts &Node
to Option<&nodes::KwBegin>
Casts &Node
to Option<&mut nodes::KwBegin>
Casts self
to nodes::KwBegin
, panics if variant doesn’t match
Returns true if self
is Node::Kwnilarg
Casts &Node
to Option<&nodes::Kwnilarg>
Casts &Node
to Option<&mut nodes::Kwnilarg>
Casts self
to nodes::Kwnilarg
, panics if variant doesn’t match
Returns true if self
is Node::Kwoptarg
Casts &Node
to Option<&nodes::Kwoptarg>
Casts &Node
to Option<&mut nodes::Kwoptarg>
Casts self
to nodes::Kwoptarg
, panics if variant doesn’t match
Returns true if self
is Node::Kwrestarg
Casts &Node
to Option<&nodes::Kwrestarg>
Casts &Node
to Option<&mut nodes::Kwrestarg>
Casts self
to nodes::Kwrestarg
, panics if variant doesn’t match
Returns true if self
is Node::Kwsplat
Casts &Node
to Option<&nodes::Kwsplat>
Casts &Node
to Option<&mut nodes::Kwsplat>
Casts self
to nodes::Kwsplat
, panics if variant doesn’t match
Casts &Node
to Option<&mut nodes::Lambda>
Casts self
to nodes::Lambda
, panics if variant doesn’t match
Casts &Node
to Option<&mut nodes::Line>
Casts &Node
to Option<&mut nodes::Lvar>
Casts &Node
to Option<&mut nodes::Lvasgn>
Casts self
to nodes::Lvasgn
, panics if variant doesn’t match
Casts &Node
to Option<&mut nodes::Masgn>
Casts self
to nodes::Masgn
, panics if variant doesn’t match
Returns true if self
is Node::MatchAlt
Casts &Node
to Option<&nodes::MatchAlt>
Casts &Node
to Option<&mut nodes::MatchAlt>
Casts self
to nodes::MatchAlt
, panics if variant doesn’t match
Returns true if self
is Node::MatchAs
Casts &Node
to Option<&nodes::MatchAs>
Casts &Node
to Option<&mut nodes::MatchAs>
Casts self
to nodes::MatchAs
, panics if variant doesn’t match
Returns true if self
is Node::MatchCurrentLine
Casts &Node
to Option<&nodes::MatchCurrentLine>
Casts &Node
to Option<&mut nodes::MatchCurrentLine>
Casts self
to nodes::MatchCurrentLine
, panics if variant doesn’t match
Returns true if self
is Node::MatchNilPattern
Casts &Node
to Option<&nodes::MatchNilPattern>
Casts &Node
to Option<&mut nodes::MatchNilPattern>
Casts self
to nodes::MatchNilPattern
, panics if variant doesn’t match
Returns true if self
is Node::MatchRest
Casts &Node
to Option<&nodes::MatchRest>
Casts &Node
to Option<&mut nodes::MatchRest>
Casts self
to nodes::MatchRest
, panics if variant doesn’t match
Returns true if self
is Node::MatchVar
Casts &Node
to Option<&nodes::MatchVar>
Casts &Node
to Option<&mut nodes::MatchVar>
Casts self
to nodes::MatchVar
, panics if variant doesn’t match
Returns true if self
is Node::MatchWithLvasgn
Casts &Node
to Option<&nodes::MatchWithLvasgn>
Casts &Node
to Option<&mut nodes::MatchWithLvasgn>
Casts self
to nodes::MatchWithLvasgn
, panics if variant doesn’t match
Casts &Node
to Option<&mut nodes::Mlhs>
Casts &Node
to Option<&mut nodes::Module>
Casts self
to nodes::Module
, panics if variant doesn’t match
Casts &Node
to Option<&mut nodes::Next>
Casts &Node
to Option<&mut nodes::Nil>
Returns true if self
is Node::NthRef
Casts &Node
to Option<&nodes::NthRef>
Casts &Node
to Option<&mut nodes::NthRef>
Casts self
to nodes::NthRef
, panics if variant doesn’t match
Returns true if self
is Node::Numblock
Casts &Node
to Option<&nodes::Numblock>
Casts &Node
to Option<&mut nodes::Numblock>
Casts self
to nodes::Numblock
, panics if variant doesn’t match
Returns true if self
is Node::OpAsgn
Casts &Node
to Option<&nodes::OpAsgn>
Casts &Node
to Option<&mut nodes::OpAsgn>
Casts self
to nodes::OpAsgn
, panics if variant doesn’t match
Casts &Node
to Option<&mut nodes::Optarg>
Casts self
to nodes::Optarg
, panics if variant doesn’t match
Returns true if self
is Node::OrAsgn
Casts &Node
to Option<&nodes::OrAsgn>
Casts &Node
to Option<&mut nodes::OrAsgn>
Casts self
to nodes::OrAsgn
, panics if variant doesn’t match
Casts &Node
to Option<&mut nodes::Pair>
Casts &Node
to Option<&mut nodes::Pin>
Returns true if self
is Node::Postexe
Casts &Node
to Option<&nodes::Postexe>
Casts &Node
to Option<&mut nodes::Postexe>
Casts self
to nodes::Postexe
, panics if variant doesn’t match
Casts &Node
to Option<&mut nodes::Preexe>
Casts self
to nodes::Preexe
, panics if variant doesn’t match
Returns true if self
is Node::Procarg0
Casts &Node
to Option<&nodes::Procarg0>
Casts &Node
to Option<&mut nodes::Procarg0>
Casts self
to nodes::Procarg0
, panics if variant doesn’t match
Returns true if self
is Node::Rational
Casts &Node
to Option<&nodes::Rational>
Casts &Node
to Option<&mut nodes::Rational>
Casts self
to nodes::Rational
, panics if variant doesn’t match
Casts &Node
to Option<&mut nodes::Redo>
Returns true if self
is Node::RegOpt
Casts &Node
to Option<&nodes::RegOpt>
Casts &Node
to Option<&mut nodes::RegOpt>
Casts self
to nodes::RegOpt
, panics if variant doesn’t match
Casts &Node
to Option<&mut nodes::Regexp>
Casts self
to nodes::Regexp
, panics if variant doesn’t match
Casts &Node
to Option<&mut nodes::Rescue>
Casts self
to nodes::Rescue
, panics if variant doesn’t match
Returns true if self
is Node::RescueBody
Casts &Node
to Option<&nodes::RescueBody>
Casts &Node
to Option<&mut nodes::RescueBody>
Casts self
to nodes::RescueBody
, panics if variant doesn’t match
Returns true if self
is Node::Restarg
Casts &Node
to Option<&nodes::Restarg>
Casts &Node
to Option<&mut nodes::Restarg>
Casts self
to nodes::Restarg
, panics if variant doesn’t match
Casts &Node
to Option<&mut nodes::Retry>
Casts self
to nodes::Retry
, panics if variant doesn’t match
Casts &Node
to Option<&mut nodes::Return>
Casts self
to nodes::Return
, panics if variant doesn’t match
Returns true if self
is Node::SClass
Casts &Node
to Option<&nodes::SClass>
Casts &Node
to Option<&mut nodes::SClass>
Casts self
to nodes::SClass
, panics if variant doesn’t match
Casts &Node
to Option<&mut nodes::Self_>
Casts &Node
to Option<&mut nodes::Send>
Returns true if self
is Node::Shadowarg
Casts &Node
to Option<&nodes::Shadowarg>
Casts &Node
to Option<&mut nodes::Shadowarg>
Casts self
to nodes::Shadowarg
, panics if variant doesn’t match
Casts &Node
to Option<&mut nodes::Splat>
Casts self
to nodes::Splat
, panics if variant doesn’t match
Casts &Node
to Option<&mut nodes::Str>
Casts &Node
to Option<&mut nodes::Super>
Casts self
to nodes::Super
, panics if variant doesn’t match
Casts &Node
to Option<&mut nodes::Sym>
Casts &Node
to Option<&mut nodes::True>
Casts &Node
to Option<&mut nodes::Undef>
Casts self
to nodes::Undef
, panics if variant doesn’t match
Returns true if self
is Node::UnlessGuard
Casts &Node
to Option<&nodes::UnlessGuard>
Casts &Node
to Option<&mut nodes::UnlessGuard>
Casts self
to nodes::UnlessGuard
, panics if variant doesn’t match
Casts &Node
to Option<&mut nodes::Until>
Casts self
to nodes::Until
, panics if variant doesn’t match
Returns true if self
is Node::UntilPost
Casts &Node
to Option<&nodes::UntilPost>
Casts &Node
to Option<&mut nodes::UntilPost>
Casts self
to nodes::UntilPost
, panics if variant doesn’t match
Casts &Node
to Option<&mut nodes::When>
Casts &Node
to Option<&mut nodes::While>
Casts self
to nodes::While
, panics if variant doesn’t match
Returns true if self
is Node::WhilePost
Casts &Node
to Option<&nodes::WhilePost>
Casts &Node
to Option<&mut nodes::WhilePost>
Casts self
to nodes::WhilePost
, panics if variant doesn’t match
Returns true if self
is Node::XHeredoc
Casts &Node
to Option<&nodes::XHeredoc>
Casts &Node
to Option<&mut nodes::XHeredoc>
Casts self
to nodes::XHeredoc
, panics if variant doesn’t match
Casts &Node
to Option<&mut nodes::Xstr>
Casts &Node
to Option<&mut nodes::Yield>
Casts self
to nodes::Yield
, panics if variant doesn’t match
Returns true if self
is Node::ZSuper
Casts &Node
to Option<&nodes::ZSuper>
Casts &Node
to Option<&mut nodes::ZSuper>
Casts self
to nodes::ZSuper
, panics if variant doesn’t match
Returs a whitequark/parser -like representation of self
.
Used in tests and example scripts
Returns location of the full node expression
Returns a whitequark/parser -like node name.
Used in tests and example scripts
Prints itself + location information
Trait Implementations
Auto Trait Implementations
impl RefUnwindSafe for Node
impl UnwindSafe for Node
Blanket Implementations
Mutably borrows from an owned value. Read more