Explorar el Código

LibJS: Explicitly provide all GetIterator arguments from Intl.ListFormat

This is an editorial change in the ECMA-402 spec. See:
https://github.com/tc39/ecma402/commit/13895c8
Timothy Flynn hace 2 años
padre
commit
b74786d3c3
Se han modificado 1 ficheros con 2 adiciones y 2 borrados
  1. 2 2
      Userland/Libraries/LibJS/Runtime/Intl/ListFormat.cpp

+ 2 - 2
Userland/Libraries/LibJS/Runtime/Intl/ListFormat.cpp

@@ -247,8 +247,8 @@ ThrowCompletionOr<Vector<String>> string_list_from_iterable(VM& vm, Value iterab
         return Vector<String> {};
     }
 
-    // 2. Let iteratorRecord be ? GetIterator(iterable).
-    auto iterator_record = TRY(get_iterator(vm, iterable));
+    // 2. Let iteratorRecord be ? GetIterator(iterable, sync).
+    auto iterator_record = TRY(get_iterator(vm, iterable, IteratorHint::Sync));
 
     // 3. Let list be a new empty List.
     Vector<String> list;