| 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 1102 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1113 const int num_vars = NumLocalVariables(); | 1113 const int num_vars = NumLocalVariables(); |
| 1114 for (intptr_t v = 0; v < num_vars; v++) { | 1114 for (intptr_t v = 0; v < num_vars; v++) { |
| 1115 String& var_name = String::Handle(); | 1115 String& var_name = String::Handle(); |
| 1116 Instance& var_value = Instance::Handle(); | 1116 Instance& var_value = Instance::Handle(); |
| 1117 intptr_t token_pos; | 1117 intptr_t token_pos; |
| 1118 intptr_t end_token_pos; | 1118 intptr_t end_token_pos; |
| 1119 VariableAt(v, &var_name, &token_pos, &end_token_pos, &var_value); | 1119 VariableAt(v, &var_name, &token_pos, &end_token_pos, &var_value); |
| 1120 if (var_name.raw() != Symbols::AsyncOperation().raw()) { | 1120 if (var_name.raw() != Symbols::AsyncOperation().raw()) { |
| 1121 JSONObject jsvar(&jsvars); | 1121 JSONObject jsvar(&jsvars); |
| 1122 jsvar.AddProperty("type", "BoundVariable"); | 1122 jsvar.AddProperty("type", "BoundVariable"); |
| 1123 var_name = String::IdentifierPrettyName(var_name); |
| 1123 jsvar.AddProperty("name", var_name.ToCString()); | 1124 jsvar.AddProperty("name", var_name.ToCString()); |
| 1124 jsvar.AddProperty("value", var_value, !full); | 1125 jsvar.AddProperty("value", var_value, !full); |
| 1125 // TODO(turnidge): Do we really want to provide this on every | 1126 // TODO(turnidge): Do we really want to provide this on every |
| 1126 // stack dump? Should be associated with the function object, I | 1127 // stack dump? Should be associated with the function object, I |
| 1127 // think, and not the stack frame. | 1128 // think, and not the stack frame. |
| 1128 jsvar.AddProperty("_tokenPos", token_pos); | 1129 jsvar.AddProperty("_tokenPos", token_pos); |
| 1129 jsvar.AddProperty("_endTokenPos", end_token_pos); | 1130 jsvar.AddProperty("_endTokenPos", end_token_pos); |
| 1130 } | 1131 } |
| 1131 } | 1132 } |
| 1132 } | 1133 } |
| (...skipping 2114 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3247 } | 3248 } |
| 3248 | 3249 |
| 3249 | 3250 |
| 3250 void Debugger::RegisterCodeBreakpoint(CodeBreakpoint* bpt) { | 3251 void Debugger::RegisterCodeBreakpoint(CodeBreakpoint* bpt) { |
| 3251 ASSERT(bpt->next() == NULL); | 3252 ASSERT(bpt->next() == NULL); |
| 3252 bpt->set_next(code_breakpoints_); | 3253 bpt->set_next(code_breakpoints_); |
| 3253 code_breakpoints_ = bpt; | 3254 code_breakpoints_ = bpt; |
| 3254 } | 3255 } |
| 3255 | 3256 |
| 3256 } // namespace dart | 3257 } // namespace dart |
| OLD | NEW |