| Index: pkg/analyzer/lib/src/task/options.dart
|
| diff --git a/pkg/analyzer/lib/src/task/options.dart b/pkg/analyzer/lib/src/task/options.dart
|
| index 689bff2eebbd5b212bf0decb42562883051f97a4..5b968b075a2deb439b2031dc71a86b01981665ee 100644
|
| --- a/pkg/analyzer/lib/src/task/options.dart
|
| +++ b/pkg/analyzer/lib/src/task/options.dart
|
| @@ -35,6 +35,7 @@ void configureContextOptions(
|
| /// `analyzer` analysis options constants.
|
| class AnalyzerOptions {
|
| static const String analyzer = 'analyzer';
|
| + static const String enableGenericMethods = 'enableGenericMethods';
|
| static const String enableSuperMixins = 'enableSuperMixins';
|
| static const String errors = 'errors';
|
| static const String exclude = 'exclude';
|
| @@ -61,7 +62,10 @@ class AnalyzerOptions {
|
| ];
|
|
|
| /// Supported `analyzer` language configuration options.
|
| - static const List<String> languageOptions = const [enableSuperMixins];
|
| + static const List<String> languageOptions = const [
|
| + enableGenericMethods,
|
| + enableSuperMixins
|
| + ];
|
| }
|
|
|
| /// Validates `analyzer` options.
|
| @@ -391,11 +395,19 @@ class _OptionsProcessor {
|
| if (feature == AnalyzerOptions.enableSuperMixins) {
|
| if (isTrue(v.value)) {
|
| AnalysisOptionsImpl options =
|
| - new AnalysisOptionsImpl.from(context.analysisOptions);
|
| + new AnalysisOptionsImpl.from(context.analysisOptions);
|
| options.enableSuperMixins = true;
|
| context.analysisOptions = options;
|
| }
|
| }
|
| + if (feature == AnalyzerOptions.enableGenericMethods) {
|
| + if (isTrue(v.value)) {
|
| + AnalysisOptionsImpl options =
|
| + new AnalysisOptionsImpl.from(context.analysisOptions);
|
| + options.enableGenericMethods = true;
|
| + context.analysisOptions = options;
|
| + }
|
| + }
|
| }
|
| });
|
| }
|
|
|