Index: pkg/compiler/lib/src/js_emitter/startup_emitter/model_emitter.dart |
diff --git a/pkg/compiler/lib/src/js_emitter/startup_emitter/model_emitter.dart b/pkg/compiler/lib/src/js_emitter/startup_emitter/model_emitter.dart |
index 8c9f24783129663857d57171a2125aa9e7a07ec6..ec8ac00c1c86105465ac23a8217663c3ea29bb89 100644 |
--- a/pkg/compiler/lib/src/js_emitter/startup_emitter/model_emitter.dart |
+++ b/pkg/compiler/lib/src/js_emitter/startup_emitter/model_emitter.dart |
@@ -31,6 +31,9 @@ import '../../js_backend/js_backend.dart' show |
Namer, |
ConstantEmitter; |
+import '../../diagnostics/diagnostic_listener.dart' show |
+ DiagnosticReporter; |
+ |
import '../../diagnostics/spannable.dart' show |
NO_LOCATION_SPANNABLE; |
@@ -100,6 +103,8 @@ class ModelEmitter { |
constantListGenerator); |
} |
+ DiagnosticReporter get reporter => compiler.reporter; |
+ |
js.Expression constantListGenerator(js.Expression array) { |
// TODO(floitsch): remove hard-coded name. |
return js.js('makeConstList(#)', [array]); |
@@ -211,7 +216,7 @@ class ModelEmitter { |
if (backend.requiresPreamble && |
!backend.htmlLibraryIsLoaded) { |
- compiler.reportHintMessage( |
+ reporter.reportHintMessage( |
NO_LOCATION_SPANNABLE, MessageKind.PREAMBLE); |
} |