| OLD | NEW |
| 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 "vm/debugger.h" | 5 #include "vm/debugger.h" |
| 6 | 6 |
| 7 #include "vm/code_generator.h" | 7 #include "vm/code_generator.h" |
| 8 #include "vm/code_patcher.h" | 8 #include "vm/code_patcher.h" |
| 9 #include "vm/compiler.h" | 9 #include "vm/compiler.h" |
| 10 #include "vm/dart_entry.h" | 10 #include "vm/dart_entry.h" |
| (...skipping 749 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 760 | 760 |
| 761 | 761 |
| 762 void Debugger::SetExceptionPauseInfo(Dart_ExceptionPauseInfo pause_info) { | 762 void Debugger::SetExceptionPauseInfo(Dart_ExceptionPauseInfo pause_info) { |
| 763 ASSERT((pause_info == kNoPauseOnExceptions) || | 763 ASSERT((pause_info == kNoPauseOnExceptions) || |
| 764 (pause_info == kPauseOnUnhandledExceptions) || | 764 (pause_info == kPauseOnUnhandledExceptions) || |
| 765 (pause_info == kPauseOnAllExceptions)); | 765 (pause_info == kPauseOnAllExceptions)); |
| 766 exc_pause_info_ = pause_info; | 766 exc_pause_info_ = pause_info; |
| 767 } | 767 } |
| 768 | 768 |
| 769 | 769 |
| 770 Dart_ExceptionPauseInfo Debugger::GetExceptionPauseInfo() { |
| 771 return (Dart_ExceptionPauseInfo)exc_pause_info_; |
| 772 } |
| 773 |
| 774 |
| 770 // TODO(hausner): Determine whether the exception is handled or not. | 775 // TODO(hausner): Determine whether the exception is handled or not. |
| 771 bool Debugger::ShouldPauseOnException(DebuggerStackTrace* stack_trace, | 776 bool Debugger::ShouldPauseOnException(DebuggerStackTrace* stack_trace, |
| 772 const Object& exc) { | 777 const Object& exc) { |
| 773 if (exc_pause_info_ == kNoPauseOnExceptions) { | 778 if (exc_pause_info_ == kNoPauseOnExceptions) { |
| 774 return false; | 779 return false; |
| 775 } | 780 } |
| 776 if ((exc_pause_info_ & kPauseOnAllExceptions) != 0) { | 781 if ((exc_pause_info_ & kPauseOnAllExceptions) != 0) { |
| 777 return true; | 782 return true; |
| 778 } | 783 } |
| 779 // Assume TypeError and AssertionError exceptions are unhandled. | 784 // Assume TypeError and AssertionError exceptions are unhandled. |
| (...skipping 786 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1566 } | 1571 } |
| 1567 | 1572 |
| 1568 | 1573 |
| 1569 void Debugger::RegisterCodeBreakpoint(CodeBreakpoint* bpt) { | 1574 void Debugger::RegisterCodeBreakpoint(CodeBreakpoint* bpt) { |
| 1570 ASSERT(bpt->next() == NULL); | 1575 ASSERT(bpt->next() == NULL); |
| 1571 bpt->set_next(code_breakpoints_); | 1576 bpt->set_next(code_breakpoints_); |
| 1572 code_breakpoints_ = bpt; | 1577 code_breakpoints_ = bpt; |
| 1573 } | 1578 } |
| 1574 | 1579 |
| 1575 } // namespace dart | 1580 } // namespace dart |
| OLD | NEW |