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

Side by Side Diff: lib/compiler/implementation/tools/mini_parser.dart

Issue 11265024: Make methods in Stopwatch getters and rename to be more consistent. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Update status files with co19 issue number. Created 8 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 | « lib/compiler/implementation/compiler.dart ('k') | lib/compiler/samples/leap/leap_leg.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 // 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 #library('parser'); 5 #library('parser');
6 6
7 #import('dart:io'); 7 #import('dart:io');
8 #import('dart:scalarlist'); 8 #import('dart:scalarlist');
9 9
10 #import('../../../utf/utf.dart'); 10 #import('../../../utf/utf.dart');
(...skipping 20 matching lines...) Expand all
31 } 31 }
32 32
33 void toolMain(List<String> arguments) { 33 void toolMain(List<String> arguments) {
34 filesWithCrashes = []; 34 filesWithCrashes = [];
35 stopwatch = new Stopwatch(); 35 stopwatch = new Stopwatch();
36 MyOptions options = new MyOptions(); 36 MyOptions options = new MyOptions();
37 37
38 void printStats() { 38 void printStats() {
39 int kb = (charCount / 1024).round().toInt(); 39 int kb = (charCount / 1024).round().toInt();
40 String stats = 40 String stats =
41 '$classCount classes (${kb}Kb) in ${stopwatch.elapsedInMs()}ms'; 41 '$classCount classes (${kb}Kb) in ${stopwatch.elapsedMilliseconds}ms';
42 if (errorCount != 0) { 42 if (errorCount != 0) {
43 stats = '$stats with $errorCount errors'; 43 stats = '$stats with $errorCount errors';
44 } 44 }
45 if (options.diet) { 45 if (options.diet) {
46 print('Diet parsed $stats.'); 46 print('Diet parsed $stats.');
47 } else { 47 } else {
48 print('Parsed $stats.'); 48 print('Parsed $stats.');
49 } 49 }
50 if (filesWithCrashes.length != 0) { 50 if (filesWithCrashes.length != 0) {
51 print('The following ${filesWithCrashes.length} files caused a crash:'); 51 print('The following ${filesWithCrashes.length} files caused a crash:');
(...skipping 260 matching lines...) Expand 10 before | Expand all | Expand 10 after
312 set text(String newText) { 312 set text(String newText) {
313 throw "not supported"; 313 throw "not supported";
314 } 314 }
315 } 315 }
316 316
317 class Mock { 317 class Mock {
318 const Mock(); 318 const Mock();
319 bool get useColors => true; 319 bool get useColors => true;
320 internalError(message) { throw message.toString(); } 320 internalError(message) { throw message.toString(); }
321 } 321 }
OLDNEW
« no previous file with comments | « lib/compiler/implementation/compiler.dart ('k') | lib/compiler/samples/leap/leap_leg.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698