Class: Aspen::CustomGrammar::AST::Nodes::Expression

Inherits:
Object
  • Object
show all
Defined in:
lib/aspen/custom_grammar/ast/nodes/expression.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(segments = []) ⇒ Expression

Returns a new instance of Expression.



9
10
11
# File 'lib/aspen/custom_grammar/ast/nodes/expression.rb', line 9

def initialize(segments=[])
  @segments = segments
end

Instance Attribute Details

#segmentsObject (readonly)

Returns the value of attribute segments.



7
8
9
# File 'lib/aspen/custom_grammar/ast/nodes/expression.rb', line 7

def segments
  @segments
end