Bug 14877 - Regexp replace halts on unicode char
Summary: Regexp replace halts on unicode char
Status: RESOLVED DUPLICATE of bug 10370
Alias: None
Product: WebKit
Classification: Unclassified
Component: JavaScriptCore (show other bugs)
Version: 523.x (Safari 3)
Hardware: Macintosh OS X 10.4
: P2 Normal
Assignee: Nobody
Keywords: HasReduction, InRadar
Depends on:
Reported: 2007-08-03 14:21 PDT by Derk-Jan Hartman
Modified: 2007-11-04 03:20 PST (History)
2 users (show)

See Also:

testcase by bdash (146 bytes, text/html)
2007-08-03 14:23 PDT, Derk-Jan Hartman
no flags Details
Original case (1.17 KB, text/html)
2007-08-03 14:26 PDT, Derk-Jan Hartman
no flags Details
Improved test case (284 bytes, text/html)
2007-08-03 14:54 PDT, Mark Rowe (bdash)
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Derk-Jan Hartman 2007-08-03 14:21:54 PDT
2 testcases attached
Comment 1 Derk-Jan Hartman 2007-08-03 14:23:58 PDT
Created attachment 15828 [details]
testcase by bdash
Comment 2 Derk-Jan Hartman 2007-08-03 14:26:16 PDT
Created attachment 15830 [details]
Original case
Comment 3 Derk-Jan Hartman 2007-08-03 14:37:32 PDT
Issue is also present in Safari 2.0.4 (419.3)
Comment 4 Mark Rowe (bdash) 2007-08-03 14:53:01 PDT
The issue is probably narrower in scope than the title suggests.  In this specific example the character class [\s\S] should match any single character (\s is the set of all whitespace characters, \S is the set of non-whitespace characters).  For some reason this is not correctly matching LEFTWARDS ARROW.

It would be interesting to know whether other character classes exhibit this issue, and whether other Unicode characters do too.
Comment 5 Mark Rowe (bdash) 2007-08-03 14:54:00 PDT
Created attachment 15833 [details]
Improved test case
Comment 6 Mark Rowe (bdash) 2007-08-03 14:55:10 PDT
Comment 7 Alexey Proskuryakov 2007-08-03 23:37:42 PDT
See also: bug 10370 (duplicate?).
Comment 8 Alexey Proskuryakov 2007-11-04 03:20:57 PST

*** This bug has been marked as a duplicate of 10370 ***