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

Unified Diff: lib/src/options.dart

Issue 1382023002: Support for --fatal-hints. (Closed) Base URL: https://github.com/dart-lang/analyzer_cli.git@master
Patch Set: Created 5 years, 3 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 | « lib/src/error_formatter.dart ('k') | test/data/file_with_error.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: lib/src/options.dart
diff --git a/lib/src/options.dart b/lib/src/options.dart
index 499cbb643e05f88ba4a3b1caa0607112d9ae7f10..9abcca3a921d4985fcf59b53a33c06f418bd595c 100644
--- a/lib/src/options.dart
+++ b/lib/src/options.dart
@@ -48,6 +48,9 @@ class CommandLineOptions {
/// errors.
final bool enableTypeChecks;
+ /// Whether to treat hints as fatal
+ final bool hintsAreFatal;
+
/// Whether to ignore unrecognized flags
final bool ignoreUnrecognizedFlags;
@@ -99,6 +102,7 @@ class CommandLineOptions {
enableStrictCallChecks = args['enable-strict-call-checks'],
enableSuperMixins = args['supermixin'],
enableTypeChecks = args['enable_type_checks'],
+ hintsAreFatal = args['fatal-hints'],
ignoreUnrecognizedFlags = args['ignore-unrecognized-flags'],
lints = args['lints'],
log = args['log'],
@@ -209,6 +213,10 @@ class CommandLineOptions {
help: 'Ignore unrecognized command line flags.',
defaultsTo: false,
negatable: false)
+ ..addFlag('fatal-hints',
+ help: 'Treat hints as fatal.',
+ defaultsTo: false,
+ negatable: false)
..addFlag('fatal-warnings',
help: 'Treat non-type warnings as fatal.',
defaultsTo: false,
« no previous file with comments | « lib/src/error_formatter.dart ('k') | test/data/file_with_error.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698