| OLD | NEW |
| 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 274 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 285 this._options.preserveComments != options.preserveComments || | 285 this._options.preserveComments != options.preserveComments || |
| 286 this._options.strongMode != options.strongMode || | 286 this._options.strongMode != options.strongMode || |
| 287 this._options.enableAssertMessage != options.enableAssertMessage || | 287 this._options.enableAssertMessage != options.enableAssertMessage || |
| 288 ((options is AnalysisOptionsImpl) | 288 ((options is AnalysisOptionsImpl) |
| 289 ? this._options.strongModeHints != options.strongModeHints | 289 ? this._options.strongModeHints != options.strongModeHints |
| 290 : false) || | 290 : false) || |
| 291 ((options is AnalysisOptionsImpl) | 291 ((options is AnalysisOptionsImpl) |
| 292 ? this._options.implicitCasts != options.implicitCasts | 292 ? this._options.implicitCasts != options.implicitCasts |
| 293 : false) || | 293 : false) || |
| 294 ((options is AnalysisOptionsImpl) | 294 ((options is AnalysisOptionsImpl) |
| 295 ? this._options.nonnullableTypes != options.nonnullableTypes |
| 296 : false) || |
| 297 ((options is AnalysisOptionsImpl) |
| 295 ? this._options.implicitDynamic != options.implicitDynamic | 298 ? this._options.implicitDynamic != options.implicitDynamic |
| 296 : false) || | 299 : false) || |
| 297 this._options.enableStrictCallChecks != | 300 this._options.enableStrictCallChecks != |
| 298 options.enableStrictCallChecks || | 301 options.enableStrictCallChecks || |
| 299 this._options.enableGenericMethods != options.enableGenericMethods || | 302 this._options.enableGenericMethods != options.enableGenericMethods || |
| 300 this._options.enableAsync != options.enableAsync || | 303 this._options.enableAsync != options.enableAsync || |
| 301 this._options.enableSuperMixins != options.enableSuperMixins; | 304 this._options.enableSuperMixins != options.enableSuperMixins; |
| 302 int cacheSize = options.cacheSize; | 305 int cacheSize = options.cacheSize; |
| 303 if (this._options.cacheSize != cacheSize) { | 306 if (this._options.cacheSize != cacheSize) { |
| 304 this._options.cacheSize = cacheSize; | 307 this._options.cacheSize = cacheSize; |
| (...skipping 14 matching lines...) Expand all Loading... |
| 319 this._options.incrementalApi = options.incrementalApi; | 322 this._options.incrementalApi = options.incrementalApi; |
| 320 this._options.incrementalValidation = options.incrementalValidation; | 323 this._options.incrementalValidation = options.incrementalValidation; |
| 321 this._options.lint = options.lint; | 324 this._options.lint = options.lint; |
| 322 this._options.preserveComments = options.preserveComments; | 325 this._options.preserveComments = options.preserveComments; |
| 323 this._options.strongMode = options.strongMode; | 326 this._options.strongMode = options.strongMode; |
| 324 this._options.trackCacheDependencies = options.trackCacheDependencies; | 327 this._options.trackCacheDependencies = options.trackCacheDependencies; |
| 325 this._options.finerGrainedInvalidation = options.finerGrainedInvalidation; | 328 this._options.finerGrainedInvalidation = options.finerGrainedInvalidation; |
| 326 if (options is AnalysisOptionsImpl) { | 329 if (options is AnalysisOptionsImpl) { |
| 327 this._options.strongModeHints = options.strongModeHints; | 330 this._options.strongModeHints = options.strongModeHints; |
| 328 this._options.implicitCasts = options.implicitCasts; | 331 this._options.implicitCasts = options.implicitCasts; |
| 332 this._options.nonnullableTypes = options.nonnullableTypes; |
| 329 this._options.implicitDynamic = options.implicitDynamic; | 333 this._options.implicitDynamic = options.implicitDynamic; |
| 330 } | 334 } |
| 331 if (needsRecompute) { | 335 if (needsRecompute) { |
| 332 for (WorkManager workManager in workManagers) { | 336 for (WorkManager workManager in workManagers) { |
| 333 workManager.onAnalysisOptionsChanged(); | 337 workManager.onAnalysisOptionsChanged(); |
| 334 } | 338 } |
| 335 } | 339 } |
| 336 } | 340 } |
| 337 | 341 |
| 338 @override | 342 @override |
| (...skipping 1962 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2301 } | 2305 } |
| 2302 DartSdk sdk = factory.dartSdk; | 2306 DartSdk sdk = factory.dartSdk; |
| 2303 if (sdk == null) { | 2307 if (sdk == null) { |
| 2304 throw new IllegalArgumentException( | 2308 throw new IllegalArgumentException( |
| 2305 "The source factory for an SDK analysis context must have a DartUriRes
olver"); | 2309 "The source factory for an SDK analysis context must have a DartUriRes
olver"); |
| 2306 } | 2310 } |
| 2307 return new AnalysisCache( | 2311 return new AnalysisCache( |
| 2308 <CachePartition>[AnalysisEngine.instance.partitionManager.forSdk(sdk)]); | 2312 <CachePartition>[AnalysisEngine.instance.partitionManager.forSdk(sdk)]); |
| 2309 } | 2313 } |
| 2310 } | 2314 } |
| OLD | NEW |