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

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

Issue 10575033: Implement override checks. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge
Patch Set: Fix problem that caused an assertion failure (and revert of the first attempt) 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/implementation/apiimpl.dart ('k') | dart/lib/compiler/implementation/dart2js.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: dart/lib/compiler/implementation/compiler.dart
diff --git a/dart/lib/compiler/implementation/compiler.dart b/dart/lib/compiler/implementation/compiler.dart
index 6a78ae5e1f127347aa970adbc7507e675cef653c..5cb19337cb4fcc308c118fca646646309eb21ecd 100644
--- a/dart/lib/compiler/implementation/compiler.dart
+++ b/dart/lib/compiler/implementation/compiler.dart
@@ -303,6 +303,8 @@ class Compiler implements DiagnosticListener {
static final int PHASE_RECOMPILING = 3;
int phase;
+ bool compilationFailed = false;
+
Compiler([this.tracer = const Tracer(),
this.enableTypeAssertions = false,
this.enableUserAssertions = false,
@@ -548,6 +550,8 @@ class Compiler implements DiagnosticListener {
processQueue(enqueuer.resolution, main);
log('Resolved ${enqueuer.resolution.resolvedElements.length} elements.');
+ if (compilationFailed) return;
+
log('Compiling...');
phase = PHASE_COMPILING;
processQueue(enqueuer.codegen, main);
@@ -557,6 +561,8 @@ class Compiler implements DiagnosticListener {
processRecompilationQueue(enqueuer.codegen);
log('Compiled ${codegenWorld.generatedCode.length} methods.');
+ if (compilationFailed) return;
+
backend.assembleProgram();
checkQueues();
@@ -755,7 +761,7 @@ class Compiler implements DiagnosticListener {
}
SourceSpan span = spanFromNode(node);
- reportDiagnostic(span, 'Warning: $message', api.Diagnostic.WARNING );
+ reportDiagnostic(span, 'Warning: $message', api.Diagnostic.WARNING);
}
reportError(Node node, var message) {
@@ -764,6 +770,14 @@ class Compiler implements DiagnosticListener {
throw new CompilerCancelledException(message.toString());
}
+ void reportMessage(SourceSpan span,
+ Diagnostic message,
+ api.Diagnostic kind) {
+ // TODO(ahe): The names Diagnostic and api.Diagnostic are in
+ // conflict. Fix it.
+ reportDiagnostic(span, "$message", kind);
+ }
+
abstract void reportDiagnostic(SourceSpan span, String message,
api.Diagnostic kind);
« no previous file with comments | « dart/lib/compiler/implementation/apiimpl.dart ('k') | dart/lib/compiler/implementation/dart2js.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698