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

Side by Side Diff: runtime/lib/mirrors_impl.dart

Issue 12282038: Remove deprecated string features. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Merge to head Created 7 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 | Annotate | Revision Log
« no previous file with comments | « runtime/lib/integers_patch.dart ('k') | runtime/lib/string.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 // VM-specific implementation of the dart:mirrors library. 5 // VM-specific implementation of the dart:mirrors library.
6 6
7 // These values are allowed to be passed directly over the wire. 7 // These values are allowed to be passed directly over the wire.
8 bool _isSimpleValue(var value) { 8 bool _isSimpleValue(var value) {
9 return (value == null || value is num || value is String || value is bool); 9 return (value == null || value is num || value is String || value is bool);
10 } 10 }
(...skipping 226 matching lines...) Expand 10 before | Expand all | Expand 10 after
237 case '\b' : 237 case '\b' :
238 output = r'\b'; 238 output = r'\b';
239 break; 239 break;
240 case '\t' : 240 case '\t' :
241 output = r'\t'; 241 output = r'\t';
242 break; 242 break;
243 case '\v' : 243 case '\v' :
244 output = r'\v'; 244 output = r'\v';
245 break; 245 break;
246 default: 246 default:
247 int code = input.charCodeAt(0); 247 // TODO(lrn): Someone decide if this should combine surrogate pairs.
248 int code = input.codeUnitAt(0);
248 if (isNice(code)) { 249 if (isNice(code)) {
249 output = input; 250 output = input;
250 } else { 251 } else {
251 output = '\\u{${code.toRadixString(16)}}'; 252 output = '\\u{${code.toRadixString(16)}}';
252 } 253 }
253 break; 254 break;
254 } 255 }
255 buf.add(output); 256 buf.add(output);
256 } 257 }
257 return buf.toString(); 258 return buf.toString();
(...skipping 706 matching lines...) Expand 10 before | Expand all | Expand 10 after
964 965
965 // Creates a new local InstanceMirror 966 // Creates a new local InstanceMirror
966 static InstanceMirror makeLocalInstanceMirror(Object reflectee) 967 static InstanceMirror makeLocalInstanceMirror(Object reflectee)
967 native 'Mirrors_makeLocalInstanceMirror'; 968 native 'Mirrors_makeLocalInstanceMirror';
968 969
969 // Creates a new local mirror for some Object. 970 // Creates a new local mirror for some Object.
970 static InstanceMirror reflect(Object reflectee) { 971 static InstanceMirror reflect(Object reflectee) {
971 return makeLocalInstanceMirror(reflectee); 972 return makeLocalInstanceMirror(reflectee);
972 } 973 }
973 } 974 }
OLDNEW
« no previous file with comments | « runtime/lib/integers_patch.dart ('k') | runtime/lib/string.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698