Regexp backreferences

Paul Biggar pbiggar at mozilla.com
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?

Thanks,
Paul


Firefox bug:
 https://bugzilla.mozilla.org/show_bug.cgi?id=413155


test262 test cases:
   http://hg.ecmascript.org/tests/test262/file/034836894a85/test/suite/sputnik_converted/15_Native/15.10_RegExp_Objects/15.10.2_Pattern_Semantics/15.10.2.11_DecimalEscape/S15.10.2.11_A1_T2.js

   http://hg.ecmascript.org/tests/test262/file/034836894a85/test/suite/sputnik_converted/15_Native/15.10_RegExp_Objects/15.10.2_Pattern_Semantics/15.10.2.11_DecimalEscape/S15.10.2.11_A1_T3.js


--
Paul Biggar
Compiler Geek
pbiggar at mozilla.com
@paulbiggar


More information about the es-discuss mailing list