OLD | NEW |
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 1187 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1198 if (!m_asyncCallStackTracker.isEnabled()) | 1198 if (!m_asyncCallStackTracker.isEnabled()) |
1199 return nullptr; | 1199 return nullptr; |
1200 const AsyncCallStackTracker::AsyncCallChain* chain = m_asyncCallStackTracker
.currentAsyncCallChain(); | 1200 const AsyncCallStackTracker::AsyncCallChain* chain = m_asyncCallStackTracker
.currentAsyncCallChain(); |
1201 if (!chain) | 1201 if (!chain) |
1202 return nullptr; | 1202 return nullptr; |
1203 const AsyncCallStackTracker::AsyncCallStackVector& callStacks = chain->callS
tacks(); | 1203 const AsyncCallStackTracker::AsyncCallStackVector& callStacks = chain->callS
tacks(); |
1204 if (callStacks.isEmpty()) | 1204 if (callStacks.isEmpty()) |
1205 return nullptr; | 1205 return nullptr; |
1206 RefPtrWillBeRawPtr<ScriptAsyncCallStack> result = nullptr; | 1206 RefPtrWillBeRawPtr<ScriptAsyncCallStack> result = nullptr; |
1207 for (AsyncCallStackTracker::AsyncCallStackVector::const_reverse_iterator it
= callStacks.rbegin(); it != callStacks.rend(); ++it) { | 1207 for (AsyncCallStackTracker::AsyncCallStackVector::const_reverse_iterator it
= callStacks.rbegin(); it != callStacks.rend(); ++it) { |
1208 RefPtrWillBeRawPtr<JavaScriptCallFrame> callFrame = ScriptDebugServer::t
oJavaScriptCallFrame((*it)->callFrames()); | 1208 RefPtrWillBeRawPtr<JavaScriptCallFrame> callFrame = ScriptDebugServer::t
oJavaScriptCallFrameUnsafe((*it)->callFrames()); |
1209 if (!callFrame) | 1209 if (!callFrame) |
1210 break; | 1210 break; |
1211 result = ScriptAsyncCallStack::create((*it)->description(), toScriptCall
Stack(callFrame.get()), result.release()); | 1211 result = ScriptAsyncCallStack::create((*it)->description(), toScriptCall
Stack(callFrame.get()), result.release()); |
1212 } | 1212 } |
1213 return result.release(); | 1213 return result.release(); |
1214 } | 1214 } |
1215 | 1215 |
1216 String InspectorDebuggerAgent::sourceMapURLForScript(const Script& script, Compi
leResult compileResult) | 1216 String InspectorDebuggerAgent::sourceMapURLForScript(const Script& script, Compi
leResult compileResult) |
1217 { | 1217 { |
1218 bool hasSyntaxError = compileResult != CompileSuccess; | 1218 bool hasSyntaxError = compileResult != CompileSuccess; |
(...skipping 208 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1427 { | 1427 { |
1428 m_scripts.clear(); | 1428 m_scripts.clear(); |
1429 m_breakpointIdToDebugServerBreakpointIds.clear(); | 1429 m_breakpointIdToDebugServerBreakpointIds.clear(); |
1430 m_asyncCallStackTracker.clear(); | 1430 m_asyncCallStackTracker.clear(); |
1431 if (m_frontend) | 1431 if (m_frontend) |
1432 m_frontend->globalObjectCleared(); | 1432 m_frontend->globalObjectCleared(); |
1433 } | 1433 } |
1434 | 1434 |
1435 } // namespace blink | 1435 } // namespace blink |
1436 | 1436 |
OLD | NEW |