Class: Oryx::Contractor

Inherits:
RLTK::CG::Contractor
  • Object
show all
Defined in:
lib/oryx/contractor.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeContractor

Returns a new instance of Contractor.



16
17
18
19
20
21
# File 'lib/oryx/contractor.rb', line 16

def initialize
  super
  @module = RLTK::CG::Module.new('Oryx JIT')
  @st = SymbolTable.new
  @branch_needed = true
end

Instance Attribute Details

#moduleObject (readonly)

Returns the value of attribute module.



14
15
16
# File 'lib/oryx/contractor.rb', line 14

def module
  @module
end

#stObject (readonly)

Returns the value of attribute st.



14
15
16
# File 'lib/oryx/contractor.rb', line 14

def st
  @st
end

Instance Method Details

#begin(ast) ⇒ Object



23
24
25
# File 'lib/oryx/contractor.rb', line 23

def begin ast
  ast.each {|a| dispatch a}
end