https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102447

Jonathan Wakely <redi at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         Resolution|INVALID                     |---
             Status|RESOLVED                    |NEW

--- Comment #4 from Jonathan Wakely <redi at gcc dot gnu.org> ---
Reopening. JavaScript engines in web browsers accept invalid regexes for legacy
support:
https://262.ecma-international.org/#sec-additional-ecmascript-features-for-web-browsers

If we're not implementing a browser engine, then it should be a syntax error:

 NonemptyClassRanges :: ClassAtom - ClassAtom ClassRanges

    It is a Syntax Error if IsCharacterClass of the first ClassAtom is true or
IsCharacterClass of the second ClassAtom is true.

    It is a Syntax Error if IsCharacterClass of the first ClassAtom is false
and IsCharacterClass of the second ClassAtom is false and the CharacterValue of
the first ClassAtom is larger than the CharacterValue of the second ClassAtom.

Reply via email to