rubyx/stash/vm/tree/while_statement.rb
Torsten Ruger 5fe0ba06ab stash old vm
moving on to getting mom to work and can’t have both
interpreter and elf broke, about 100 tests  went
2018-03-11 17:02:42 +05:30

12 lines
262 B
Ruby

module Vm
module Tree
class WhileStatement < Statement
attr_accessor :branch_type , :condition , :statements
def to_s
str = "while_#{branch_type}(#{condition}) do\n"
str + statements.to_s + "\nend\n"
end
end
end
end