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

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

Issue 10918047: First corelib cleanup patch after unification. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Remove bogus comment. Created 8 years, 3 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/compiler.dart
diff --git a/lib/compiler/implementation/compiler.dart b/lib/compiler/implementation/compiler.dart
index f22184e30d276639fb1c1936d6f9042114e7f6fe..ae78cb4558df3a51b275b0ca95a86b416ba9c255 100644
--- a/lib/compiler/implementation/compiler.dart
+++ b/lib/compiler/implementation/compiler.dart
@@ -826,6 +826,14 @@ class Compiler implements DiagnosticListener {
}
Token position = element.position();
Uri uri = element.getCompilationUnit().script.uri;
+
+ // TODO(ager,johnniwinther): The patch support should be
+ // reworked to allow us to get rid of this.
+ if (element.isPatched) {
+ position = element.patch.position();
+ uri = element.patch.getCompilationUnit().script.uri;
+ }
+
return (position === null)
? new SourceSpan(uri, 0, 0)
: spanFromTokens(position, position, uri);

Powered by Google App Engine
This is Rietveld 408576698