{ and } in regexps

Allen Wirfs-Brock Allen.Wirfs-Brock at microsoft.com
Fri Nov 12 08:08:48 PST 2010


I don't think so.  See http://blogs.msdn.com/b/ie/archive/2010/08/25/chakra-interoperability-means-more-than-just-standards.aspx 

Hopefully for Harmony somebody will take on the challenge of updating the RegExp spec. to reflect reality.  We need a software archeologist to analyze the major browsers what the consensus spec. really is. 

Allen

> -----Original Message-----
> From: es-discuss-bounces at mozilla.org [mailto:es-discuss-
> bounces at mozilla.org] On Behalf Of Michael Day
> Sent: Thursday, November 11, 2010 11:59 PM
> To: ES-Discuss
> Subject: { and } in regexps
> 
> Hi,
> 
> Browsers seem to allow { and } to occur in regexps unescaped, if the position
> does not conflict with their use as a quantifier. For example:
> 
> /foo|{bar}/
> 
> However, ES3 and ES5 forbid this, as PatternCharacter does not include { or } or
> any of the other significant punctuation.
> 
> Given that every new implementation ends up having to do what all the existing
> implementations do, is there any reason for the spec to differ?
> 
> Best regards,
> 
> Michael
> 
> --
> Print XML with Prince!
> http://www.princexml.com
> _______________________________________________
> es-discuss mailing list
> es-discuss at mozilla.org
> https://mail.mozilla.org/listinfo/es-discuss



More information about the es-discuss mailing list