Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(208)

Unified Diff: src/factory.cc

Issue 2314903004: [promises] Move PromiseResolveThenableJob to c++ (Closed)
Patch Set: Created 4 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/factory.h ('k') | src/isolate.h » ('j') | src/objects.h » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/factory.cc
diff --git a/src/factory.cc b/src/factory.cc
index 400e15e5c97ddb4fc132baba1b630e7414953787..d231c625a8c035dae2420f45289a8d0fd7e436dc 100644
--- a/src/factory.cc
+++ b/src/factory.cc
@@ -91,7 +91,6 @@ Handle<Box> Factory::NewBox(Handle<Object> value) {
return result;
}
-
Handle<PrototypeInfo> Factory::NewPrototypeInfo() {
Handle<PrototypeInfo> result =
Handle<PrototypeInfo>::cast(NewStruct(PROTOTYPE_INFO_TYPE));
@@ -889,6 +888,18 @@ Handle<Struct> Factory::NewStruct(InstanceType type) {
Struct);
}
+Handle<PromiseContainer> Factory::NewPromiseContainer(
+ Handle<Object> promise, Handle<Object> thenable, Handle<JSFunction> then,
+ Handle<JSFunction> resolve, Handle<JSFunction> reject) {
+ Handle<PromiseContainer> result =
+ Handle<PromiseContainer>::cast(NewStruct(PROMISE_CONTAINER_TYPE));
+ result->set_promise(*promise);
+ result->set_thenable(*thenable);
+ result->set_then(*then);
+ result->set_resolve(*resolve);
+ result->set_reject(*reject);
+ return result;
+}
Handle<AliasedArgumentsEntry> Factory::NewAliasedArgumentsEntry(
int aliased_context_slot) {
« no previous file with comments | « src/factory.h ('k') | src/isolate.h » ('j') | src/objects.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698