@@ -8148,12 +8148,14 @@ namespace ts {
8148
8148
&& nextTokenJSDoc ( ) === SyntaxKind . AtToken
8149
8149
&& tokenIsIdentifierOrKeyword ( nextTokenJSDoc ( ) ) ) {
8150
8150
const kind = scanner . getTokenValue ( ) ;
8151
- if ( kind === "link" || kind === "linkcode" || kind === "linkplain" ) {
8152
- return kind ;
8153
- }
8151
+ if ( isJSDocLinkTag ( kind ) ) return kind ;
8154
8152
}
8155
8153
}
8156
8154
8155
+ function isJSDocLinkTag ( kind : string ) {
8156
+ return kind === "link" || kind === "linkcode" || kind === "linkplain" ;
8157
+ }
8158
+
8157
8159
function parseUnknownTag ( start : number , tagName : Identifier , indent : number , indentText : string ) {
8158
8160
return finishNode ( factory . createJSDocUnknownTag ( tagName , parseTrailingTagComments ( start , getNodePos ( ) , indent , indentText ) ) , start ) ;
8159
8161
}
@@ -8276,7 +8278,7 @@ namespace ts {
8276
8278
8277
8279
function parseSeeTag ( start : number , tagName : Identifier , indent ?: number , indentText ?: string ) : JSDocSeeTag {
8278
8280
const isMarkdownOrJSDocLink = token ( ) === SyntaxKind . OpenBracketToken
8279
- || lookAhead ( ( ) => nextTokenJSDoc ( ) === SyntaxKind . AtToken && tokenIsIdentifierOrKeyword ( nextTokenJSDoc ( ) ) && scanner . getTokenValue ( ) === "link" ) ;
8281
+ || lookAhead ( ( ) => nextTokenJSDoc ( ) === SyntaxKind . AtToken && tokenIsIdentifierOrKeyword ( nextTokenJSDoc ( ) ) && isJSDocLinkTag ( scanner . getTokenValue ( ) ) ) ;
8280
8282
const nameExpression = isMarkdownOrJSDocLink ? undefined : parseJSDocNameReference ( ) ;
8281
8283
const comments = indent !== undefined && indentText !== undefined ? parseTrailingTagComments ( start , getNodePos ( ) , indent , indentText ) : undefined ;
8282
8284
return finishNode ( factory . createJSDocSeeTag ( tagName , nameExpression , comments ) , start ) ;
0 commit comments