| 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.task.dart; | 5 library analyzer.src.task.dart; |
| 6 | 6 |
| 7 import 'dart:collection'; | 7 import 'dart:collection'; |
| 8 | 8 |
| 9 import 'package:analyzer/dart/ast/ast.dart'; | 9 import 'package:analyzer/dart/ast/ast.dart'; |
| 10 import 'package:analyzer/dart/ast/standard_resolution_map.dart'; | 10 import 'package:analyzer/dart/ast/standard_resolution_map.dart'; |
| (...skipping 6108 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 6119 RecordingErrorListener errorListener = new RecordingErrorListener(); | 6119 RecordingErrorListener errorListener = new RecordingErrorListener(); |
| 6120 // | 6120 // |
| 6121 // Prepare inputs. | 6121 // Prepare inputs. |
| 6122 // | 6122 // |
| 6123 TypeProvider typeProvider = getRequiredInput(TYPE_PROVIDER_INPUT); | 6123 TypeProvider typeProvider = getRequiredInput(TYPE_PROVIDER_INPUT); |
| 6124 CompilationUnit unit = getRequiredInput(UNIT_INPUT); | 6124 CompilationUnit unit = getRequiredInput(UNIT_INPUT); |
| 6125 AnalysisOptionsImpl options = context.analysisOptions; | 6125 AnalysisOptionsImpl options = context.analysisOptions; |
| 6126 if (options.strongMode) { | 6126 if (options.strongMode) { |
| 6127 CodeChecker checker = new CodeChecker( | 6127 CodeChecker checker = new CodeChecker( |
| 6128 typeProvider, | 6128 typeProvider, |
| 6129 new StrongTypeSystemImpl( | 6129 new StrongTypeSystemImpl(typeProvider, |
| 6130 implicitCasts: options.implicitCasts, | 6130 implicitCasts: options.implicitCasts, |
| 6131 nonnullableTypes: options.nonnullableTypes), | 6131 nonnullableTypes: options.nonnullableTypes), |
| 6132 errorListener, | 6132 errorListener, |
| 6133 options); | 6133 options); |
| 6134 checker.visitCompilationUnit(unit); | 6134 checker.visitCompilationUnit(unit); |
| 6135 } | 6135 } |
| 6136 // | 6136 // |
| 6137 // Record outputs. | 6137 // Record outputs. |
| 6138 // | 6138 // |
| 6139 outputs[STRONG_MODE_ERRORS] = getUniqueErrors(errorListener.errors); | 6139 outputs[STRONG_MODE_ERRORS] = getUniqueErrors(errorListener.errors); |
| (...skipping 366 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 6506 | 6506 |
| 6507 @override | 6507 @override |
| 6508 bool moveNext() { | 6508 bool moveNext() { |
| 6509 if (_newSources.isEmpty) { | 6509 if (_newSources.isEmpty) { |
| 6510 return false; | 6510 return false; |
| 6511 } | 6511 } |
| 6512 currentTarget = _newSources.removeLast(); | 6512 currentTarget = _newSources.removeLast(); |
| 6513 return true; | 6513 return true; |
| 6514 } | 6514 } |
| 6515 } | 6515 } |
| OLD | NEW |