| 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 "include/dart_api.h" | 7 #include "include/dart_api.h" |
| 8 | 8 |
| 9 #include "vm/code_generator.h" | 9 #include "vm/code_generator.h" |
| 10 #include "vm/code_patcher.h" | 10 #include "vm/code_patcher.h" |
| (...skipping 152 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 163 visitor->VisitPointer(reinterpret_cast<RawObject**>(&function_)); | 163 visitor->VisitPointer(reinterpret_cast<RawObject**>(&function_)); |
| 164 } | 164 } |
| 165 | 165 |
| 166 | 166 |
| 167 void SourceBreakpoint::PrintJSON(JSONStream* stream) { | 167 void SourceBreakpoint::PrintJSON(JSONStream* stream) { |
| 168 Isolate* isolate = Isolate::Current(); | 168 Isolate* isolate = Isolate::Current(); |
| 169 | 169 |
| 170 JSONObject jsobj(stream); | 170 JSONObject jsobj(stream); |
| 171 jsobj.AddProperty("type", "Breakpoint"); | 171 jsobj.AddProperty("type", "Breakpoint"); |
| 172 | 172 |
| 173 jsobj.AddPropertyF("id", "debug/breakpoints/%" Pd "", id()); | 173 jsobj.AddPropertyF("id", "breakpoints/%" Pd "", id()); |
| 174 jsobj.AddProperty("breakpointNumber", id()); | 174 jsobj.AddProperty("breakpointNumber", id()); |
| 175 jsobj.AddProperty("enabled", IsEnabled()); | 175 jsobj.AddProperty("enabled", IsEnabled()); |
| 176 jsobj.AddProperty("resolved", IsResolved()); | 176 jsobj.AddProperty("resolved", IsResolved()); |
| 177 | 177 |
| 178 Library& library = Library::Handle(isolate); | 178 Library& library = Library::Handle(isolate); |
| 179 Script& script = Script::Handle(isolate); | 179 Script& script = Script::Handle(isolate); |
| 180 intptr_t token_pos; | 180 intptr_t token_pos; |
| 181 GetCodeLocation(&library, &script, &token_pos); | 181 GetCodeLocation(&library, &script, &token_pos); |
| 182 { | 182 { |
| 183 JSONObject location(&jsobj, "location"); | 183 JSONObject location(&jsobj, "location"); |
| (...skipping 2444 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2628 } | 2628 } |
| 2629 | 2629 |
| 2630 | 2630 |
| 2631 void Debugger::RegisterCodeBreakpoint(CodeBreakpoint* bpt) { | 2631 void Debugger::RegisterCodeBreakpoint(CodeBreakpoint* bpt) { |
| 2632 ASSERT(bpt->next() == NULL); | 2632 ASSERT(bpt->next() == NULL); |
| 2633 bpt->set_next(code_breakpoints_); | 2633 bpt->set_next(code_breakpoints_); |
| 2634 code_breakpoints_ = bpt; | 2634 code_breakpoints_ = bpt; |
| 2635 } | 2635 } |
| 2636 | 2636 |
| 2637 } // namespace dart | 2637 } // namespace dart |
| OLD | NEW |