Class: Potter::AST::Variable

Inherits:
Node
  • Object
show all
Defined in:
lib/potter/ast/variable.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from Node

#eql?, #hash, #symbol, #visit

Constructor Details

#initialize(name) ⇒ Variable

Returns a new instance of Variable.



6
7
8
# File 'lib/potter/ast/variable.rb', line 6

def initialize(name)
  @name = name
end

Instance Attribute Details

#nameObject (readonly)

Returns the value of attribute name.



4
5
6
# File 'lib/potter/ast/variable.rb', line 4

def name
  @name
end