Fix parser order

This commit is contained in:
Glenn Y. Rolland 2017-09-12 17:53:24 +02:00
parent e76e11535d
commit a5236a9af8

View file

@ -149,10 +149,6 @@ module Mm2ep
ex.value = BoolValue.new(l.value.to_s) ex.value = BoolValue.new(l.value.to_s)
end end
rule 'expr : NOT_OP expr %prec UMINUS' do |ex, l, e|
ex.value = NotOp.new(e.value)
end
rule 'expr : expr OR_OP expr' do |ex, l, e, r| rule 'expr : expr OR_OP expr' do |ex, l, e, r|
ex.value = OrOp.new(l.value, r.value) ex.value = OrOp.new(l.value, r.value)
end end
@ -165,6 +161,10 @@ module Mm2ep
ex.value = e.value ex.value = e.value
end end
rule 'expr : NOT_OP expr %prec UMINUS' do |ex, l, e|
ex.value = NotOp.new(e.value)
end
rule 'expr : VAR EQ_OP F_BOOL' do |ex, v, eq, n| rule 'expr : VAR EQ_OP F_BOOL' do |ex, v, eq, n|
ex.value = EqOp.new( ex.value = EqOp.new(
VarValue.new(v.value.to_s), VarValue.new(v.value.to_s),