[Webkit-unassigned] [Bug 8395] New: RegEx seems broken for this example

bugzilla-daemon at opendarwin.org bugzilla-daemon at opendarwin.org
Fri Apr 14 13:57:37 PDT 2006


http://bugzilla.opendarwin.org/show_bug.cgi?id=8395

           Summary: RegEx seems broken for this example
           Product: WebKit
           Version: 420+ (nightly)
          Platform: Macintosh
        OS/Version: Mac OS X 10.4
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: WebCore JavaScript
        AssignedTo: webkit-unassigned at opendarwin.org
        ReportedBy: jason at bakafish.com


The RegEx engine is not behaving correctly for special characters (Octal
escaped   anyway.)
This shouldn't match \s according to the info I have read, which makes sense,
but this script works fine in the current Release version.



<html><head>
<script type="text/javascript" language="javascript1.2">
<!--
   var text = "foo";
   var nbsp = "\xa0";
   alert("Orig: (" + text + ")");
   text = text + nbsp + nbsp + nbsp;
   alert("After: (" + text + ")");
   var re = new RegExp(/\xa0*$/);
   text = text.replace(re,'');
   alert("Stripped: (" + text + ")");   
//-->
</script>
</head>
<body></body>
</html>


-- 
Configure bugmail: http://bugzilla.opendarwin.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.



More information about the webkit-unassigned mailing list