mirror of
https://github.com/microsoft/TypeScript.git
synced 2026-05-19 20:37:00 -05:00
fix(55939): JS Doc comment not shown in signature help when overload tag exists (#56139)
This commit is contained in:
@@ -43,6 +43,7 @@ import {
|
||||
isFunctionTypeNode,
|
||||
isIdentifier,
|
||||
isJSDoc,
|
||||
isJSDocOverloadTag,
|
||||
isJSDocParameterTag,
|
||||
isJSDocPropertyLikeTag,
|
||||
isJSDocTypeLiteral,
|
||||
@@ -230,6 +231,11 @@ function getCommentHavingNodes(declaration: Declaration): readonly (JSDoc | JSDo
|
||||
case SyntaxKind.JSDocCallbackTag:
|
||||
case SyntaxKind.JSDocTypedefTag:
|
||||
return [declaration as JSDocTypedefTag, (declaration as JSDocTypedefTag).parent];
|
||||
case SyntaxKind.JSDocSignature:
|
||||
if (isJSDocOverloadTag(declaration.parent)) {
|
||||
return [declaration.parent.parent];
|
||||
}
|
||||
// falls through
|
||||
default:
|
||||
return getJSDocCommentsAndTags(declaration);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user