Changeset 267559 in webkit
- Timestamp:
- Sep 24, 2020, 10:40:25 PM (6 years ago)
- Location:
- trunk
- Files:
-
- 4 edited
-
JSTests/ChangeLog (modified) (1 diff)
-
JSTests/test262/expectations.yaml (modified) (1 diff)
-
Source/JavaScriptCore/ChangeLog (modified) (1 diff)
-
Source/JavaScriptCore/builtins/TypedArrayPrototype.js (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/JSTests/ChangeLog
r267554 r267559 1 2020-09-24 Ross Kirsling <ross.kirsling@sony.com> 2 3 %TypedArray%.prototype.toLocaleString must make conscious use of @toString 4 https://bugs.webkit.org/show_bug.cgi?id=216956 5 6 Reviewed by Yusuke Suzuki. 7 8 * test262/expectations.yaml: 9 Mark four test cases as passing. 10 1 11 2020-09-24 Ross Kirsling <ross.kirsling@sony.com> 2 12 -
trunk/JSTests/test262/expectations.yaml
r267554 r267559 1252 1252 default: 'TypeError: Underlying ArrayBuffer has been detached from the view (Testing with Float64Array.)' 1253 1253 strict mode: 'TypeError: Underlying ArrayBuffer has been detached from the view (Testing with Float64Array.)' 1254 test/built-ins/TypedArray/prototype/toLocaleString/calls-tostring-from-each-value.js:1255 default: 'Test262Error: should not call valueOf if toString is present (Testing with Float64Array.)'1256 strict mode: 'Test262Error: should not call valueOf if toString is present (Testing with Float64Array.)'1257 test/built-ins/TypedArray/prototype/toLocaleString/calls-valueof-from-each-value.js:1258 default: 'Test262Error: returns expected value Expected SameValue(«hacks2,hacks1», «hacks1,hacks2») to be true (Testing with Float64Array.)'1259 strict mode: 'Test262Error: returns expected value Expected SameValue(«hacks2,hacks1», «hacks1,hacks2») to be true (Testing with Float64Array.)'1260 1254 test/built-ins/TypedArrayConstructors/ctors/buffer-arg/byteoffset-to-number-detachbuffer.js: 1261 1255 default: 'Test262Error: Expected a TypeError but got a RangeError (Testing with Float64Array.)' -
trunk/Source/JavaScriptCore/ChangeLog
r267554 r267559 1 2020-09-24 Ross Kirsling <ross.kirsling@sony.com> 2 3 %TypedArray%.prototype.toLocaleString must make conscious use of @toString 4 https://bugs.webkit.org/show_bug.cgi?id=216956 5 6 Reviewed by Yusuke Suzuki. 7 8 A fascinating bug: if we override Number.prototype.toLocaleString to return { valueOf() { ... } }, 9 then we can observe our %TypedArray%.prototype.toLocaleString resolving its element values in the wrong order. 10 11 * builtins/TypedArrayPrototype.js: 12 (toLocaleString): 13 Wrap the toLocaleString call for each element in @toString(), as the spec indicates. 14 1 15 2020-09-24 Ross Kirsling <ross.kirsling@sony.com> 2 16 -
trunk/Source/JavaScriptCore/builtins/TypedArrayPrototype.js
r267554 r267559 365 365 return ""; 366 366 367 var string = this[0].toLocaleString(@argument(0), @argument(1));367 var string = @toString(this[0].toLocaleString(@argument(0), @argument(1))); 368 368 for (var i = 1; i < length; i++) 369 string += "," + this[i].toLocaleString(@argument(0), @argument(1));369 string += "," + @toString(this[i].toLocaleString(@argument(0), @argument(1))); 370 370 371 371 return string;
Note:
See TracChangeset
for help on using the changeset viewer.