Class: Vertigo::Constant

Inherits:
AstNode show all
Defined in:
lib/vertigo/ast_vertigo_rkgen.rb

Instance Attribute Summary collapse

Attributes inherited from AstNode

#label, #pos

Instance Method Summary collapse

Methods inherited from AstNode

#accept, #str

Constructor Details

#initialize(name = nil, type = nil, expr = nil) ⇒ Constant

Returns a new instance of Constant.



393
394
395
# File 'lib/vertigo/ast_vertigo_rkgen.rb', line 393

def initialize name=nil,type=nil,expr=nil
  @name,@type,@expr=name,type,expr
end

Instance Attribute Details

#exprObject

Returns the value of attribute expr.



392
393
394
# File 'lib/vertigo/ast_vertigo_rkgen.rb', line 392

def expr
  @expr
end

#nameObject

Returns the value of attribute name.



392
393
394
# File 'lib/vertigo/ast_vertigo_rkgen.rb', line 392

def name
  @name
end

#typeObject

Returns the value of attribute type.



392
393
394
# File 'lib/vertigo/ast_vertigo_rkgen.rb', line 392

def type
  @type
end