jviereck / regjsparser

Parsing the JavaScript's RegExp in JavaScript.
http://www.julianviereck.de/regjsparser/
BSD 2-Clause "Simplified" License
77 stars 20 forks source link

disallow quantifiable anchors in unicode mode #135

Closed JLHwung closed 10 months ago

JLHwung commented 1 year ago

Fixes #134

/cc @mathiasbynens @nicolo-ribaudo

It seems to me that the spec does not disallow quantified +/- lookahead in unicode sets mode, as is in unicode mode:

https://tc39.es/ecma262/#prod-annexB-Assertion

But both JSC and V8 disallow such productions. It seems to me an oversight in the spec.

nicolo-ribaudo commented 11 months ago

In unicode sets mode, the UnicodeMode flag is enabled: https://tc39.es/ecma262/#sec-parsepattern

nicolo-ribaudo commented 10 months ago

@jviereck Could we get a release? :)

JLHwung commented 2 months ago

@jviereck Could you release this patch? Many thanks.