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

Side by Side Diff: pkg/analyzer/lib/src/generated/java_core.dart

Issue 689383005: Fix for issue 20796 (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Fixed missed case Created 6 years, 1 month 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 | « no previous file | pkg/analyzer/lib/src/generated/parser.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 library java.core; 1 library java.core;
2 2
3 final Stopwatch nanoTimeStopwatch = new Stopwatch(); 3 final Stopwatch nanoTimeStopwatch = new Stopwatch();
4 4
5 const int LONG_MAX_VALUE = 0x7fffffffffffffff; 5 const int LONG_MAX_VALUE = 0x7fffffffffffffff;
6 6
7 class JavaSystem { 7 class JavaSystem {
8 static int currentTimeMillis() { 8 static int currentTimeMillis() {
9 return (new DateTime.now()).millisecondsSinceEpoch; 9 return (new DateTime.now()).millisecondsSinceEpoch;
10 } 10 }
(...skipping 136 matching lines...) Expand 10 before | Expand all | Expand 10 after
147 markFound = false; 147 markFound = false;
148 } else { 148 } else {
149 markFound = true; 149 markFound = true;
150 } 150 }
151 continue; 151 continue;
152 } 152 }
153 if (markFound) { 153 if (markFound) {
154 markFound = false; 154 markFound = false;
155 // %d 155 // %d
156 if (c == 0x64) { 156 if (c == 0x64) {
157 sb.writeCharCode(args[argIndex++]); 157 sb.write(args[argIndex++]);
158 continue; 158 continue;
159 } 159 }
160 // %s 160 // %s
161 if (c == 0x73) { 161 if (c == 0x73) {
162 sb.writeCharCode(args[argIndex++]); 162 sb.write(args[argIndex++]);
163 continue; 163 continue;
164 } 164 }
165 // unknown 165 // unknown
166 throw new IllegalArgumentException('[$fmt][$i] = 0x${c.toRadixString(16)}' ); 166 throw new IllegalArgumentException('[$fmt][$i] = 0x${c.toRadixString(16)}' );
167 } else { 167 } else {
168 sb.writeCharCode(c); 168 sb.writeCharCode(c);
169 } 169 }
170 } 170 }
171 return sb.toString(); 171 return sb.toString();
172 } 172 }
(...skipping 248 matching lines...) Expand 10 before | Expand all | Expand 10 after
421 * format('{0} are you {1}ing?', ['What', 'read']) = 'What are you reading?' 421 * format('{0} are you {1}ing?', ['What', 'read']) = 'What are you reading?'
422 */ 422 */
423 String formatList(String pattern, List args) { 423 String formatList(String pattern, List args) {
424 return pattern.replaceAllMapped(new RegExp(r'\{(\d+)\}'), (match) { 424 return pattern.replaceAllMapped(new RegExp(r'\{(\d+)\}'), (match) {
425 String indexStr = match.group(1); 425 String indexStr = match.group(1);
426 int index = int.parse(indexStr); 426 int index = int.parse(indexStr);
427 var arg = args[index]; 427 var arg = args[index];
428 return arg != null ? arg.toString() : null; 428 return arg != null ? arg.toString() : null;
429 }); 429 });
430 } 430 }
OLDNEW
« no previous file with comments | « no previous file | pkg/analyzer/lib/src/generated/parser.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698