Changeset 267125 in webkit
- Timestamp:
- Sep 15, 2020 6:17:07 PM (4 years ago)
- Location:
- trunk
- Files:
-
- 1 added
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/JSTests/ChangeLog
r267115 r267125 1 2020-09-15 HyeockJin Kim <kherootz@gmail.com> 2 3 Check whether the iterator is callable in spread 4 https://bugs.webkit.org/show_bug.cgi?id=215974 5 6 Reviewed by Darin Adler. 7 8 * stress/spread-array-iterator.js: Added. 9 (shouldThrowTypeError): 10 (shouldThrowExactly): 11 (f): 12 (C): 13 1 14 2020-09-15 Yusuke Suzuki <ysuzuki@apple.com> 2 15 -
trunk/Source/JavaScriptCore/ChangeLog
r267114 r267125 1 2020-09-15 HyeockJin Kim <kherootz@gmail.com> 2 3 Check whether the iterator is callable in spread 4 https://bugs.webkit.org/show_bug.cgi?id=215974 5 6 Reviewed by Darin Adler. 7 8 * builtins/IteratorHelpers.js: 9 (performIteration): 10 1 11 2020-09-15 Tadeu Zagallo <tzagallo@apple.com> 2 12 -
trunk/Source/JavaScriptCore/builtins/IteratorHelpers.js
r257681 r267125 32 32 33 33 var result = []; 34 if (@isUndefinedOrNull(iterable)) 35 @throwTypeError('Spread syntax requires ...iterable not be null or undefined'); 36 37 var iteratorMethod = iterable.@@iterator; 38 if (!@isCallable(iteratorMethod)) 39 @throwTypeError('Spread syntax requires ...iterable[Symbol.iterator] to be a function'); 34 40 35 var iterator = itera ble.@@iterator();41 var iterator = iteratorMethod.@call(iterable); 36 42 var next = iterator.next; 37 43 var item;
Note: See TracChangeset
for help on using the changeset viewer.