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

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

Issue 2680303002: Kernel debugging; service tests (Closed)
Patch Set: New failing test Created 3 years, 10 months 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
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 "vm/object.h" 5 #include "vm/object.h"
6 6
7 #include "include/dart_api.h" 7 #include "include/dart_api.h"
8 #include "platform/assert.h" 8 #include "platform/assert.h"
9 #include "vm/assembler.h" 9 #include "vm/assembler.h"
10 #include "vm/become.h" 10 #include "vm/become.h"
(...skipping 9101 matching lines...) Expand 10 before | Expand all | Expand 10 after
9112 } else { 9112 } else {
9113 min = midpoint; 9113 min = midpoint;
9114 } 9114 }
9115 } 9115 }
9116 *line = min + 1; 9116 *line = min + 1;
9117 smi ^= line_starts_array.At(min); 9117 smi ^= line_starts_array.At(min);
9118 if (column != NULL) { 9118 if (column != NULL) {
9119 *column = offset - smi.Value() + 1; 9119 *column = offset - smi.Value() + 1;
9120 } 9120 }
9121 if (token_len != NULL) { 9121 if (token_len != NULL) {
9122 // We don't explicitly save this data. 9122 // We don't explicitly save this data: Load the source
9123 // TODO(jensj): Load the source and attempt to find it from there. 9123 // and find it from there.
9124 const String& source = String::Handle(zone, Source());
9125 ASSERT(source.Length() >= offset);
9124 *token_len = 1; 9126 *token_len = 1;
9127 for (intptr_t i = offset + 1; i < source.Length(); ++i, ++*token_len) {
9128 uint16_t c = source.CharAt(i);
9129 if ((c >= 'A' && c <= 'Z') || (c >= 'a' && c <= 'z') ||
Kevin Millikin (Google) 2017/02/08 15:37:53 This is Scanner::IsIdentChar(c), isn't it?
jensj 2017/02/13 14:04:17 Yes, but that's private.
9130 (c >= '0' && c <= '9') || c == '_' || c == '$') {
9131 continue;
9132 }
9133 break;
9134 }
9125 } 9135 }
9126 return; 9136 return;
9127 } 9137 }
9128 9138
9129 const TokenStream& tkns = TokenStream::Handle(zone, tokens()); 9139 const TokenStream& tkns = TokenStream::Handle(zone, tokens());
9130 if (tkns.IsNull()) { 9140 if (tkns.IsNull()) {
9131 ASSERT((Dart::vm_snapshot_kind() == Snapshot::kAppAOT)); 9141 ASSERT((Dart::vm_snapshot_kind() == Snapshot::kAppAOT));
9132 *line = -1; 9142 *line = -1;
9133 if (column != NULL) { 9143 if (column != NULL) {
9134 *column = -1; 9144 *column = -1;
(...skipping 13624 matching lines...) Expand 10 before | Expand all | Expand 10 after
22759 return UserTag::null(); 22769 return UserTag::null();
22760 } 22770 }
22761 22771
22762 22772
22763 const char* UserTag::ToCString() const { 22773 const char* UserTag::ToCString() const {
22764 const String& tag_label = String::Handle(label()); 22774 const String& tag_label = String::Handle(label());
22765 return tag_label.ToCString(); 22775 return tag_label.ToCString();
22766 } 22776 }
22767 22777
22768 } // namespace dart 22778 } // namespace dart
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698