in reply to Re: baby Marpa::R2 haml Error in SLIF parse: No lexemes accepted
in thread baby Marpa::R2 haml Error in SLIF parse: No lexemes accepted

Your problem is at the following line:haml ::= comments | oneliners
Your example doesn't contain only comments or only oneliners, but a mix of both types. What you actually need is

Aha, thank you choroba . I had written /a+|b+/ instead of /(a|b)+/

For debugging, it's better to set the default rule to  :default ::= action => [name,value]

meh :D for debugging I'm using the trace options

Handling of whitespace is weird. You didn't tell Marpa there could be whitespace between the tag and the body. Either do it explicitly, or try the implicit rule

What? Why would I discard whitespace?

  • Comment on Re^2: baby Marpa::R2 haml Error in SLIF parse: No lexemes accepted
  • Download Code