Skip to content

Commit 65b9f70

Browse files
committed
Update API baselines
1 parent a989cfd commit 65b9f70

File tree

2 files changed

+20
-4
lines changed

2 files changed

+20
-4
lines changed

tests/baselines/reference/api/tsserverlibrary.d.ts

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4414,7 +4414,8 @@ declare namespace ts {
44144414
ReachabilityCheckFlags = 768,
44154415
ReachabilityAndEmitFlags = 2816,
44164416
ContextFlags = 50720768,
4417-
TypeExcludesFlags = 40960
4417+
TypeExcludesFlags = 40960,
4418+
IdentifierIsInJSDocNamespace = 2048
44184419
}
44194420
enum ModifierFlags {
44204421
None = 0,
@@ -4584,8 +4585,10 @@ declare namespace ts {
45844585
* Text of identifier, but if the identifier begins with two underscores, this will begin with three.
45854586
*/
45864587
readonly escapedText: __String;
4588+
/** @deprecated Use `idKeyword(identifier)` instead. */
45874589
readonly originalKeywordKind?: SyntaxKind;
4588-
/** @deprecated */ readonly isInJSDocNamespace?: boolean;
4590+
/** @deprecated Use `identifier.flags & NodeFlags.IdentifierIsInJSDocNamespace` instead. */
4591+
readonly isInJSDocNamespace?: boolean;
45894592
}
45904593
interface Identifier {
45914594
readonly text: string;
@@ -8598,6 +8601,11 @@ declare namespace ts {
85988601
*/
85998602
function unescapeLeadingUnderscores(identifier: __String): string;
86008603
function idText(identifierOrPrivateName: Identifier | PrivateIdentifier): string;
8604+
/**
8605+
* If the text of an Identifier matches a keyword (including contextual and TypeScript-specific keywords), returns the
8606+
* SyntaxKind for the matching keyword.
8607+
*/
8608+
function idKeyword(node: Identifier): SyntaxKind | undefined;
86018609
function symbolName(symbol: Symbol): string;
86028610
function getNameOfJSDocTypedef(declaration: JSDocTypedefTag): Identifier | PrivateIdentifier | undefined;
86038611
function getNameOfDeclaration(declaration: Declaration | Expression | undefined): DeclarationName | undefined;

tests/baselines/reference/api/typescript.d.ts

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -479,7 +479,8 @@ declare namespace ts {
479479
ReachabilityCheckFlags = 768,
480480
ReachabilityAndEmitFlags = 2816,
481481
ContextFlags = 50720768,
482-
TypeExcludesFlags = 40960
482+
TypeExcludesFlags = 40960,
483+
IdentifierIsInJSDocNamespace = 2048
483484
}
484485
enum ModifierFlags {
485486
None = 0,
@@ -649,8 +650,10 @@ declare namespace ts {
649650
* Text of identifier, but if the identifier begins with two underscores, this will begin with three.
650651
*/
651652
readonly escapedText: __String;
653+
/** @deprecated Use `idKeyword(identifier)` instead. */
652654
readonly originalKeywordKind?: SyntaxKind;
653-
/** @deprecated */ readonly isInJSDocNamespace?: boolean;
655+
/** @deprecated Use `identifier.flags & NodeFlags.IdentifierIsInJSDocNamespace` instead. */
656+
readonly isInJSDocNamespace?: boolean;
654657
}
655658
interface Identifier {
656659
readonly text: string;
@@ -4663,6 +4666,11 @@ declare namespace ts {
46634666
*/
46644667
function unescapeLeadingUnderscores(identifier: __String): string;
46654668
function idText(identifierOrPrivateName: Identifier | PrivateIdentifier): string;
4669+
/**
4670+
* If the text of an Identifier matches a keyword (including contextual and TypeScript-specific keywords), returns the
4671+
* SyntaxKind for the matching keyword.
4672+
*/
4673+
function idKeyword(node: Identifier): SyntaxKind | undefined;
46664674
function symbolName(symbol: Symbol): string;
46674675
function getNameOfJSDocTypedef(declaration: JSDocTypedefTag): Identifier | PrivateIdentifier | undefined;
46684676
function getNameOfDeclaration(declaration: Declaration | Expression | undefined): DeclarationName | undefined;

0 commit comments

Comments
 (0)