--> is a valid HTML close comment when it appears on the first line of a script (Annex B). Boa rejects it unconditionally with SyntaxError.
Repro (raw script, no preceding newline):
--> this is a comment
throw new EvalError("reached");
Expected: EvalError thrown — the --> line is treated as a comment, execution continues to the next line
Got: SyntaxError
Spec: https://tc39.es/ecma262/#sec-html-like-comments
HTMLCloseComment ::
WhiteSpaceSequence[opt] SingleLineDelimitedCommentSequence[opt] --> SingleLineCommentChars[opt]
Failing test262: annexB/language/comments/single-line-html-close-first-line-{1,2,3}.js
-->is a valid HTML close comment when it appears on the first line of a script (Annex B). Boa rejects it unconditionally withSyntaxError.Repro (raw script, no preceding newline):
Expected:
EvalErrorthrown — the-->line is treated as a comment, execution continues to the next lineGot:
SyntaxErrorSpec: https://tc39.es/ecma262/#sec-html-like-comments
Failing test262:
annexB/language/comments/single-line-html-close-first-line-{1,2,3}.js