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

Unified Diff: lib/compiler/implementation/source_file.dart

Issue 10829459: Deprecate Math object in corelib in favor of dart:math library. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 4 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
Index: lib/compiler/implementation/source_file.dart
diff --git a/lib/compiler/implementation/source_file.dart b/lib/compiler/implementation/source_file.dart
index 222420c457e2b7343000e4964886f3cb20c8626d..af9743d1dbf72701d5134340530152688a99e577 100644
--- a/lib/compiler/implementation/source_file.dart
+++ b/lib/compiler/implementation/source_file.dart
@@ -4,6 +4,8 @@
#library('source_file');
+#import('dart:math');
+
#import('colors.dart', prefix: 'colors');
/**
@@ -71,7 +73,7 @@ class SourceFile {
textLine = '${text.substring(_lineStarts[line])}\n';
}
- int toColumn = Math.min(column + (end-start), textLine.length);
+ int toColumn = min(column + (end-start), textLine.length);
buf.add(textLine.substring(0, column));
buf.add(color(textLine.substring(column, toColumn)));
buf.add(textLine.substring(toColumn));

Powered by Google App Engine
This is Rietveld 408576698