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

Unified Diff: Source/core/inspector/InjectedScriptSource.js

Issue 466243002: Support merged Dart-JS callstacks (Closed) Base URL: svn://svn.chromium.org/blink/branches/dart/dartium
Patch Set: Created 6 years, 4 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
Index: Source/core/inspector/InjectedScriptSource.js
diff --git a/Source/core/inspector/InjectedScriptSource.js b/Source/core/inspector/InjectedScriptSource.js
index 8c5cc460f4a6b4b56a89be75c385c0c793bfaffa..1018e458e143cc39de15d1e1e872aeac3d8370f0 100644
--- a/Source/core/inspector/InjectedScriptSource.js
+++ b/Source/core/inspector/InjectedScriptSource.js
@@ -976,7 +976,13 @@ InjectedScript.prototype = {
_callFrameForParsedId: function(topCallFrame, parsedCallFrameId, asyncCallStacks)
{
var asyncOrdinal = parsedCallFrameId["asyncOrdinal"]; // 1-based index
- if (asyncOrdinal)
+ // FIXMEDART: change this next line back to
+ // if (asyncOrdinal)
+ // once we can remove the hack of giving JavaScript callframes from
+ // mixed Dart-JavaScript call stacks ordinal -1 to trigger the
+ // safer code path used to simulate evaluating code on the call frame
+ // for async call frames.
+ if (asyncOrdinal >= 1)
topCallFrame = asyncCallStacks[asyncOrdinal - 1];
var ordinal = parsedCallFrameId["ordinal"];
var callFrame = topCallFrame;

Powered by Google App Engine
This is Rietveld 408576698