mozilla/rhino — pull request #13 by mguillem (2011-10-13 10:09:02+00:00)
Title: Parsing error with EOL + comment in place of semicolon

code like this
var s = 3
/* */var t = 1;
can't be parsed. Exception below is thrown. Pull request contains unit test + fix.

junit.framework.AssertionFailedError: extra error: missing ; before statement
at junit.framework.Assert.fail(Assert.java:47)
at org.mozilla.javascript.testing.TestErrorReporter.error(TestErrorReporter.java:38)
at org.mozilla.javascript.Parser.addError(Parser.java:230)
at org.mozilla.javascript.Parser.addError(Parser.java:208)
at org.mozilla.javascript.Parser.reportError(Parser.java:265)
at org.mozilla.javascript.Parser.reportError(Parser.java:252)
at org.mozilla.javascript.Parser.reportError(Parser.java:245)
at org.mozilla.javascript.Parser.autoInsertSemicolon(Parser.java:1109)
at org.mozilla.javascript.Parser.statementHelper(Parser.java:1086)
at org.mozilla.javascript.Parser.statement(Parser.java:943)
at org.mozilla.javascript.Parser.parse(Parser.java:568)
at org.mozilla.javascript.Parser.parse(Parser.java:530)
at org.mozilla.javascript.tests.ParserTest.parseAsReader(ParserTest.java:977)
at org.mozilla.javascript.tests.ParserTest.testParseAutoSemiColonBeforeNewlineAndComments(ParserTest.java:34)