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

Unified Diff: runtime/lib/integers_patch.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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « runtime/bin/process_patch.dart ('k') | runtime/lib/mirrors_impl.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/lib/integers_patch.dart
diff --git a/runtime/lib/integers_patch.dart b/runtime/lib/integers_patch.dart
index c6485ab2d6020098e5e5efacdb960c1c2c16c56f..fdbd4f9bd2f28039fc3a338d8155e0008e9bccdb 100644
--- a/runtime/lib/integers_patch.dart
+++ b/runtime/lib/integers_patch.dart
@@ -50,12 +50,12 @@ patch class int {
];
int i = 0;
- int code = source.charCodeAt(i);
+ int code = source.codeUnitAt(i);
if (code == 0x2d || code == 0x2b) { // Starts with a plus or minus-sign.
negative = (code == 0x2d);
if (source.length == 1) return onError(source);
i = 1;
- code = source.charCodeAt(i);
+ code = source.codeUnitAt(i);
}
do {
if (code < 0x30 || code > 0x7f) return onError(source);
@@ -64,7 +64,7 @@ patch class int {
result = result * radix + digit;
i++;
if (i == source.length) break;
- code = source.charCodeAt(i);
+ code = source.codeUnitAt(i);
} while (true);
return negative ? -result : result;
}
« no previous file with comments | « runtime/bin/process_patch.dart ('k') | runtime/lib/mirrors_impl.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698