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

Side by Side Diff: Source/core/inspector/InspectorDebuggerAgent.cpp

Issue 849333003: DevTools: remove async operation's AsyncCallChain when the operation is complete (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2010 Apple Inc. All rights reserved. 2 * Copyright (C) 2010 Apple Inc. All rights reserved.
3 * Copyright (C) 2013 Google Inc. All rights reserved. 3 * Copyright (C) 2013 Google Inc. All rights reserved.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions 6 * modification, are permitted provided that the following conditions
7 * are met: 7 * are met:
8 * 8 *
9 * 1. Redistributions of source code must retain the above copyright 9 * 1. Redistributions of source code must retain the above copyright
10 * notice, this list of conditions and the following disclaimer. 10 * notice, this list of conditions and the following disclaimer.
(...skipping 1118 matching lines...) Expand 10 before | Expand all | Expand 10 after
1129 scriptDebugServer().setPauseOnNextStatement(true); 1129 scriptDebugServer().setPauseOnNextStatement(true);
1130 } else { 1130 } else {
1131 if (m_currentAsyncCallChain) 1131 if (m_currentAsyncCallChain)
1132 ++m_nestedAsyncCallCount; 1132 ++m_nestedAsyncCallCount;
1133 } 1133 }
1134 } 1134 }
1135 1135
1136 void InspectorDebuggerAgent::traceAsyncOperationCompleted(int operationId) 1136 void InspectorDebuggerAgent::traceAsyncOperationCompleted(int operationId)
1137 { 1137 {
1138 ASSERT(operationId > 0 || operationId == unknownAsyncOperationId); 1138 ASSERT(operationId > 0 || operationId == unknownAsyncOperationId);
1139 if (operationId > 0) {
1140 m_asyncOperations.remove(operationId);
1141 m_asyncOperationsForStepInto.remove(operationId);
1142 }
1139 if (!m_performingAsyncStepIn) 1143 if (!m_performingAsyncStepIn)
1140 return; 1144 return;
1141 if (operationId > 0)
1142 m_asyncOperationsForStepInto.remove(operationId);
1143 if (!m_inAsyncOperationForStepInto && m_asyncOperationsForStepInto.isEmpty() ) 1145 if (!m_inAsyncOperationForStepInto && m_asyncOperationsForStepInto.isEmpty() )
1144 clearStepIntoAsync(); 1146 clearStepIntoAsync();
1145 } 1147 }
1146 1148
1147 void InspectorDebuggerAgent::resetAsyncCallTracker() 1149 void InspectorDebuggerAgent::resetAsyncCallTracker()
1148 { 1150 {
1149 m_currentAsyncCallChain.clear(); 1151 m_currentAsyncCallChain.clear();
1150 m_nestedAsyncCallCount = 0; 1152 m_nestedAsyncCallCount = 0;
1151 for (auto& listener: m_asyncCallTrackingListeners) 1153 for (auto& listener: m_asyncCallTrackingListeners)
1152 listener->resetAsyncOperations(); 1154 listener->resetAsyncOperations();
(...skipping 395 matching lines...) Expand 10 before | Expand all | Expand 10 after
1548 visitor->trace(m_v8AsyncCallTracker); 1550 visitor->trace(m_v8AsyncCallTracker);
1549 visitor->trace(m_promiseTracker); 1551 visitor->trace(m_promiseTracker);
1550 visitor->trace(m_asyncOperationsForStepInto); 1552 visitor->trace(m_asyncOperationsForStepInto);
1551 visitor->trace(m_currentAsyncCallChain); 1553 visitor->trace(m_currentAsyncCallChain);
1552 visitor->trace(m_asyncCallTrackingListeners); 1554 visitor->trace(m_asyncCallTrackingListeners);
1553 #endif 1555 #endif
1554 InspectorBaseAgent::trace(visitor); 1556 InspectorBaseAgent::trace(visitor);
1555 } 1557 }
1556 1558
1557 } // namespace blink 1559 } // namespace blink
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698