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

Unified Diff: pkg/compiler/lib/src/diagnostics/diagnostic_listener.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
« no previous file with comments | « pkg/compiler/lib/src/deferred_load.dart ('k') | pkg/compiler/lib/src/dump_info.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/compiler/lib/src/diagnostics/diagnostic_listener.dart
diff --git a/pkg/compiler/lib/src/diagnostics/diagnostic_listener.dart b/pkg/compiler/lib/src/diagnostics/diagnostic_listener.dart
index e2e4d1a4a7fb952ba67fe8e0728272eaf91d471a..cfef59fbabd60edc3dcea1d0f2ffa2ba28f3a8cc 100644
--- a/pkg/compiler/lib/src/diagnostics/diagnostic_listener.dart
+++ b/pkg/compiler/lib/src/diagnostics/diagnostic_listener.dart
@@ -12,8 +12,21 @@ import '../elements/elements.dart' show
Element;
import 'messages.dart';
+class DiagnosticOptions {
+ final bool suppressWarnings;
+ final bool terseDiagnostics;
+ final bool showPackageWarnings;
+
+ const DiagnosticOptions({
+ this.suppressWarnings: false,
+ this.terseDiagnostics: false,
+ this.showPackageWarnings: false});
+}
+
// TODO(johnniwinther): Rename and cleanup this interface. Add severity enum.
-abstract class DiagnosticListener {
+abstract class DiagnosticReporter {
+ DiagnosticOptions get options => const DiagnosticOptions();
+
// TODO(karlklose): rename log to something like reportInfo.
void log(message);
« no previous file with comments | « pkg/compiler/lib/src/deferred_load.dart ('k') | pkg/compiler/lib/src/dump_info.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698