Changeset 252766 in webkit
- Timestamp:
- Nov 22, 2019 1:39:04 AM (4 years ago)
- Location:
- trunk
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/JSTests/ChangeLog
r252765 r252766 1 2019-11-21 Mark Lam <mark.lam@apple.com> 2 3 replaceUsingStringSearch() should not use CachedCall with host functions. 4 https://bugs.webkit.org/show_bug.cgi?id=204494 5 <rdar://problem/57421078> 6 7 Reviewed by Ross Kirsling. 8 9 * stress/string-replaceAll-2.js: 10 1 11 2019-11-21 Ross Kirsling <ross.kirsling@sony.com> 2 12 -
trunk/JSTests/stress/string-replaceAll-2.js
r252758 r252766 108 108 { result: '51525352545', visits: 6 }, // replace /(?:)/g 109 109 { result: '51525352545', visits: 6 }, // replaceAll '' 110 { result: '12324', visits: 0 }, // replace '0' 111 { result: '12324', visits: 0 }, // replace /0/g 112 { result: '12324', visits: 0 }, // replaceAll '0' 113 ]); 114 115 test("function parseInt", parseInt, [ 116 { result: '1NaN324', visits: 0 }, // replace '2' 117 { result: '1NaN324', visits: 0 }, // replace /2/g 118 { result: '1NaN324', visits: 0 }, // replaceAll '2' 119 { result: 'NaN12324', visits: 0 }, // replace '' 120 { result: 'NaN1NaN2NaN3NaN2NaN4NaN', visits: 0 }, // replace /(?:)/g 121 { result: 'NaN1NaN2NaN3NaN2NaN4NaN', visits: 0 }, // replaceAll '' 110 122 { result: '12324', visits: 0 }, // replace '0' 111 123 { result: '12324', visits: 0 }, // replace /0/g -
trunk/Source/JavaScriptCore/ChangeLog
r252763 r252766 1 2019-11-21 Mark Lam <mark.lam@apple.com> 2 3 replaceUsingStringSearch() should not use CachedCall with host functions. 4 https://bugs.webkit.org/show_bug.cgi?id=204494 5 <rdar://problem/57421078> 6 7 Reviewed by Ross Kirsling. 8 9 The CachedCall mechanism does not support calling hist functions. 10 11 * runtime/StringPrototype.cpp: 12 (JSC::replaceUsingStringSearch): 13 1 14 2019-11-21 Saam Barati <sbarati@apple.com> 2 15 -
trunk/Source/JavaScriptCore/runtime/StringPrototype.cpp
r252758 r252766 794 794 replaceString = replaceValue.toWTFString(globalObject); 795 795 RETURN_IF_EXCEPTION(scope, nullptr); 796 } else { 797 JSFunction* function = jsDynamicCast<JSFunction*>(vm, replaceValue); 798 if (function) { 799 cachedCall.emplace(globalObject, callFrame, function, 3); 800 cachedCall->setThis(jsUndefined()); 801 } 796 } else if (callType == CallType::JS) { 797 cachedCall.emplace(globalObject, callFrame, jsCast<JSFunction*>(replaceValue), 3); 798 cachedCall->setThis(jsUndefined()); 802 799 } 803 800
Note: See TracChangeset
for help on using the changeset viewer.