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

Unified Diff: pkg/compiler/lib/src/js_emitter/lazy_emitter/emitter.dart

Issue 1383483006: Extract DiagnosticReporter implementation from Compiler. (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: Fixes after rebase. Created 5 years, 2 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: pkg/compiler/lib/src/js_emitter/lazy_emitter/emitter.dart
diff --git a/pkg/compiler/lib/src/js_emitter/lazy_emitter/emitter.dart b/pkg/compiler/lib/src/js_emitter/lazy_emitter/emitter.dart
index d68c38b6f03b49611119d95cec3501dbbfdb3465..2c2f3035430a8ca6948f90e3b48a5209daf42715 100644
--- a/pkg/compiler/lib/src/js_emitter/lazy_emitter/emitter.dart
+++ b/pkg/compiler/lib/src/js_emitter/lazy_emitter/emitter.dart
@@ -26,6 +26,9 @@ import '../js_emitter.dart' show
import '../js_emitter.dart' as emitterTask show
Emitter;
+import '../../diagnostics/diagnostic_listener.dart' show
+ DiagnosticReporter;
+
import '../../diagnostics/spannable.dart' show
NO_LOCATION_SPANNABLE;
@@ -41,6 +44,8 @@ class Emitter implements emitterTask.Emitter {
this.namer = namer,
_emitter = new ModelEmitter(compiler, namer, nativeEmitter);
+ DiagnosticReporter get reporter => _compiler.reporter;
+
@override
String get patchVersion => "lazy";
@@ -181,7 +186,7 @@ class Emitter implements emitterTask.Emitter {
throw new UnsupportedError('createDartClosureFromNameOfStaticFunction');
default:
- _compiler.internalError(NO_LOCATION_SPANNABLE,
+ reporter.internalError(NO_LOCATION_SPANNABLE,
"Unhandled Builtin: $builtin");
return null;
}
« no previous file with comments | « pkg/compiler/lib/src/js_emitter/js_emitter.dart ('k') | pkg/compiler/lib/src/js_emitter/metadata_collector.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698