Sadly this probably isn't right, based on the fact that JRuby's grammar doesn't have this and it still parser that code ok, I think the real issue is in the lexer, it shouldn't emit a newline token at all here, since it's not meaningful.