JavaScriptCore:
authorddkilzer <ddkilzer@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sat, 3 Jun 2006 04:56:56 +0000 (04:56 +0000)
committerddkilzer <ddkilzer@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sat, 3 Jun 2006 04:56:56 +0000 (04:56 +0000)
commit2d2c4b80675244259d3d36c565457d378d8f7f0e
tree659b0db0e94586547785063031f93ca88e77a94f
parent011c69daac3484406b2f12c536ae8d7e14595838
JavaScriptCore:

        Reviewed by ggaren.

        - http://bugzilla.opendarwin.org/show_bug.cgi?id=9234
          Implement $&, $' and $` replacement codes in String.prototype.replace

        Test: fast/js/string-replace-3.html

        * kjs/string_object.cpp:
        (substituteBackreferences): Added support for $& (matched substring),
        $` (everything preceding matched substring), $' (everything following
        matched substring) and 2-digit back references, and cleaned up a little.

LayoutTests:

        Reviewed by ggaren.

        - test for http://bugzilla.opendarwin.org/show_bug.cgi?id=9234
          Implement $&, $' and $` replacement codes in String.prototype.replace

        * fast/js/resources/string-replace-3.js: Added.
        * fast/js/string-replace-3-expected.txt: Added.
        * fast/js/string-replace-3.html: Added.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@14705 268f45cc-cd09-0410-ab3c-d52691b4dbfc
JavaScriptCore/ChangeLog
JavaScriptCore/kjs/string_object.cpp
LayoutTests/ChangeLog
LayoutTests/fast/js/resources/string-replace-3.js [new file with mode: 0644]
LayoutTests/fast/js/string-replace-3-expected.txt [new file with mode: 0644]
LayoutTests/fast/js/string-replace-3.html [new file with mode: 0644]