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

Side by Side Diff: pkg/analyzer/lib/src/context/context.dart

Issue 1744773002: Support conditional directives in the options file. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 4 years, 9 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 unified diff | Download patch
« no previous file with comments | « no previous file | pkg/analyzer/lib/src/generated/incremental_resolver.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 library analyzer.src.context.context; 5 library analyzer.src.context.context;
6 6
7 import 'dart:async'; 7 import 'dart:async';
8 import 'dart:collection'; 8 import 'dart:collection';
9 9
10 import 'package:analyzer/dart/ast/ast.dart'; 10 import 'package:analyzer/dart/ast/ast.dart';
(...skipping 242 matching lines...) Expand 10 before | Expand all | Expand 10 after
253 this._options.preserveComments != options.preserveComments || 253 this._options.preserveComments != options.preserveComments ||
254 this._options.strongMode != options.strongMode || 254 this._options.strongMode != options.strongMode ||
255 this._options.enableAssertMessage != options.enableAssertMessage || 255 this._options.enableAssertMessage != options.enableAssertMessage ||
256 ((options is AnalysisOptionsImpl) 256 ((options is AnalysisOptionsImpl)
257 ? this._options.strongModeHints != options.strongModeHints 257 ? this._options.strongModeHints != options.strongModeHints
258 : false) || 258 : false) ||
259 this._options.enableStrictCallChecks != 259 this._options.enableStrictCallChecks !=
260 options.enableStrictCallChecks || 260 options.enableStrictCallChecks ||
261 this._options.enableGenericMethods != options.enableGenericMethods || 261 this._options.enableGenericMethods != options.enableGenericMethods ||
262 this._options.enableAsync != options.enableAsync || 262 this._options.enableAsync != options.enableAsync ||
263 this._options.enableConditionalDirectives !=
264 options.enableConditionalDirectives ||
263 this._options.enableSuperMixins != options.enableSuperMixins; 265 this._options.enableSuperMixins != options.enableSuperMixins;
264 int cacheSize = options.cacheSize; 266 int cacheSize = options.cacheSize;
265 if (this._options.cacheSize != cacheSize) { 267 if (this._options.cacheSize != cacheSize) {
266 this._options.cacheSize = cacheSize; 268 this._options.cacheSize = cacheSize;
267 } 269 }
268 this._options.analyzeFunctionBodiesPredicate = 270 this._options.analyzeFunctionBodiesPredicate =
269 options.analyzeFunctionBodiesPredicate; 271 options.analyzeFunctionBodiesPredicate;
270 this._options.generateImplicitErrors = options.generateImplicitErrors; 272 this._options.generateImplicitErrors = options.generateImplicitErrors;
271 this._options.generateSdkErrors = options.generateSdkErrors; 273 this._options.generateSdkErrors = options.generateSdkErrors;
272 this._options.dart2jsHint = options.dart2jsHint; 274 this._options.dart2jsHint = options.dart2jsHint;
273 this._options.enableGenericMethods = options.enableGenericMethods; 275 this._options.enableGenericMethods = options.enableGenericMethods;
274 this._options.enableAssertMessage = options.enableAssertMessage; 276 this._options.enableAssertMessage = options.enableAssertMessage;
275 this._options.enableStrictCallChecks = options.enableStrictCallChecks; 277 this._options.enableStrictCallChecks = options.enableStrictCallChecks;
276 this._options.enableAsync = options.enableAsync; 278 this._options.enableAsync = options.enableAsync;
279 this._options.enableConditionalDirectives =
280 options.enableConditionalDirectives;
277 this._options.enableSuperMixins = options.enableSuperMixins; 281 this._options.enableSuperMixins = options.enableSuperMixins;
278 this._options.hint = options.hint; 282 this._options.hint = options.hint;
279 this._options.incremental = options.incremental; 283 this._options.incremental = options.incremental;
280 this._options.incrementalApi = options.incrementalApi; 284 this._options.incrementalApi = options.incrementalApi;
281 this._options.incrementalValidation = options.incrementalValidation; 285 this._options.incrementalValidation = options.incrementalValidation;
282 this._options.lint = options.lint; 286 this._options.lint = options.lint;
283 this._options.preserveComments = options.preserveComments; 287 this._options.preserveComments = options.preserveComments;
284 this._options.strongMode = options.strongMode; 288 this._options.strongMode = options.strongMode;
285 if (options is AnalysisOptionsImpl) { 289 if (options is AnalysisOptionsImpl) {
286 this._options.strongModeHints = options.strongModeHints; 290 this._options.strongModeHints = options.strongModeHints;
(...skipping 1841 matching lines...) Expand 10 before | Expand all | Expand 10 after
2128 } 2132 }
2129 DartSdk sdk = factory.dartSdk; 2133 DartSdk sdk = factory.dartSdk;
2130 if (sdk == null) { 2134 if (sdk == null) {
2131 throw new IllegalArgumentException( 2135 throw new IllegalArgumentException(
2132 "The source factory for an SDK analysis context must have a DartUriRes olver"); 2136 "The source factory for an SDK analysis context must have a DartUriRes olver");
2133 } 2137 }
2134 return new AnalysisCache( 2138 return new AnalysisCache(
2135 <CachePartition>[AnalysisEngine.instance.partitionManager.forSdk(sdk)]); 2139 <CachePartition>[AnalysisEngine.instance.partitionManager.forSdk(sdk)]);
2136 } 2140 }
2137 } 2141 }
OLDNEW
« no previous file with comments | « no previous file | pkg/analyzer/lib/src/generated/incremental_resolver.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698