add more functionality to get while to work (not there yet)

This commit is contained in:
Torsten Ruger
2014-05-14 11:33:23 +03:00
parent 2230a4f25e
commit d50c38f5ad
6 changed files with 46 additions and 23 deletions

View File

@@ -16,10 +16,12 @@ module Ast
def compile context , into
cond_val = condition.compile(context , into)
#set up branches for bodies
last = nil
body.each do |part|
part.compile(context , into )
last = part.compile(context , into )
puts "compiled in while #{last.inspect}"
end
return cond_val
return last
end
end