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

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

Issue 10579015: Update dart2js to use diagnostic kinds. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 8 years, 6 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 | « dart/lib/compiler/compiler.dart ('k') | dart/lib/compiler/implementation/colors.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: dart/lib/compiler/implementation/apiimpl.dart
diff --git a/dart/lib/compiler/implementation/apiimpl.dart b/dart/lib/compiler/implementation/apiimpl.dart
index 2296e262de0376aa22e3806ea4f0cdbbf117dc60..f983f5a86588f77b8185b0fd7ed0498d272e0e1f 100644
--- a/dart/lib/compiler/implementation/apiimpl.dart
+++ b/dart/lib/compiler/implementation/apiimpl.dart
@@ -39,7 +39,7 @@ class Compiler extends leg.Compiler {
}
void log(message) {
- handler(null, null, null, message, false);
+ handler(null, null, null, message, api.Diagnostic.VERBOSE_INFO);
}
leg.Script readScript(Uri uri, [tree.Node node]) {
@@ -55,7 +55,7 @@ class Compiler extends leg.Compiler {
cancel("$exception", node: node);
} else {
reportDiagnostic(const leg.SourceSpan(null, null, null),
- "$exception", true);
+ "$exception", api.Diagnostic.ERROR);
throw new leg.CompilerCancelledException("$exception");
}
}
@@ -95,12 +95,13 @@ class Compiler extends leg.Compiler {
return success;
}
- void reportDiagnostic(leg.SourceSpan span, String message, bool fatal) {
+ void reportDiagnostic(leg.SourceSpan span, String message,
+ api.Diagnostic kind) {
if (span === null) {
- handler(null, null, null, message, fatal);
+ handler(null, null, null, message, kind);
} else {
handler(translateUri(span.uri, null), span.begin, span.end,
- message, fatal);
+ message, kind);
}
}
« no previous file with comments | « dart/lib/compiler/compiler.dart ('k') | dart/lib/compiler/implementation/colors.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698