Treetop seems to ignore turther rules after the first and fails to parse anything that doesn't match the first rule on the grammar file. I already tried to swap the order of the rules, but still, only the first one is considered.
# grammar_pov.treetop
grammar Pov
rule numeric
'-'? [0-9]+ ('.' [0-9]+)? <::PovFabric::Nodes::NumericLiteral>
end
rule comma
','
end
rule space
[\s]+
end
end
This grammar file matches all integer and floats, but doesn't match '123, 456' or '123,456' The parser failure_reason property says this 'Expected - at line 1, column 1 (byte 1) after '
Am i missing something?