Aaron said:
Racc doesn't actually understand how to parse anything. Someone must
write a grammar that racc uses to generate a parser.
You are seeing an error with the grammar file, not with Racc. What gem
are you using where you see this error? Can we get a larger stack
trace?
Thanks for your answer.
It comes from flog via ruby-parser (flay gives the same error):
F:/Ruby19/lib/ruby/gems/1.9.1/gems/racc-1.4.6/lib/racc/parser.rb:347:in
`on_error': (Racc:
arseError)
parse error on value "in" (kIN)
from
F:/Ruby19/lib/ruby/gems/1.9.1/gems/racc-1.4.6/lib/racc/parser.rb:99:in
`_racc_do_parse_c'
from
F:/Ruby19/lib/ruby/gems/1.9.1/gems/racc-1.4.6/lib/racc/parser.rb:99:in
`do_parse'
from
F:/Ruby19/lib/ruby/gems/1.9.1/gems/ruby_parser-2.0.4/lib/ruby_parser_extras.rb:749:in
`process'
from
F:/Ruby19/lib/ruby/gems/1.9.1/gems/flog-2.4.0/lib/flog.rb:176:in `block
in flog'
from
F:/Ruby19/lib/ruby/gems/1.9.1/gems/flog-2.4.0/lib/flog.rb:170:in `each'
from
F:/Ruby19/lib/ruby/gems/1.9.1/gems/flog-2.4.0/lib/flog.rb:170:in `flog'
from
F:/Ruby19/lib/ruby/gems/1.9.1/gems/flog-2.4.0/bin/flog:11:in `<top
(required)>'
from F:/Ruby19/bin/flog:19:in `load'
from F:/Ruby19/bin/flog:19:in `<main>'
Of course, 'in' is also a keyword. When using a key which is not a
keyword, the error happens when parsing the colon.