Index: src/factory.cc |
diff --git a/src/factory.cc b/src/factory.cc |
index e934f18054c73a33cd8eee79fb828683226f47b8..16c5feb93e22f4357740e9bc3c96e51832b38464 100644 |
--- a/src/factory.cc |
+++ b/src/factory.cc |
@@ -1680,6 +1680,16 @@ Handle<JSSetIterator> Factory::NewJSSetIterator() { |
} |
+Handle<JSIteratorResult> Factory::NewJSIteratorResult(Handle<Object> value, |
+ Handle<Object> done) { |
+ Handle<JSIteratorResult> result = Handle<JSIteratorResult>::cast( |
+ NewJSObjectFromMap(isolate()->iterator_result_map())); |
+ result->set_value(*value); |
+ result->set_done(*done); |
+ return result; |
+} |
+ |
+ |
namespace { |
ElementsKind GetExternalArrayElementsKind(ExternalArrayType type) { |