Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(564)

Unified Diff: pkg/analyzer/lib/src/generated/error.dart

Issue 1530993002: Report HintCode.UNDEFINED_IDENTIFIER and HintCode.UNDEFINED_MEMBER for unresolved names in comments. Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 5 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: pkg/analyzer/lib/src/generated/error.dart
diff --git a/pkg/analyzer/lib/src/generated/error.dart b/pkg/analyzer/lib/src/generated/error.dart
index aa43a7e29494da95c0c4101c92bea782bb851e2d..6e9b29c6425e841dd8040419a8fa385510572829 100644
--- a/pkg/analyzer/lib/src/generated/error.dart
+++ b/pkg/analyzer/lib/src/generated/error.dart
@@ -2705,6 +2705,8 @@ abstract class ErrorCode {
HintCode.TYPE_CHECK_IS_NOT_NULL,
HintCode.TYPE_CHECK_IS_NULL,
HintCode.UNDEFINED_GETTER,
+ HintCode.UNDEFINED_IDENTIFIER,
+ HintCode.UNDEFINED_MEMBER,
HintCode.UNDEFINED_METHOD,
HintCode.UNDEFINED_OPERATOR,
HintCode.UNDEFINED_SETTER,
@@ -3633,6 +3635,31 @@ class HintCode extends ErrorCode {
/**
* This hint is generated anywhere where the
+ * [StaticWarningCode.UNDEFINED_IDENTIFIER] would have been generated, if it
+ * were required by the specification.
+ *
+ * Parameters:
+ * 0: the name of the identifier
+ */
+ static const HintCode UNDEFINED_IDENTIFIER =
+ const HintCode('UNDEFINED_IDENTIFIER', "Undefined name '{0}'");
+
+ /**
+ * This hint is generated anywhere where the
+ * [StaticTypeWarningCode.UNDEFINED_GETTER],
+ * [StaticTypeWarningCode.UNDEFINED_METHOD] or
+ * [StaticTypeWarningCode.UNDEFINED_SETTER] would have been generated, if it
+ * were required by the specification.
+ *
+ * Parameters:
+ * 0: the name of the member that is undefined
+ * 1: the resolved type name that the method lookup is happening on
+ */
+ static const HintCode UNDEFINED_MEMBER = const HintCode('UNDEFINED_MEMBER',
+ "The member '{0}' is not defined for the class '{1}'");
+
+ /**
+ * This hint is generated anywhere where the
* [StaticTypeWarningCode.UNDEFINED_METHOD] would have been generated, if we
* used propagated information for the warnings.
*
« no previous file with comments | « pkg/analyzer/lib/src/generated/element_resolver.dart ('k') | pkg/analyzer/test/generated/resolver_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698