/\1/ could be a valid RegExp through Chapter 16 Extension clause?

Dave Fugate dfugate at microsoft.com
Wed Jul 6 16:35:31 PDT 2011

                var x = /\1/;

According to, the RegExp snippet above should throw something as there aren't any capturing parenthesis within the RegExp, yet one is referenced.  Just now noticed that step 4 of is more precise and shows a SyntaxError gets thrown.  Isn't the snippet then potentially valid ES5 code through Chapter 16's SyntaxError extension clause?



-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.mozilla.org/pipermail/es-discuss/attachments/20110706/1d03eebf/attachment.html>

More information about the es-discuss mailing list