Represents an xstring literal that contains interpolation.
`foo #{bar} baz` ^^^^^^^^^^^^^^^^
Represents a keyword rest parameter to a method, block, or lambda definition.
def a(**b) ^^^ end
Represents using a lambda literal (not the lambda method call).
->(value) { value * 2 } ^^^^^^^^^^^^^^^^^^^^^^^
Represents a regular expression literal used in the predicate of a conditional to implicitly match against the last line read by an IO
object.
if /foo/i then end ^^^^^^
Represents writing local variables using a regular expression match with named capture groups.
/(?<foo>bar)/ =~ baz ^^^^^^^^^^^^^^^^^^^^
Represents a node that is missing from the source and results in a syntax error.
Represents the use of ‘**nil` inside method arguments.
def a(**nil) ^^^^^ end
Represents an implicit set of parameters through the use of numbered parameters within a block or lambda.
-> { _1 + _2 } ^^^^^^^^^^^^^^
Represents the use of the ‘||` operator or the `or` keyword.
left or right ^^^^^^^^^^^^^
Represents the list of parameters on a method, block, or lambda definition.
def a(b, c, d) ^^^^^^^ end
The top level node of any parse tree.
Represents the use of the ‘..` or `…` operators.
1..2 ^^^^ c if a =~ /left/ ... b =~ /right/ ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Represents a required keyword parameter to a method, block, or lambda definition.
def a(b: ) ^^ end
Represents a required parameter to a method, block, or lambda definition.
def a(b) ^ end
Represents a rescue statement.
begin rescue Foo, *splat, Bar => ex foo ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ end
‘Foo, *splat, Bar` are in the `exceptions` field. `ex` is in the `exception` field.
Represents a rest parameter to a method, block, or lambda definition.
def a(*b) ^^ end