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/token.dart'; | 10 import 'package:analyzer/dart/ast/token.dart'; |
(...skipping 5666 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5677 RecordingErrorListener errorListener = new RecordingErrorListener(); | 5677 RecordingErrorListener errorListener = new RecordingErrorListener(); |
5678 // | 5678 // |
5679 // Prepare inputs. | 5679 // Prepare inputs. |
5680 // | 5680 // |
5681 TypeProvider typeProvider = getRequiredInput(TYPE_PROVIDER_INPUT); | 5681 TypeProvider typeProvider = getRequiredInput(TYPE_PROVIDER_INPUT); |
5682 CompilationUnit unit = getRequiredInput(UNIT_INPUT); | 5682 CompilationUnit unit = getRequiredInput(UNIT_INPUT); |
5683 AnalysisOptionsImpl options = context.analysisOptions; | 5683 AnalysisOptionsImpl options = context.analysisOptions; |
5684 if (options.strongMode) { | 5684 if (options.strongMode) { |
5685 unit.accept(new CodeChecker( | 5685 unit.accept(new CodeChecker( |
5686 typeProvider, new StrongTypeSystemImpl(), errorListener, | 5686 typeProvider, new StrongTypeSystemImpl(), errorListener, |
5687 hints: options.strongModeHints)); | 5687 options)); |
5688 } | 5688 } |
5689 // | 5689 // |
5690 // Record outputs. | 5690 // Record outputs. |
5691 // | 5691 // |
5692 outputs[STRONG_MODE_ERRORS] = getUniqueErrors(errorListener.errors); | 5692 outputs[STRONG_MODE_ERRORS] = getUniqueErrors(errorListener.errors); |
5693 outputs[CREATED_RESOLVED_UNIT] = true; | 5693 outputs[CREATED_RESOLVED_UNIT] = true; |
5694 outputs[RESOLVED_UNIT] = unit; | 5694 outputs[RESOLVED_UNIT] = unit; |
5695 } | 5695 } |
5696 | 5696 |
5697 /** | 5697 /** |
(...skipping 290 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5988 | 5988 |
5989 @override | 5989 @override |
5990 bool moveNext() { | 5990 bool moveNext() { |
5991 if (_newSources.isEmpty) { | 5991 if (_newSources.isEmpty) { |
5992 return false; | 5992 return false; |
5993 } | 5993 } |
5994 currentTarget = _newSources.removeLast(); | 5994 currentTarget = _newSources.removeLast(); |
5995 return true; | 5995 return true; |
5996 } | 5996 } |
5997 } | 5997 } |
OLD | NEW |