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

Unified Diff: src/inspector/v8-debugger.cc

Issue 2628173005: [inspector] merged type and name of async task event (Closed)
Patch Set: addressed comments 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/isolate.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/inspector/v8-debugger.cc
diff --git a/src/inspector/v8-debugger.cc b/src/inspector/v8-debugger.cc
index a6b1219bc6ce027f4f51eefb774b9ceb2c5dba46..95605d0ce98a34af51b6abd92877e05b04ec7de2 100644
--- a/src/inspector/v8-debugger.cc
+++ b/src/inspector/v8-debugger.cc
@@ -610,11 +610,6 @@ void V8Debugger::handleV8AsyncTaskEvent(v8::Local<v8::Object> eventData) {
->ToInteger(m_isolate->GetCurrentContext())
.ToLocalChecked()
->Value());
- String16 name = toProtocolStringWithTypeCheck(
- eventData
- ->Get(m_isolate->GetCurrentContext(),
- toV8StringInternalized(m_isolate, "name_"))
- .ToLocalChecked());
int id = static_cast<int>(eventData
->Get(m_isolate->GetCurrentContext(),
toV8StringInternalized(m_isolate, "id_"))
@@ -627,10 +622,19 @@ void V8Debugger::handleV8AsyncTaskEvent(v8::Local<v8::Object> eventData) {
// namespace of such ids, managed by src/js/promise.js.
void* ptr = reinterpret_cast<void*>(id * 2 + 1);
switch (type) {
- case v8::debug::kDebugEnqueueRecurring:
- asyncTaskScheduled(name, ptr, true);
+ case v8::debug::kDebugEnqueueAsyncFunction:
+ asyncTaskScheduled("async function", ptr, true);
+ break;
+ case v8::debug::kDebugEnqueuePromiseResolve:
+ asyncTaskScheduled("Promise.resolve", ptr, true);
+ break;
+ case v8::debug::kDebugEnqueuePromiseReject:
+ asyncTaskScheduled("Promise.reject", ptr, true);
+ break;
+ case v8::debug::kDebugEnqueuePromiseResolveThenableJob:
+ asyncTaskScheduled("PromiseResolveThenableJob", ptr, true);
break;
- case v8::debug::kDebugCancel:
+ case v8::debug::kDebugPromiseCollected:
asyncTaskCanceled(ptr);
break;
case v8::debug::kDebugWillHandle:
« no previous file with comments | « src/factory.cc ('k') | src/isolate.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698