Class: P2::ConstTagNode

Inherits:
Object
  • Object
show all
Defined in:
lib/p2/compiler/nodes.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(call_node, translator) ⇒ ConstTagNode

Returns a new instance of ConstTagNode.



97
98
99
100
# File 'lib/p2/compiler/nodes.rb', line 97

def initialize(call_node, translator)
  @call_node = call_node
  @location = call_node.location
end

Instance Attribute Details

#call_nodeObject (readonly)

Returns the value of attribute call_node.



95
96
97
# File 'lib/p2/compiler/nodes.rb', line 95

def call_node
  @call_node
end

#locationObject (readonly)

Returns the value of attribute location.



95
96
97
# File 'lib/p2/compiler/nodes.rb', line 95

def location
  @location
end

Instance Method Details

#accept(visitor) ⇒ Object



102
103
104
# File 'lib/p2/compiler/nodes.rb', line 102

def accept(visitor)
  visitor.visit_const_tag_node(self)
end