Index: src/runtime/runtime-internal.cc |
diff --git a/src/runtime/runtime-internal.cc b/src/runtime/runtime-internal.cc |
index d9113753d03b2b20b1cdb86348bbd1eacdae7969..6e6445c85bc6fa0ea25610276f99943fa765f463 100644 |
--- a/src/runtime/runtime-internal.cc |
+++ b/src/runtime/runtime-internal.cc |
@@ -224,6 +224,13 @@ RUNTIME_FUNCTION(Runtime_ThrowSymbolIteratorInvalid) { |
isolate, NewTypeError(MessageTemplate::kSymbolIteratorInvalid)); |
} |
+RUNTIME_FUNCTION(Runtime_ThrowSymbolAsyncIteratorInvalid) { |
+ HandleScope scope(isolate); |
+ DCHECK(args.length() == 0); |
+ THROW_NEW_ERROR_RETURN_FAILURE( |
+ isolate, NewTypeError(MessageTemplate::kSymbolAsyncIteratorInvalid)); |
+} |
+ |
RUNTIME_FUNCTION(Runtime_ThrowNotGeneric) { |
HandleScope scope(isolate); |
DCHECK_EQ(1, args.length()); |
@@ -494,5 +501,20 @@ RUNTIME_FUNCTION(Runtime_Typeof) { |
return *Object::TypeOf(isolate, object); |
} |
+RUNTIME_FUNCTION(Runtime_CreateAsyncFromSyncIterator) { |
+ HandleScope scope(isolate); |
+ DCHECK_EQ(1, args.length()); |
+ |
+ CONVERT_ARG_HANDLE_CHECKED(Object, sync_iterator, 0); |
+ |
+ if (!sync_iterator->IsJSReceiver()) { |
+ THROW_NEW_ERROR_RETURN_FAILURE( |
+ isolate, NewTypeError(MessageTemplate::kSymbolIteratorInvalid)); |
+ } |
+ |
+ return *isolate->factory()->NewJSAsyncFromSyncIterator( |
+ Handle<HeapObject>::cast(sync_iterator)); |
+} |
+ |
} // namespace internal |
} // namespace v8 |