| 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.src.generated.error; | 5 library analyzer.src.generated.error; |
| 6 | 6 |
| 7 import 'dart:collection'; | 7 import 'dart:collection'; |
| 8 | 8 |
| 9 import 'package:analyzer/dart/ast/ast.dart' show AstNode; | 9 import 'package:analyzer/dart/ast/ast.dart' show AstNode; |
| 10 import 'package:analyzer/dart/ast/token.dart'; | 10 import 'package:analyzer/dart/ast/token.dart'; |
| (...skipping 2665 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2676 HintCode.DEPRECATED_MEMBER_USE, | 2676 HintCode.DEPRECATED_MEMBER_USE, |
| 2677 HintCode.DUPLICATE_IMPORT, | 2677 HintCode.DUPLICATE_IMPORT, |
| 2678 HintCode.DIVISION_OPTIMIZATION, | 2678 HintCode.DIVISION_OPTIMIZATION, |
| 2679 HintCode.IS_DOUBLE, | 2679 HintCode.IS_DOUBLE, |
| 2680 HintCode.IS_INT, | 2680 HintCode.IS_INT, |
| 2681 HintCode.IS_NOT_DOUBLE, | 2681 HintCode.IS_NOT_DOUBLE, |
| 2682 HintCode.IS_NOT_INT, | 2682 HintCode.IS_NOT_INT, |
| 2683 HintCode.IMPORT_DEFERRED_LIBRARY_WITH_LOAD_FUNCTION, | 2683 HintCode.IMPORT_DEFERRED_LIBRARY_WITH_LOAD_FUNCTION, |
| 2684 HintCode.INVALID_ASSIGNMENT, | 2684 HintCode.INVALID_ASSIGNMENT, |
| 2685 HintCode.INVALID_USE_OF_PROTECTED_MEMBER, | 2685 HintCode.INVALID_USE_OF_PROTECTED_MEMBER, |
| 2686 HintCode.MISSING_REQUIRED_PARAM, |
| 2686 HintCode.MISSING_RETURN, | 2687 HintCode.MISSING_RETURN, |
| 2687 HintCode.NULL_AWARE_IN_CONDITION, | 2688 HintCode.NULL_AWARE_IN_CONDITION, |
| 2688 HintCode.OVERRIDE_ON_NON_OVERRIDING_GETTER, | 2689 HintCode.OVERRIDE_ON_NON_OVERRIDING_GETTER, |
| 2689 HintCode.OVERRIDE_ON_NON_OVERRIDING_METHOD, | 2690 HintCode.OVERRIDE_ON_NON_OVERRIDING_METHOD, |
| 2690 HintCode.OVERRIDE_ON_NON_OVERRIDING_SETTER, | 2691 HintCode.OVERRIDE_ON_NON_OVERRIDING_SETTER, |
| 2691 HintCode.OVERRIDE_EQUALS_BUT_NOT_HASH_CODE, | 2692 HintCode.OVERRIDE_EQUALS_BUT_NOT_HASH_CODE, |
| 2692 HintCode.TYPE_CHECK_IS_NOT_NULL, | 2693 HintCode.TYPE_CHECK_IS_NOT_NULL, |
| 2693 HintCode.TYPE_CHECK_IS_NULL, | 2694 HintCode.TYPE_CHECK_IS_NULL, |
| 2694 HintCode.UNDEFINED_GETTER, | 2695 HintCode.UNDEFINED_GETTER, |
| 2695 HintCode.UNDEFINED_METHOD, | 2696 HintCode.UNDEFINED_METHOD, |
| (...skipping 869 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3565 * | 3566 * |
| 3566 * Parameters: | 3567 * Parameters: |
| 3567 * 0: the name of the member | 3568 * 0: the name of the member |
| 3568 * 1: the name of the defining class | 3569 * 1: the name of the defining class |
| 3569 */ | 3570 */ |
| 3570 static const HintCode INVALID_USE_OF_PROTECTED_MEMBER = const HintCode( | 3571 static const HintCode INVALID_USE_OF_PROTECTED_MEMBER = const HintCode( |
| 3571 'INVALID_USE_OF_PROTECTED_MEMBER', | 3572 'INVALID_USE_OF_PROTECTED_MEMBER', |
| 3572 "The member '{0}' can only be used within instance members of subclasses o
f '{1}'"); | 3573 "The member '{0}' can only be used within instance members of subclasses o
f '{1}'"); |
| 3573 | 3574 |
| 3574 /** | 3575 /** |
| 3576 * Generate a hint for a constructor, function or method invocation where a |
| 3577 * required parameter is missing. |
| 3578 * |
| 3579 * Parameters: |
| 3580 * 0: the name of the parameter |
| 3581 * 1: an optional reason |
| 3582 */ |
| 3583 static const HintCode MISSING_REQUIRED_PARAM = const HintCode( |
| 3584 'MISSING_REQUIRED_PARAM', "The parameter '{0}' is required. {1}"); |
| 3585 |
| 3586 /** |
| 3575 * Generate a hint for methods or functions that have a return type, but do | 3587 * Generate a hint for methods or functions that have a return type, but do |
| 3576 * not have a non-void return statement on all branches. At the end of methods | 3588 * not have a non-void return statement on all branches. At the end of methods |
| 3577 * or functions with no return, Dart implicitly returns `null`, avoiding these | 3589 * or functions with no return, Dart implicitly returns `null`, avoiding these |
| 3578 * implicit returns is considered a best practice. | 3590 * implicit returns is considered a best practice. |
| 3579 * | 3591 * |
| 3580 * Parameters: | 3592 * Parameters: |
| 3581 * 0: the name of the declared return type | 3593 * 0: the name of the declared return type |
| 3582 */ | 3594 */ |
| 3583 static const HintCode MISSING_RETURN = const HintCode( | 3595 static const HintCode MISSING_RETURN = const HintCode( |
| 3584 'MISSING_RETURN', | 3596 'MISSING_RETURN', |
| (...skipping 2163 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 5748 * Initialize a newly created error code to have the given [name]. | 5760 * Initialize a newly created error code to have the given [name]. |
| 5749 */ | 5761 */ |
| 5750 const TodoCode(String name) : super(name, "{0}"); | 5762 const TodoCode(String name) : super(name, "{0}"); |
| 5751 | 5763 |
| 5752 @override | 5764 @override |
| 5753 ErrorSeverity get errorSeverity => ErrorSeverity.INFO; | 5765 ErrorSeverity get errorSeverity => ErrorSeverity.INFO; |
| 5754 | 5766 |
| 5755 @override | 5767 @override |
| 5756 ErrorType get type => ErrorType.TODO; | 5768 ErrorType get type => ErrorType.TODO; |
| 5757 } | 5769 } |
| OLD | NEW |