Class: LibRubyParser::Nodes::Restarg
- Inherits:
-
LibRubyParser::Node
- Object
- LibRubyParser::Node
- LibRubyParser::Nodes::Restarg
- Defined in:
- lib/lib-ruby-parser/nodes.rb
Overview
Represents positional rest argument (i.e. *foo
in def m(*foo); end
)
Instance Attribute Summary collapse
-
#expression_l ⇒ Loc
readonly
Location of the full expression.
-
#name ⇒ String?
readonly
Name of the argument.
-
#name_l ⇒ Loc?
readonly
Location of the argument name.
-
#operator_l ⇒ Loc
readonly
Location of the
*
operator.
Instance Attribute Details
#expression_l ⇒ Loc (readonly)
Location of the full expression
def m(*foo); end
~~~~
3624 3625 3626 |
# File 'lib/lib-ruby-parser/nodes.rb', line 3624 def expression_l @expression_l end |
#name ⇒ String? (readonly)
Name of the argument.
None
if argument has no name (i.e. def m(*); end
)
3597 3598 3599 |
# File 'lib/lib-ruby-parser/nodes.rb', line 3597 def name @name end |
#name_l ⇒ Loc? (readonly)
Location of the argument name
def m(*foo); end
~~~
3615 3616 3617 |
# File 'lib/lib-ruby-parser/nodes.rb', line 3615 def name_l @name_l end |
#operator_l ⇒ Loc (readonly)
Location of the *
operator
def m(*foo); end
~
3606 3607 3608 |
# File 'lib/lib-ruby-parser/nodes.rb', line 3606 def operator_l @operator_l end |