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

Side by Side Diff: runtime/vm/debugger_api_impl.cc

Issue 2572563004: Improve the casing of Stackmap and Stacktrace. (Closed)
Patch Set: Build fixes 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 unified diff | Download patch
« no previous file with comments | « runtime/vm/debugger.cc ('k') | runtime/vm/disassembler.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 #include "include/dart_tools_api.h" 5 #include "include/dart_tools_api.h"
6 6
7 #include "vm/class_finalizer.h" 7 #include "vm/class_finalizer.h"
8 #include "vm/compiler.h" 8 #include "vm/compiler.h"
9 #include "vm/dart_api_impl.h" 9 #include "vm/dart_api_impl.h"
10 #include "vm/dart_api_state.h" 10 #include "vm/dart_api_state.h"
(...skipping 229 matching lines...) Expand 10 before | Expand all | Expand 10 after
240 240
241 241
242 DART_EXPORT Dart_Handle Dart_GetStackTraceFromError(Dart_Handle handle, 242 DART_EXPORT Dart_Handle Dart_GetStackTraceFromError(Dart_Handle handle,
243 Dart_StackTrace* trace) { 243 Dart_StackTrace* trace) {
244 DARTSCOPE(Thread::Current()); 244 DARTSCOPE(Thread::Current());
245 CHECK_DEBUGGER(T->isolate()); 245 CHECK_DEBUGGER(T->isolate());
246 CHECK_NOT_NULL(trace); 246 CHECK_NOT_NULL(trace);
247 const Object& obj = Object::Handle(Z, Api::UnwrapHandle(handle)); 247 const Object& obj = Object::Handle(Z, Api::UnwrapHandle(handle));
248 if (obj.IsUnhandledException()) { 248 if (obj.IsUnhandledException()) {
249 const UnhandledException& error = UnhandledException::Cast(obj); 249 const UnhandledException& error = UnhandledException::Cast(obj);
250 Stacktrace& dart_stacktrace = Stacktrace::Handle(Z); 250 StackTrace& dart_stacktrace = StackTrace::Handle(Z);
251 dart_stacktrace ^= error.stacktrace(); 251 dart_stacktrace ^= error.stacktrace();
252 if (dart_stacktrace.IsNull()) { 252 if (dart_stacktrace.IsNull()) {
253 *trace = NULL; 253 *trace = NULL;
254 } else { 254 } else {
255 Isolate* I = T->isolate(); 255 Isolate* I = T->isolate();
256 *trace = reinterpret_cast<Dart_StackTrace>( 256 *trace = reinterpret_cast<Dart_StackTrace>(
257 I->debugger()->StackTraceFrom(dart_stacktrace)); 257 I->debugger()->StackTraceFrom(dart_stacktrace));
258 } 258 }
259 return Api::Success(); 259 return Api::Success();
260 } else { 260 } else {
(...skipping 722 matching lines...) Expand 10 before | Expand all | Expand 10 after
983 983
984 #else 984 #else
985 985
986 DART_EXPORT void Dart_SetPausedEventHandler(Dart_PausedEventHandler handler) { 986 DART_EXPORT void Dart_SetPausedEventHandler(Dart_PausedEventHandler handler) {
987 // NOOP. 987 // NOOP.
988 } 988 }
989 989
990 #endif // !PRODUCT 990 #endif // !PRODUCT
991 991
992 } // namespace dart 992 } // namespace dart
OLDNEW
« no previous file with comments | « runtime/vm/debugger.cc ('k') | runtime/vm/disassembler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698