Index: runtime/vm/debugger.cc |
diff --git a/runtime/vm/debugger.cc b/runtime/vm/debugger.cc |
index 05ecbcbdb5b33d7d8ee58ecc9bbd19f1a16c572f..e51b6057161b2ef99908598a1fe1f3c1e5e90025 100644 |
--- a/runtime/vm/debugger.cc |
+++ b/runtime/vm/debugger.cc |
@@ -2275,6 +2275,27 @@ void Debugger::SignalBpReached() { |
} |
+void Debugger::ExplicitBreakpoint() { |
hausner
2015/05/05 00:16:27
SignalDebugBreak() ?
Cutch
2015/05/05 02:38:53
I went with BreakHere and changed the behaviour. P
|
+ // We ignore this breakpoint when the VM is executing code invoked |
+ // by the debugger to evaluate variables values, or when we see a nested |
+ // breakpoint or exception event. |
+ if (ignore_breakpoints_ || IsPaused() || !HasEventHandler()) { |
+ return; |
+ } |
+ |
+ DebuggerStackTrace* stack_trace = CollectStackTrace(); |
+ ASSERT(stack_trace->Length() > 0); |
+ ActivationFrame* top_frame = stack_trace->FrameAt(0); |
+ ASSERT(top_frame != NULL); |
+ |
+ ASSERT(stack_trace_ == NULL); |
+ stack_trace_ = stack_trace; |
+ SignalPausedEvent(top_frame, NULL); |
+ HandleSteppingRequest(stack_trace_); |
+ stack_trace_ = NULL; |
+} |
+ |
+ |
void Debugger::Initialize(Isolate* isolate) { |
if (initialized_) { |
return; |