move vool statements into own directory

also tests for guard to work
This commit is contained in:
Torsten Ruger
2017-04-06 19:11:11 +03:00
parent 3fe286b5ed
commit db8f99409b
30 changed files with 29 additions and 27 deletions

View File

@ -1,17 +0,0 @@
module Vool
class WhileStatement < Statement
attr_reader :condition , :statements
def initialize( condition , statements )
@condition = condition
@statements = statements
simplify_condition
end
def simplify_condition
return unless @condition.is_a?(ScopeStatement)
@condition = @condition.first if @condition.single?
end
end
end