mirror of
https://github.com/microsoft/TypeScript.git
synced 2026-05-17 01:49:57 -05:00
Merge pull request #29352 from Microsoft/qualified-name-param-tag-error
Qualified name param tag error
This commit is contained in:
@@ -24785,9 +24785,17 @@ namespace ts {
|
||||
return;
|
||||
}
|
||||
if (!containsArgumentsReference(decl)) {
|
||||
error(node.name,
|
||||
Diagnostics.JSDoc_param_tag_has_name_0_but_there_is_no_parameter_with_that_name,
|
||||
idText(node.name.kind === SyntaxKind.QualifiedName ? node.name.right : node.name));
|
||||
if (isQualifiedName(node.name)) {
|
||||
error(node.name,
|
||||
Diagnostics.Qualified_name_0_is_not_allowed_without_a_leading_param_object_1,
|
||||
entityNameToString(node.name),
|
||||
entityNameToString(node.name.left));
|
||||
}
|
||||
else {
|
||||
error(node.name,
|
||||
Diagnostics.JSDoc_param_tag_has_name_0_but_there_is_no_parameter_with_that_name,
|
||||
idText(node.name));
|
||||
}
|
||||
}
|
||||
else if (findLast(getJSDocTags(decl), isJSDocParameterTag) === node &&
|
||||
node.typeExpression && node.typeExpression.type &&
|
||||
|
||||
@@ -4266,6 +4266,10 @@
|
||||
"category": "Error",
|
||||
"code": 8031
|
||||
},
|
||||
"Qualified name '{0}' is not allowed without a leading '@param {object} {1}'.": {
|
||||
"category": "Error",
|
||||
"code": 8032
|
||||
},
|
||||
"Only identifiers/qualified-names with optional type arguments are currently supported in a class 'extends' clause.": {
|
||||
"category": "Error",
|
||||
"code": 9002
|
||||
|
||||
Reference in New Issue
Block a user