Class: Rubinius::AST::CollectSplat
- Defined in:
- lib/compiler/ast/sends.rb
Instance Attribute Summary
Attributes inherited from Node
Instance Method Summary collapse
-
#initialize(line, *parts) ⇒ CollectSplat
constructor
A new instance of CollectSplat.
- #to_sexp ⇒ Object
Methods inherited from Node
#ascii_graph, #attributes, #children, match_arguments?, match_send?, #new_block_generator, #new_generator, #node_name, node_name, #pos, #set_child, transform, #transform, transform_comment, transform_kind, transform_kind=, transform_name, #visit, #walk
Constructor Details
#initialize(line, *parts) ⇒ CollectSplat
Returns a new instance of CollectSplat.
184 185 186 187 188 189 |
# File 'lib/compiler/ast/sends.rb', line 184 def initialize(line, *parts) @line = line @splat = parts.shift @last = parts.pop @array = parts end |
Instance Method Details
#to_sexp ⇒ Object
191 192 193 |
# File 'lib/compiler/ast/sends.rb', line 191 def to_sexp [:collect_splat] + @parts.map { |x| x.to_sexp } end |