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

Unified Diff: src/js/async-await.js

Issue 2578923002: [inspector] async stacks for Promise.then calls... (Closed)
Patch Set: added missing handle scope Created 4 years 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
« src/debug/debug.cc ('K') | « src/isolate.cc ('k') | src/js/promise.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/js/async-await.js
diff --git a/src/js/async-await.js b/src/js/async-await.js
index c7e90510d1c830d4e03a2b4d0bd150637a4773e6..87f3df540dc0d4186ab15574cb20adad85edebeb 100644
--- a/src/js/async-await.js
+++ b/src/js/async-await.js
@@ -133,23 +133,15 @@ function AsyncFunctionPromiseCreate() {
%DebugPushPromise(promise);
// Assign ID and create a recurring task to save stack for future
// resumptions from await.
- var id = %DebugNextMicrotaskId();
+ var id = %DebugNextAsyncTaskId(promise);
SET_PRIVATE(promise, promiseAsyncStackIDSymbol, id);
- %DebugAsyncTaskEvent("enqueueRecurring", id, "async function");
+ %DebugEnqueueRecurringAsyncTaskEvent(promise, "async function");
}
return promise;
}
function AsyncFunctionPromiseRelease(promise) {
if (DEBUG_IS_ACTIVE) {
- // Cancel
- var id = GET_PRIVATE(promise, promiseAsyncStackIDSymbol);
-
- // Don't send invalid events when catch prediction is turned on in
- // the middle of some async operation.
- if (!IS_UNDEFINED(id)) {
- %DebugAsyncTaskEvent("cancel", id, "async function");
- }
// Pop the Promise under construction in an async function on
// from catch prediction stack.
%DebugPopPromise();
« src/debug/debug.cc ('K') | « src/isolate.cc ('k') | src/js/promise.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698