Regexp backreferences

Paul Biggar pbiggar at
Tue Aug 9 13:41:32 PDT 2011

[apologies for the duplicate post on test262@, my first attempt
bounced on es-discuss@]

Hi folks,

Currently in SpiderMonkey, overlarge regex backreferences do not cause
syntax errors. We are considering making them cause syntax errors for
test262 compliance, but are worried it will break the web.

As far as I can tell, we inherited our behaviour from Apple's Yarr,
which took the behaviour from us, who originally copied IE back when
that was important. Chrome does the same as us.

Does anyone have any idea or data as to whether this will break the
web? If no such data exists, we can always just try it and see if it
breaks things. Should this be removed form test262?


Firefox bug:

test262 test cases:

Paul Biggar
Compiler Geek
pbiggar at

More information about the es-discuss mailing list