OLD | NEW |
1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2014, 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.error.error; | 5 library analyzer.error.error; |
6 | 6 |
7 import 'dart:collection'; | 7 import 'dart:collection'; |
8 | 8 |
9 import 'package:analyzer/error/listener.dart'; | 9 import 'package:analyzer/error/listener.dart'; |
10 import 'package:analyzer/src/dart/scanner/scanner.dart' show ScannerErrorCode; | 10 import 'package:analyzer/src/dart/scanner/scanner.dart' show ScannerErrorCode; |
(...skipping 24 matching lines...) Expand all Loading... |
35 // ../front_end/lib/src/scanner/errors.dart | | 35 // ../front_end/lib/src/scanner/errors.dart | |
36 // grep 'static const .*Code' | | 36 // grep 'static const .*Code' | |
37 // awk '{print $3"."$4","}' | | 37 // awk '{print $3"."$4","}' | |
38 // sort > codes.txt | 38 // sort > codes.txt |
39 // | 39 // |
40 // There are a few error codes that are wrapped such that the name of the | 40 // There are a few error codes that are wrapped such that the name of the |
41 // error code in on the line following the pattern we're grepping for. Those | 41 // error code in on the line following the pattern we're grepping for. Those |
42 // need to be filled in by hand. | 42 // need to be filled in by hand. |
43 // | 43 // |
44 AnalysisOptionsErrorCode.PARSE_ERROR, | 44 AnalysisOptionsErrorCode.PARSE_ERROR, |
| 45 AnalysisOptionsErrorCode.INCLUDED_FILE_PARSE_ERROR, |
| 46 AnalysisOptionsWarningCode.INCLUDE_FILE_NOT_FOUND, |
| 47 AnalysisOptionsWarningCode.INCLUDED_FILE_WARNING, |
45 AnalysisOptionsWarningCode.UNRECOGNIZED_ERROR_CODE, | 48 AnalysisOptionsWarningCode.UNRECOGNIZED_ERROR_CODE, |
46 AnalysisOptionsWarningCode.UNSUPPORTED_OPTION_WITH_LEGAL_VALUE, | 49 AnalysisOptionsWarningCode.UNSUPPORTED_OPTION_WITH_LEGAL_VALUE, |
47 AnalysisOptionsWarningCode.UNSUPPORTED_OPTION_WITH_LEGAL_VALUES, | 50 AnalysisOptionsWarningCode.UNSUPPORTED_OPTION_WITH_LEGAL_VALUES, |
48 AnalysisOptionsWarningCode.UNSUPPORTED_VALUE, | 51 AnalysisOptionsWarningCode.UNSUPPORTED_VALUE, |
49 CheckedModeCompileTimeErrorCode.CONST_CONSTRUCTOR_FIELD_TYPE_MISMATCH, | 52 CheckedModeCompileTimeErrorCode.CONST_CONSTRUCTOR_FIELD_TYPE_MISMATCH, |
50 CheckedModeCompileTimeErrorCode.CONST_CONSTRUCTOR_PARAM_TYPE_MISMATCH, | 53 CheckedModeCompileTimeErrorCode.CONST_CONSTRUCTOR_PARAM_TYPE_MISMATCH, |
51 CheckedModeCompileTimeErrorCode.CONST_EVAL_THROWS_EXCEPTION, | 54 CheckedModeCompileTimeErrorCode.CONST_EVAL_THROWS_EXCEPTION, |
52 CheckedModeCompileTimeErrorCode.CONST_FIELD_INITIALIZER_NOT_ASSIGNABLE, | 55 CheckedModeCompileTimeErrorCode.CONST_FIELD_INITIALIZER_NOT_ASSIGNABLE, |
53 CheckedModeCompileTimeErrorCode.LIST_ELEMENT_TYPE_NOT_ASSIGNABLE, | 56 CheckedModeCompileTimeErrorCode.LIST_ELEMENT_TYPE_NOT_ASSIGNABLE, |
54 CheckedModeCompileTimeErrorCode.MAP_KEY_TYPE_NOT_ASSIGNABLE, | 57 CheckedModeCompileTimeErrorCode.MAP_KEY_TYPE_NOT_ASSIGNABLE, |
(...skipping 788 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
843 * a single list of errors. | 846 * a single list of errors. |
844 */ | 847 */ |
845 static List<AnalysisError> mergeLists(List<List<AnalysisError>> errorLists) { | 848 static List<AnalysisError> mergeLists(List<List<AnalysisError>> errorLists) { |
846 Set<AnalysisError> errors = new HashSet<AnalysisError>(); | 849 Set<AnalysisError> errors = new HashSet<AnalysisError>(); |
847 for (List<AnalysisError> errorList in errorLists) { | 850 for (List<AnalysisError> errorList in errorLists) { |
848 errors.addAll(errorList); | 851 errors.addAll(errorList); |
849 } | 852 } |
850 return errors.toList(); | 853 return errors.toList(); |
851 } | 854 } |
852 } | 855 } |
OLD | NEW |