The first and the last are def vaild and I've used the first as a partial
plenty of times.
Basically [[] is the same as saying /\[/ just a little bit longer, match a
single character from the set [.
/[[]/.exec('[]') -> '['
There is nothing special about /a{,,/ its just a normal match these
characters in this order.
/a{,,/.exec('a{,,') -> 'a{,,'
/[]]/ This one throws me, that should require the first ] to be escaped
(\]) to be useful. I can see it parse and accept but have no clue why or
what it would do. It should throw an error.
On Fri, Jun 3, 2016 at 3:20 AM, Isiah Meadows <[email protected]>
wrote:
> These three RegExps don't appear valid, even after reading the Annex B,
> but they do behave consistently in both Chrome and Firefox. They are listed
> here with equivalent regexps:
>
> - `/[[]/` -> `/\[\[\]/`
> - `/[]]/` -> `/(?!)/` (i.e. nothing)
> - `/a{,,/` -> `/a\{,,+/`
>
> Is this a spec bug or an implementation bug in the parsing?
>
> _______________________________________________
> es-discuss mailing list
> [email protected]
> https://mail.mozilla.org/listinfo/es-discuss
>
>
_______________________________________________
es-discuss mailing list
[email protected]
https://mail.mozilla.org/listinfo/es-discuss