Class: Rubinius::AST::ConstantAccess

Inherits:
Node
  • Object
show all
Defined in:
lib/compiler/ast/constants.rb

Instance Attribute Summary collapse

Attributes inherited from Node

#line

Instance Method Summary collapse

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, name) ⇒ ConstantAccess

Returns a new instance of ConstantAccess.



46
47
48
49
# File 'lib/compiler/ast/constants.rb', line 46

def initialize(line, name)
  @line = line
  @name = name
end

Instance Attribute Details

#nameObject

Returns the value of attribute name.



44
45
46
# File 'lib/compiler/ast/constants.rb', line 44

def name
  @name
end

Instance Method Details

#assign_sexpObject



51
52
53
# File 'lib/compiler/ast/constants.rb', line 51

def assign_sexp
  @name
end

#to_sexpObject



55
56
57
# File 'lib/compiler/ast/constants.rb', line 55

def to_sexp
  [:const, @name]
end