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

Unified Diff: src/isolate.cc

Issue 2633443002: [promisehook] Pass deferred promise to Before/After callback (Closed)
Patch Set: Remove adaptor Created 3 years, 11 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.cc ('k') | src/objects.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/isolate.cc
diff --git a/src/isolate.cc b/src/isolate.cc
index f620897922f3088458139ddcd5e7acaad22644d0..59ee355c667ee458dd307fa337e3b48788f33c2e 100644
--- a/src/isolate.cc
+++ b/src/isolate.cc
@@ -3295,7 +3295,6 @@ void Isolate::PromiseReactionJob(Handle<PromiseReactionJobInfo> info,
MaybeHandle<Object>* maybe_exception) {
PromiseDebugEventScope helper(this, info->debug_id(), info->debug_name());
- Handle<JSPromise> promise(info->promise(), this);
Handle<Object> value(info->value(), this);
Handle<Object> tasks(info->tasks(), this);
Handle<JSFunction> promise_handle_fn = promise_handle();
@@ -3312,9 +3311,7 @@ void Isolate::PromiseReactionJob(Handle<PromiseReactionJobInfo> info,
FixedArray::cast(info->deferred_on_reject()), this);
Handle<FixedArray> tasks_arr = Handle<FixedArray>::cast(tasks);
for (int i = 0; i < deferred_promise_arr->length(); i++) {
- Handle<Object> argv[] = {promise,
- value,
- handle(tasks_arr->get(i), this),
+ Handle<Object> argv[] = {value, handle(tasks_arr->get(i), this),
handle(deferred_promise_arr->get(i), this),
handle(deferred_on_resolve_arr->get(i), this),
handle(deferred_on_reject_arr->get(i), this)};
@@ -3326,10 +3323,7 @@ void Isolate::PromiseReactionJob(Handle<PromiseReactionJobInfo> info,
}
}
} else {
- Handle<Object> argv[] = {promise,
- value,
- tasks,
- deferred_promise,
+ Handle<Object> argv[] = {value, tasks, deferred_promise,
handle(info->deferred_on_resolve(), this),
handle(info->deferred_on_reject(), this)};
*result = Execution::TryCall(this, promise_handle_fn, undefined,
« no previous file with comments | « src/factory.cc ('k') | src/objects.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698