3247c2036c
when iterating over tree. Much cleaner, less hokuspukus methods that are noops Mom is coming back out, but not linked yet
25 lines
476 B
Ruby
25 lines
476 B
Ruby
module Vool
|
|
class Statements < Statement
|
|
include Common::Statements
|
|
|
|
# create machine instructions
|
|
def to_mom( method )
|
|
all = @statements.collect { |statement| statement.to_mom( method ) }
|
|
Mom::Statements.new(all)
|
|
end
|
|
|
|
def create_objects
|
|
@statements.each{ |s| s.create_objects }
|
|
end
|
|
|
|
def each(&block)
|
|
block.call(self)
|
|
@statements.each{|a| a.each(block)}
|
|
end
|
|
|
|
end
|
|
|
|
class ScopeStatement < Statements
|
|
end
|
|
end
|