Add jsdoc member names: Class#method (#44150)

* Everything mostly works

A couple of mixed, nested references don't work yet.
The scanner+parser interaction is wrong, the parser consumes one too
many spaces, and the checker+services code needs a little cleanup.

* Cleanup

1. I decided that correctly parsing a#b.c, an entity name containing an
instance reference, is not worth the work.
2. I made the scanner, at least the jsdoc part, emit a # token, and
provided a reScanPrivateIdentifier in order to convert #a to # a.
3. I cleaned up the code in the checker.
2. Unrelated: I added a missing space in linkPart display.

* Cleanup lint + var naming

* investigate+clean up a couple of TODOs

* Fix lint in utilities.ts

* change name to JSDocMemberName

* address PR comments
This commit is contained in:
Nathan Shively-Sanders
2021-05-21 07:53:17 -07:00
committed by GitHub
parent 71cdf6a920
commit 086423729a
19 changed files with 2244 additions and 714 deletions
+42 -44
View File
@@ -39156,16 +39156,6 @@ namespace ts {
return node.parent.kind === SyntaxKind.ExpressionWithTypeArguments;
}
function getJSDocEntryNameReference(node: Identifier | PrivateIdentifier | PropertyAccessExpression | QualifiedName): JSDocNameReference | undefined {
while (node.parent.kind === SyntaxKind.QualifiedName) {
node = node.parent as QualifiedName;
}
while (node.parent.kind === SyntaxKind.PropertyAccessExpression) {
node = node.parent as PropertyAccessExpression;
}
return isJSDocNameReference(node.parent) ? node.parent : undefined;
}
function forEachEnclosingClass<T>(node: Node, callback: (node: Node) => T | undefined): T | undefined {
let result: T | undefined;
@@ -39240,7 +39230,7 @@ namespace ts {
return undefined;
}
function getSymbolOfNameOrPropertyAccessExpression(name: EntityName | PrivateIdentifier | PropertyAccessExpression): Symbol | undefined {
function getSymbolOfNameOrPropertyAccessExpression(name: EntityName | PrivateIdentifier | PropertyAccessExpression | JSDocMemberName): Symbol | undefined {
if (isDeclarationName(name)) {
return getSymbolOfNode(name.parent);
}
@@ -39249,7 +39239,7 @@ namespace ts {
name.parent.kind === SyntaxKind.PropertyAccessExpression &&
name.parent === (name.parent.parent as BinaryExpression).left) {
// Check if this is a special property assignment
if (!isPrivateIdentifier(name)) {
if (!isPrivateIdentifier(name) && !isJSDocMemberName(name)) {
const specialPropertyAssignmentSymbol = getSpecialPropertyAssignmentSymbolFromEntityName(name);
if (specialPropertyAssignmentSymbol) {
return specialPropertyAssignmentSymbol;
@@ -39265,14 +39255,14 @@ namespace ts {
return success;
}
}
else if (!isPropertyAccessExpression(name) && !isPrivateIdentifier(name) && isInRightSideOfImportOrExportAssignment(name)) {
else if (isEntityName(name) && isInRightSideOfImportOrExportAssignment(name)) {
// Since we already checked for ExportAssignment, this really could only be an Import
const importEqualsDeclaration = getAncestor(name, SyntaxKind.ImportEqualsDeclaration);
Debug.assert(importEqualsDeclaration !== undefined);
return getSymbolOfPartOfRightHandSideOfImportEquals(name, /*dontResolveAlias*/ true);
}
if (!isPropertyAccessExpression(name) && !isPrivateIdentifier(name)) {
if (isEntityName(name)) {
const possibleImportNode = isImportTypeQualifierPart(name);
if (possibleImportNode) {
getTypeFromTypeNode(possibleImportNode);
@@ -39281,8 +39271,8 @@ namespace ts {
}
}
while (isRightSideOfQualifiedNameOrPropertyAccess(name)) {
name = name.parent as QualifiedName | PropertyAccessEntityNameExpression;
while (isRightSideOfQualifiedNameOrPropertyAccessOrJSDocMemberName(name)) {
name = name.parent as QualifiedName | PropertyAccessEntityNameExpression | JSDocMemberName;
}
if (isHeritageClauseElementIdentifier(name)) {
@@ -39323,12 +39313,14 @@ namespace ts {
return undefined;
}
const isJSDoc = findAncestor(name, or(isJSDocLink, isJSDocNameReference, isJSDocMemberName));
const meaning = isJSDoc ? SymbolFlags.Type | SymbolFlags.Namespace | SymbolFlags.Value : SymbolFlags.Value;
if (name.kind === SyntaxKind.Identifier) {
if (isJSXTagName(name) && isJsxIntrinsicIdentifier(name)) {
const symbol = getIntrinsicTagSymbol(name.parent as JsxOpeningLikeElement);
return symbol === unknownSymbol ? undefined : symbol;
}
return resolveEntityName(name, SymbolFlags.Value, /*ignoreErrors*/ false, /*dontResolveAlias*/ true);
return resolveEntityName(name, meaning, /*ignoreErrors*/ false, /*dontResolveAlias*/ !isJSDoc, getHostSignatureFromJSDoc(name));
}
else if (name.kind === SyntaxKind.PropertyAccessExpression || name.kind === SyntaxKind.QualifiedName) {
const links = getNodeLinks(name);
@@ -39342,40 +39334,19 @@ namespace ts {
else {
checkQualifiedName(name, CheckMode.Normal);
}
if (!links.resolvedSymbol && isJSDoc && isQualifiedName(name)) {
return resolveJSDocMemberName(name);
}
return links.resolvedSymbol;
}
else if (isJSDocMemberName(name)) {
return resolveJSDocMemberName(name);
}
}
else if (isTypeReferenceIdentifier(name as EntityName)) {
const meaning = name.parent.kind === SyntaxKind.TypeReference ? SymbolFlags.Type : SymbolFlags.Namespace;
return resolveEntityName(name as EntityName, meaning, /*ignoreErrors*/ false, /*dontResolveAlias*/ true);
}
const jsdocReference = getJSDocEntryNameReference(name);
if (jsdocReference || isJSDocLink(name.parent)) {
const meaning = SymbolFlags.Type | SymbolFlags.Namespace | SymbolFlags.Value;
const symbol = resolveEntityName(name as EntityName, meaning, /*ignoreErrors*/ false, /*dontResolveAlias*/ false, getHostSignatureFromJSDoc(name));
if (symbol) {
return symbol;
}
else if (isQualifiedName(name) && isIdentifier(name.left)) {
// resolve C.m as a static member first
const links = getNodeLinks(name);
if (links.resolvedSymbol) {
return links.resolvedSymbol;
}
checkQualifiedName(name, CheckMode.Normal);
if (links.resolvedSymbol) {
return links.resolvedSymbol;
}
// then resolve it as an instance member
const s = resolveEntityName(name.left, meaning, /*ignoreErrors*/ false);
if (s) {
const t = getDeclaredTypeOfSymbol(s);
return getPropertyOfType(t, name.right.escapedText);
}
}
}
if (name.parent.kind === SyntaxKind.TypePredicate) {
return resolveEntityName(name as Identifier, /*meaning*/ SymbolFlags.FunctionScopedVariable);
}
@@ -39383,6 +39354,33 @@ namespace ts {
return undefined;
}
/**
* Recursively resolve entity names and jsdoc instance references:
* 1. K#m as K.prototype.m for a class (or other value) K
* 2. K.m as K.prototype.m
* 3. I.m as I.m for a type I, or any other I.m that fails to resolve in (1) or (2)
*/
function resolveJSDocMemberName(name: EntityName | JSDocMemberName): Symbol | undefined {
if (isEntityName(name)) {
const symbol = resolveEntityName(
name,
SymbolFlags.Type | SymbolFlags.Namespace | SymbolFlags.Value,
/*ignoreErrors*/ false,
/*dontResolveAlias*/ true,
getHostSignatureFromJSDoc(name));
if (symbol || isIdentifier(name)) {
// can't recur on identifier, so just return when it's undefined
return symbol;
}
}
const left = resolveJSDocMemberName(name.left);
if (left) {
const proto = left.flags & SymbolFlags.Value && getPropertyOfType(getTypeOfSymbol(left), "prototype" as __String);
const t = proto ? getTypeOfSymbol(proto) : getDeclaredTypeOfSymbol(left);
return getPropertyOfType(t, name.right.escapedText);
}
}
function getSymbolAtLocation(node: Node, ignoreErrors?: boolean): Symbol | undefined {
if (node.kind === SyntaxKind.SourceFile) {
return isExternalModule(node as SourceFile) ? getMergedSymbol(node.symbol) : undefined;
+25 -4
View File
@@ -345,6 +345,8 @@ namespace ts {
updateJSDocSeeTag,
createJSDocNameReference,
updateJSDocNameReference,
createJSDocMemberName,
updateJSDocMemberName,
createJSDocLink,
updateJSDocLink,
// lazily load factory members for JSDoc tags with similar structure
@@ -4391,21 +4393,40 @@ namespace ts {
}
// @api
function createJSDocNameReference(name: EntityName): JSDocNameReference {
function createJSDocNameReference(name: EntityName | JSDocMemberName): JSDocNameReference {
const node = createBaseNode<JSDocNameReference>(SyntaxKind.JSDocNameReference);
node.name = name;
return node;
}
// @api
function updateJSDocNameReference(node: JSDocNameReference, name: EntityName): JSDocNameReference {
function updateJSDocNameReference(node: JSDocNameReference, name: EntityName | JSDocMemberName): JSDocNameReference {
return node.name !== name
? update(createJSDocNameReference(name), node)
: node;
}
// @api
function createJSDocLink(name: EntityName | undefined, text: string): JSDocLink {
function createJSDocMemberName(left: EntityName | JSDocMemberName, right: Identifier) {
const node = createBaseNode<JSDocMemberName>(SyntaxKind.JSDocMemberName);
node.left = left;
node.right = right;
node.transformFlags |=
propagateChildFlags(node.left) |
propagateChildFlags(node.right);
return node;
}
// @api
function updateJSDocMemberName(node: JSDocMemberName, left: EntityName | JSDocMemberName, right: Identifier) {
return node.left !== left
|| node.right !== right
? update(createJSDocMemberName(left, right), node)
: node;
}
// @api
function createJSDocLink(name: EntityName | JSDocMemberName | undefined, text: string): JSDocLink {
const node = createBaseNode<JSDocLink>(SyntaxKind.JSDocLink);
node.name = name;
node.text = text;
@@ -4413,7 +4434,7 @@ namespace ts {
}
// @api
function updateJSDocLink(node: JSDocLink, name: EntityName | undefined, text: string): JSDocLink {
function updateJSDocLink(node: JSDocLink, name: EntityName | JSDocMemberName | undefined, text: string): JSDocLink {
return node.name !== name
? update(createJSDocLink(name, text), node)
: node;
+4
View File
@@ -770,6 +770,10 @@ namespace ts {
return node.kind === SyntaxKind.JSDocNameReference;
}
export function isJSDocMemberName(node: Node): node is JSDocMemberName {
return node.kind === SyntaxKind.JSDocMemberName;
}
export function isJSDocLink(node: Node): node is JSDocLink {
return node.kind === SyntaxKind.JSDocLink;
}
+23 -2
View File
@@ -489,6 +489,9 @@ namespace ts {
(typeof (node as JSDoc).comment === "string" ? undefined : visitNodes(cbNode, cbNodes, (node as JSDoc).comment as NodeArray<JSDocText | JSDocLink> | undefined));
case SyntaxKind.JSDocNameReference:
return visitNode(cbNode, (node as JSDocNameReference).name);
case SyntaxKind.JSDocMemberName:
return visitNode(cbNode, (node as JSDocMemberName).left) ||
visitNode(cbNode, (node as JSDocMemberName).right);
case SyntaxKind.JSDocParameterTag:
case SyntaxKind.JSDocPropertyTag:
return visitNode(cbNode, (node as JSDocTag).tagName) ||
@@ -1424,6 +1427,10 @@ namespace ts {
return currentToken = scanner.reScanLessThanToken();
}
function reScanHashToken(): SyntaxKind {
return currentToken = scanner.reScanHashToken();
}
function scanJsxIdentifier(): SyntaxKind {
return currentToken = scanner.scanJsxIdentifier();
}
@@ -7338,7 +7345,13 @@ namespace ts {
export function parseJSDocNameReference(): JSDocNameReference {
const pos = getNodePos();
const hasBrace = parseOptional(SyntaxKind.OpenBraceToken);
const entityName = parseEntityName(/* allowReservedWords*/ false);
const p2 = getNodePos();
let entityName: EntityName | JSDocMemberName = parseEntityName(/* allowReservedWords*/ false);
while (token() === SyntaxKind.PrivateIdentifier) {
reScanHashToken(); // rescan #id as # id
nextTokenJSDoc(); // then skip the #
entityName = finishNode(factory.createJSDocMemberName(entityName, parseIdentifier()), p2);
}
if (hasBrace) {
parseExpectedJSDoc(SyntaxKind.CloseBraceToken);
}
@@ -7793,9 +7806,17 @@ namespace ts {
nextTokenJSDoc(); // start at token after link, then skip any whitespace
skipWhitespace();
// parseEntityName logs an error for non-identifier, so create a MissingNode ourselves to avoid the error
const name = tokenIsIdentifierOrKeyword(token())
const p2 = getNodePos();
let name: EntityName | JSDocMemberName | undefined = tokenIsIdentifierOrKeyword(token())
? parseEntityName(/*allowReservedWords*/ true)
: undefined;
if (name) {
while (token() === SyntaxKind.PrivateIdentifier) {
reScanHashToken(); // rescan #id as # id
nextTokenJSDoc(); // then skip the #
name = finishNode(factory.createJSDocMemberName(name, parseIdentifier()), p2);
}
}
const text = [];
while (token() !== SyntaxKind.CloseBraceToken && token() !== SyntaxKind.NewLineTrivia && token() !== SyntaxKind.EndOfFileToken) {
text.push(scanner.getTokenText());
+14 -1
View File
@@ -42,6 +42,7 @@ namespace ts {
reScanJsxAttributeValue(): SyntaxKind;
reScanJsxToken(allowMultilineJsxText?: boolean): JsxTokenSyntaxKind;
reScanLessThanToken(): SyntaxKind;
reScanHashToken(): SyntaxKind;
reScanQuestionToken(): SyntaxKind;
reScanInvalidIdentifier(): SyntaxKind;
scanJsxToken(): JsxTokenSyntaxKind;
@@ -220,7 +221,8 @@ namespace ts {
"&&=": SyntaxKind.AmpersandAmpersandEqualsToken,
"??=": SyntaxKind.QuestionQuestionEqualsToken,
"@": SyntaxKind.AtToken,
"`": SyntaxKind.BacktickToken
"#": SyntaxKind.HashToken,
"`": SyntaxKind.BacktickToken,
}));
/*
@@ -981,6 +983,7 @@ namespace ts {
reScanJsxAttributeValue,
reScanJsxToken,
reScanLessThanToken,
reScanHashToken,
reScanQuestionToken,
reScanInvalidIdentifier,
scanJsxToken,
@@ -2240,6 +2243,14 @@ namespace ts {
return token;
}
function reScanHashToken(): SyntaxKind {
if (token === SyntaxKind.PrivateIdentifier) {
pos = tokenPos + 1;
return token = SyntaxKind.HashToken;
}
return token;
}
function reScanQuestionToken(): SyntaxKind {
Debug.assert(token === SyntaxKind.QuestionQuestionToken, "'reScanQuestionToken' should only be called on a '??'");
pos = tokenPos + 1;
@@ -2426,6 +2437,8 @@ namespace ts {
return token = SyntaxKind.DotToken;
case CharacterCodes.backtick:
return token = SyntaxKind.BacktickToken;
case CharacterCodes.hash:
return token = SyntaxKind.HashToken;
case CharacterCodes.backslash:
pos--;
const extendedCookedChar = peekExtendedUnicodeEscape();
+20 -6
View File
@@ -88,6 +88,8 @@ namespace ts {
QuestionQuestionToken,
/** Only the JSDoc scanner produces BacktickToken. The normal scanner produces NoSubstitutionTemplateLiteral and related kinds. */
BacktickToken,
/** Only the JSDoc scanner produces HashToken. The normal scanner produces PrivateIdentifier. */
HashToken,
// Assignments
EqualsToken,
PlusEqualsToken,
@@ -362,6 +364,7 @@ namespace ts {
// JSDoc nodes
JSDocTypeExpression,
JSDocNameReference,
JSDocMemberName, // C#p
JSDocAllType, // The * type
JSDocUnknownType, // The ? type
JSDocNullableType,
@@ -517,6 +520,7 @@ namespace ts {
| SyntaxKind.ColonToken
| SyntaxKind.AtToken
| SyntaxKind.BacktickToken
| SyntaxKind.HashToken
| SyntaxKind.EqualsToken
| SyntaxKind.PlusEqualsToken
| SyntaxKind.MinusEqualsToken
@@ -722,6 +726,7 @@ namespace ts {
| SyntaxKind.DotToken
| SyntaxKind.Identifier
| SyntaxKind.BacktickToken
| SyntaxKind.HashToken
| SyntaxKind.Unknown
| KeywordSyntaxKind
;
@@ -3123,7 +3128,14 @@ namespace ts {
export interface JSDocNameReference extends Node {
readonly kind: SyntaxKind.JSDocNameReference;
readonly name: EntityName;
readonly name: EntityName | JSDocMemberName;
}
/** Class#method reference in JSDoc */
export interface JSDocMemberName extends Node {
readonly kind: SyntaxKind.JSDocMemberName;
readonly left: EntityName | JSDocMemberName;
readonly right: Identifier;
}
export interface JSDocType extends TypeNode {
@@ -3189,7 +3201,7 @@ namespace ts {
export interface JSDocLink extends Node {
readonly kind: SyntaxKind.JSDocLink;
readonly name?: EntityName;
readonly name?: EntityName | JSDocMemberName;
text: string;
}
@@ -7279,10 +7291,12 @@ namespace ts {
updateJSDocNamepathType(node: JSDocNamepathType, type: TypeNode): JSDocNamepathType;
createJSDocTypeExpression(type: TypeNode): JSDocTypeExpression;
updateJSDocTypeExpression(node: JSDocTypeExpression, type: TypeNode): JSDocTypeExpression;
createJSDocNameReference(name: EntityName): JSDocNameReference;
updateJSDocNameReference(node: JSDocNameReference, name: EntityName): JSDocNameReference;
createJSDocLink(name: EntityName | undefined, text: string): JSDocLink;
updateJSDocLink(node: JSDocLink, name: EntityName | undefined, text: string): JSDocLink;
createJSDocNameReference(name: EntityName | JSDocMemberName): JSDocNameReference;
updateJSDocNameReference(node: JSDocNameReference, name: EntityName | JSDocMemberName): JSDocNameReference;
createJSDocMemberName(left: EntityName | JSDocMemberName, right: Identifier): JSDocMemberName;
updateJSDocMemberName(node: JSDocMemberName, left: EntityName | JSDocMemberName, right: Identifier): JSDocMemberName;
createJSDocLink(name: EntityName | JSDocMemberName | undefined, text: string): JSDocLink;
updateJSDocLink(node: JSDocLink, name: EntityName | JSDocMemberName | undefined, text: string): JSDocLink;
createJSDocTypeLiteral(jsDocPropertyTags?: readonly JSDocPropertyLikeTag[], isArrayType?: boolean): JSDocTypeLiteral;
updateJSDocTypeLiteral(node: JSDocTypeLiteral, jsDocPropertyTags: readonly JSDocPropertyLikeTag[] | undefined, isArrayType: boolean | undefined): JSDocTypeLiteral;
createJSDocSignature(typeParameters: readonly JSDocTemplateTag[] | undefined, parameters: readonly JSDocParameterTag[], type?: JSDocReturnTag): JSDocSignature;
+16 -3
View File
@@ -962,7 +962,7 @@ namespace ts {
}
}
export function entityNameToString(name: EntityNameOrEntityNameExpression | JsxTagNameExpression | PrivateIdentifier): string {
export function entityNameToString(name: EntityNameOrEntityNameExpression | JSDocMemberName | JsxTagNameExpression | PrivateIdentifier): string {
switch (name.kind) {
case SyntaxKind.ThisKeyword:
return "this";
@@ -978,6 +978,8 @@ namespace ts {
else {
return Debug.assertNever(name.name);
}
case SyntaxKind.JSDocMemberName:
return entityNameToString(name.left) + entityNameToString(name.right);
default:
return Debug.assertNever(name);
}
@@ -1896,9 +1898,14 @@ namespace ts {
while (node.parent.kind === SyntaxKind.QualifiedName) {
node = node.parent;
}
return node.parent.kind === SyntaxKind.TypeQuery || isJSXTagName(node);
return node.parent.kind === SyntaxKind.TypeQuery || isJSDocLink(node.parent) || isJSDocNameReference(node.parent) || isJSDocMemberName(node.parent) || isJSXTagName(node);
case SyntaxKind.JSDocMemberName:
while (isJSDocMemberName(node.parent)) {
node = node.parent;
}
return node.parent.kind === SyntaxKind.TypeQuery || isJSDocLink(node.parent) || isJSDocNameReference(node.parent) || isJSDocMemberName(node.parent) || isJSXTagName(node);
case SyntaxKind.Identifier:
if (node.parent.kind === SyntaxKind.TypeQuery || isJSXTagName(node)) {
if (node.parent.kind === SyntaxKind.TypeQuery || isJSDocLink(node.parent) || isJSDocNameReference(node.parent) || isJSDocMemberName(node.parent) || isJSXTagName(node)) {
return true;
}
// falls through
@@ -4932,6 +4939,12 @@ namespace ts {
(node.parent.kind === SyntaxKind.PropertyAccessExpression && (node.parent as PropertyAccessExpression).name === node);
}
export function isRightSideOfQualifiedNameOrPropertyAccessOrJSDocMemberName(node: Node) {
return isQualifiedName(node.parent) && node.parent.right === node
|| isPropertyAccessExpression(node.parent) && node.parent.name === node
|| isJSDocMemberName(node.parent) && node.parent.right === node;
}
export function isEmptyObjectLiteral(expression: Node): boolean {
return expression.kind === SyntaxKind.ObjectLiteralExpression &&
(expression as ObjectLiteralExpression).properties.length === 0;
+4
View File
@@ -1401,6 +1401,10 @@ namespace ts.FindAllReferences {
// Compare the length so we filter out strict superstrings of the symbol we are looking for
switch (node.kind) {
case SyntaxKind.PrivateIdentifier:
if (isJSDocMemberName(node.parent)) {
return true;
}
// falls through I guess
case SyntaxKind.Identifier:
return (node as PrivateIdentifier | Identifier).text.length === searchSymbolName.length;
case SyntaxKind.NoSubstitutionTemplateLiteral:
+3 -3
View File
@@ -105,7 +105,7 @@ namespace ts {
else if (isDeclarationName(node)) {
return getMeaningFromDeclaration(node.parent);
}
else if (isEntityName(node) && (isJSDocNameReference(node.parent) || isJSDocLink(node.parent))) {
else if (isEntityName(node) && findAncestor(node, or(isJSDocNameReference, isJSDocLink, isJSDocMemberName))) {
return SemanticMeaning.All;
}
else if (isTypeReference(node)) {
@@ -2218,7 +2218,7 @@ namespace ts {
return displayPart(text, SymbolDisplayPartKind.linkText);
}
export function linkNamePart(name: EntityName, target: Declaration): JSDocLinkDisplayPart {
export function linkNamePart(name: EntityName | JSDocMemberName, target: Declaration): JSDocLinkDisplayPart {
return {
text: getTextOfNode(name),
kind: SymbolDisplayPartKind[SymbolDisplayPartKind.linkName],
@@ -2246,7 +2246,7 @@ namespace ts {
if (link.text) {parts.push(linkTextPart(link.text));}
}
else {
parts.push(linkTextPart(getTextOfNode(link.name) + link.text));
parts.push(linkTextPart(getTextOfNode(link.name) + " " + link.text));
}
}
parts.push(linkPart("}"));
+327 -314
View File
@@ -166,306 +166,309 @@ declare namespace ts {
QuestionQuestionToken = 60,
/** Only the JSDoc scanner produces BacktickToken. The normal scanner produces NoSubstitutionTemplateLiteral and related kinds. */
BacktickToken = 61,
EqualsToken = 62,
PlusEqualsToken = 63,
MinusEqualsToken = 64,
AsteriskEqualsToken = 65,
AsteriskAsteriskEqualsToken = 66,
SlashEqualsToken = 67,
PercentEqualsToken = 68,
LessThanLessThanEqualsToken = 69,
GreaterThanGreaterThanEqualsToken = 70,
GreaterThanGreaterThanGreaterThanEqualsToken = 71,
AmpersandEqualsToken = 72,
BarEqualsToken = 73,
BarBarEqualsToken = 74,
AmpersandAmpersandEqualsToken = 75,
QuestionQuestionEqualsToken = 76,
CaretEqualsToken = 77,
Identifier = 78,
PrivateIdentifier = 79,
BreakKeyword = 80,
CaseKeyword = 81,
CatchKeyword = 82,
ClassKeyword = 83,
ConstKeyword = 84,
ContinueKeyword = 85,
DebuggerKeyword = 86,
DefaultKeyword = 87,
DeleteKeyword = 88,
DoKeyword = 89,
ElseKeyword = 90,
EnumKeyword = 91,
ExportKeyword = 92,
ExtendsKeyword = 93,
FalseKeyword = 94,
FinallyKeyword = 95,
ForKeyword = 96,
FunctionKeyword = 97,
IfKeyword = 98,
ImportKeyword = 99,
InKeyword = 100,
InstanceOfKeyword = 101,
NewKeyword = 102,
NullKeyword = 103,
ReturnKeyword = 104,
SuperKeyword = 105,
SwitchKeyword = 106,
ThisKeyword = 107,
ThrowKeyword = 108,
TrueKeyword = 109,
TryKeyword = 110,
TypeOfKeyword = 111,
VarKeyword = 112,
VoidKeyword = 113,
WhileKeyword = 114,
WithKeyword = 115,
ImplementsKeyword = 116,
InterfaceKeyword = 117,
LetKeyword = 118,
PackageKeyword = 119,
PrivateKeyword = 120,
ProtectedKeyword = 121,
PublicKeyword = 122,
StaticKeyword = 123,
YieldKeyword = 124,
AbstractKeyword = 125,
AsKeyword = 126,
AssertsKeyword = 127,
AnyKeyword = 128,
AsyncKeyword = 129,
AwaitKeyword = 130,
BooleanKeyword = 131,
ConstructorKeyword = 132,
DeclareKeyword = 133,
GetKeyword = 134,
InferKeyword = 135,
IntrinsicKeyword = 136,
IsKeyword = 137,
KeyOfKeyword = 138,
ModuleKeyword = 139,
NamespaceKeyword = 140,
NeverKeyword = 141,
ReadonlyKeyword = 142,
RequireKeyword = 143,
NumberKeyword = 144,
ObjectKeyword = 145,
SetKeyword = 146,
StringKeyword = 147,
SymbolKeyword = 148,
TypeKeyword = 149,
UndefinedKeyword = 150,
UniqueKeyword = 151,
UnknownKeyword = 152,
FromKeyword = 153,
GlobalKeyword = 154,
BigIntKeyword = 155,
OverrideKeyword = 156,
OfKeyword = 157,
QualifiedName = 158,
ComputedPropertyName = 159,
TypeParameter = 160,
Parameter = 161,
Decorator = 162,
PropertySignature = 163,
PropertyDeclaration = 164,
MethodSignature = 165,
MethodDeclaration = 166,
Constructor = 167,
GetAccessor = 168,
SetAccessor = 169,
CallSignature = 170,
ConstructSignature = 171,
IndexSignature = 172,
TypePredicate = 173,
TypeReference = 174,
FunctionType = 175,
ConstructorType = 176,
TypeQuery = 177,
TypeLiteral = 178,
ArrayType = 179,
TupleType = 180,
OptionalType = 181,
RestType = 182,
UnionType = 183,
IntersectionType = 184,
ConditionalType = 185,
InferType = 186,
ParenthesizedType = 187,
ThisType = 188,
TypeOperator = 189,
IndexedAccessType = 190,
MappedType = 191,
LiteralType = 192,
NamedTupleMember = 193,
TemplateLiteralType = 194,
TemplateLiteralTypeSpan = 195,
ImportType = 196,
ObjectBindingPattern = 197,
ArrayBindingPattern = 198,
BindingElement = 199,
ArrayLiteralExpression = 200,
ObjectLiteralExpression = 201,
PropertyAccessExpression = 202,
ElementAccessExpression = 203,
CallExpression = 204,
NewExpression = 205,
TaggedTemplateExpression = 206,
TypeAssertionExpression = 207,
ParenthesizedExpression = 208,
FunctionExpression = 209,
ArrowFunction = 210,
DeleteExpression = 211,
TypeOfExpression = 212,
VoidExpression = 213,
AwaitExpression = 214,
PrefixUnaryExpression = 215,
PostfixUnaryExpression = 216,
BinaryExpression = 217,
ConditionalExpression = 218,
TemplateExpression = 219,
YieldExpression = 220,
SpreadElement = 221,
ClassExpression = 222,
OmittedExpression = 223,
ExpressionWithTypeArguments = 224,
AsExpression = 225,
NonNullExpression = 226,
MetaProperty = 227,
SyntheticExpression = 228,
TemplateSpan = 229,
SemicolonClassElement = 230,
Block = 231,
EmptyStatement = 232,
VariableStatement = 233,
ExpressionStatement = 234,
IfStatement = 235,
DoStatement = 236,
WhileStatement = 237,
ForStatement = 238,
ForInStatement = 239,
ForOfStatement = 240,
ContinueStatement = 241,
BreakStatement = 242,
ReturnStatement = 243,
WithStatement = 244,
SwitchStatement = 245,
LabeledStatement = 246,
ThrowStatement = 247,
TryStatement = 248,
DebuggerStatement = 249,
VariableDeclaration = 250,
VariableDeclarationList = 251,
FunctionDeclaration = 252,
ClassDeclaration = 253,
InterfaceDeclaration = 254,
TypeAliasDeclaration = 255,
EnumDeclaration = 256,
ModuleDeclaration = 257,
ModuleBlock = 258,
CaseBlock = 259,
NamespaceExportDeclaration = 260,
ImportEqualsDeclaration = 261,
ImportDeclaration = 262,
ImportClause = 263,
NamespaceImport = 264,
NamedImports = 265,
ImportSpecifier = 266,
ExportAssignment = 267,
ExportDeclaration = 268,
NamedExports = 269,
NamespaceExport = 270,
ExportSpecifier = 271,
MissingDeclaration = 272,
ExternalModuleReference = 273,
JsxElement = 274,
JsxSelfClosingElement = 275,
JsxOpeningElement = 276,
JsxClosingElement = 277,
JsxFragment = 278,
JsxOpeningFragment = 279,
JsxClosingFragment = 280,
JsxAttribute = 281,
JsxAttributes = 282,
JsxSpreadAttribute = 283,
JsxExpression = 284,
CaseClause = 285,
DefaultClause = 286,
HeritageClause = 287,
CatchClause = 288,
PropertyAssignment = 289,
ShorthandPropertyAssignment = 290,
SpreadAssignment = 291,
EnumMember = 292,
UnparsedPrologue = 293,
UnparsedPrepend = 294,
UnparsedText = 295,
UnparsedInternalText = 296,
UnparsedSyntheticReference = 297,
SourceFile = 298,
Bundle = 299,
UnparsedSource = 300,
InputFiles = 301,
JSDocTypeExpression = 302,
JSDocNameReference = 303,
JSDocAllType = 304,
JSDocUnknownType = 305,
JSDocNullableType = 306,
JSDocNonNullableType = 307,
JSDocOptionalType = 308,
JSDocFunctionType = 309,
JSDocVariadicType = 310,
JSDocNamepathType = 311,
JSDocComment = 312,
JSDocText = 313,
JSDocTypeLiteral = 314,
JSDocSignature = 315,
JSDocLink = 316,
JSDocTag = 317,
JSDocAugmentsTag = 318,
JSDocImplementsTag = 319,
JSDocAuthorTag = 320,
JSDocDeprecatedTag = 321,
JSDocClassTag = 322,
JSDocPublicTag = 323,
JSDocPrivateTag = 324,
JSDocProtectedTag = 325,
JSDocReadonlyTag = 326,
JSDocOverrideTag = 327,
JSDocCallbackTag = 328,
JSDocEnumTag = 329,
JSDocParameterTag = 330,
JSDocReturnTag = 331,
JSDocThisTag = 332,
JSDocTypeTag = 333,
JSDocTemplateTag = 334,
JSDocTypedefTag = 335,
JSDocSeeTag = 336,
JSDocPropertyTag = 337,
SyntaxList = 338,
NotEmittedStatement = 339,
PartiallyEmittedExpression = 340,
CommaListExpression = 341,
MergeDeclarationMarker = 342,
EndOfDeclarationMarker = 343,
SyntheticReferenceExpression = 344,
Count = 345,
FirstAssignment = 62,
LastAssignment = 77,
FirstCompoundAssignment = 63,
LastCompoundAssignment = 77,
FirstReservedWord = 80,
LastReservedWord = 115,
FirstKeyword = 80,
LastKeyword = 157,
FirstFutureReservedWord = 116,
LastFutureReservedWord = 124,
FirstTypeNode = 173,
LastTypeNode = 196,
/** Only the JSDoc scanner produces HashToken. The normal scanner produces PrivateIdentifier. */
HashToken = 62,
EqualsToken = 63,
PlusEqualsToken = 64,
MinusEqualsToken = 65,
AsteriskEqualsToken = 66,
AsteriskAsteriskEqualsToken = 67,
SlashEqualsToken = 68,
PercentEqualsToken = 69,
LessThanLessThanEqualsToken = 70,
GreaterThanGreaterThanEqualsToken = 71,
GreaterThanGreaterThanGreaterThanEqualsToken = 72,
AmpersandEqualsToken = 73,
BarEqualsToken = 74,
BarBarEqualsToken = 75,
AmpersandAmpersandEqualsToken = 76,
QuestionQuestionEqualsToken = 77,
CaretEqualsToken = 78,
Identifier = 79,
PrivateIdentifier = 80,
BreakKeyword = 81,
CaseKeyword = 82,
CatchKeyword = 83,
ClassKeyword = 84,
ConstKeyword = 85,
ContinueKeyword = 86,
DebuggerKeyword = 87,
DefaultKeyword = 88,
DeleteKeyword = 89,
DoKeyword = 90,
ElseKeyword = 91,
EnumKeyword = 92,
ExportKeyword = 93,
ExtendsKeyword = 94,
FalseKeyword = 95,
FinallyKeyword = 96,
ForKeyword = 97,
FunctionKeyword = 98,
IfKeyword = 99,
ImportKeyword = 100,
InKeyword = 101,
InstanceOfKeyword = 102,
NewKeyword = 103,
NullKeyword = 104,
ReturnKeyword = 105,
SuperKeyword = 106,
SwitchKeyword = 107,
ThisKeyword = 108,
ThrowKeyword = 109,
TrueKeyword = 110,
TryKeyword = 111,
TypeOfKeyword = 112,
VarKeyword = 113,
VoidKeyword = 114,
WhileKeyword = 115,
WithKeyword = 116,
ImplementsKeyword = 117,
InterfaceKeyword = 118,
LetKeyword = 119,
PackageKeyword = 120,
PrivateKeyword = 121,
ProtectedKeyword = 122,
PublicKeyword = 123,
StaticKeyword = 124,
YieldKeyword = 125,
AbstractKeyword = 126,
AsKeyword = 127,
AssertsKeyword = 128,
AnyKeyword = 129,
AsyncKeyword = 130,
AwaitKeyword = 131,
BooleanKeyword = 132,
ConstructorKeyword = 133,
DeclareKeyword = 134,
GetKeyword = 135,
InferKeyword = 136,
IntrinsicKeyword = 137,
IsKeyword = 138,
KeyOfKeyword = 139,
ModuleKeyword = 140,
NamespaceKeyword = 141,
NeverKeyword = 142,
ReadonlyKeyword = 143,
RequireKeyword = 144,
NumberKeyword = 145,
ObjectKeyword = 146,
SetKeyword = 147,
StringKeyword = 148,
SymbolKeyword = 149,
TypeKeyword = 150,
UndefinedKeyword = 151,
UniqueKeyword = 152,
UnknownKeyword = 153,
FromKeyword = 154,
GlobalKeyword = 155,
BigIntKeyword = 156,
OverrideKeyword = 157,
OfKeyword = 158,
QualifiedName = 159,
ComputedPropertyName = 160,
TypeParameter = 161,
Parameter = 162,
Decorator = 163,
PropertySignature = 164,
PropertyDeclaration = 165,
MethodSignature = 166,
MethodDeclaration = 167,
Constructor = 168,
GetAccessor = 169,
SetAccessor = 170,
CallSignature = 171,
ConstructSignature = 172,
IndexSignature = 173,
TypePredicate = 174,
TypeReference = 175,
FunctionType = 176,
ConstructorType = 177,
TypeQuery = 178,
TypeLiteral = 179,
ArrayType = 180,
TupleType = 181,
OptionalType = 182,
RestType = 183,
UnionType = 184,
IntersectionType = 185,
ConditionalType = 186,
InferType = 187,
ParenthesizedType = 188,
ThisType = 189,
TypeOperator = 190,
IndexedAccessType = 191,
MappedType = 192,
LiteralType = 193,
NamedTupleMember = 194,
TemplateLiteralType = 195,
TemplateLiteralTypeSpan = 196,
ImportType = 197,
ObjectBindingPattern = 198,
ArrayBindingPattern = 199,
BindingElement = 200,
ArrayLiteralExpression = 201,
ObjectLiteralExpression = 202,
PropertyAccessExpression = 203,
ElementAccessExpression = 204,
CallExpression = 205,
NewExpression = 206,
TaggedTemplateExpression = 207,
TypeAssertionExpression = 208,
ParenthesizedExpression = 209,
FunctionExpression = 210,
ArrowFunction = 211,
DeleteExpression = 212,
TypeOfExpression = 213,
VoidExpression = 214,
AwaitExpression = 215,
PrefixUnaryExpression = 216,
PostfixUnaryExpression = 217,
BinaryExpression = 218,
ConditionalExpression = 219,
TemplateExpression = 220,
YieldExpression = 221,
SpreadElement = 222,
ClassExpression = 223,
OmittedExpression = 224,
ExpressionWithTypeArguments = 225,
AsExpression = 226,
NonNullExpression = 227,
MetaProperty = 228,
SyntheticExpression = 229,
TemplateSpan = 230,
SemicolonClassElement = 231,
Block = 232,
EmptyStatement = 233,
VariableStatement = 234,
ExpressionStatement = 235,
IfStatement = 236,
DoStatement = 237,
WhileStatement = 238,
ForStatement = 239,
ForInStatement = 240,
ForOfStatement = 241,
ContinueStatement = 242,
BreakStatement = 243,
ReturnStatement = 244,
WithStatement = 245,
SwitchStatement = 246,
LabeledStatement = 247,
ThrowStatement = 248,
TryStatement = 249,
DebuggerStatement = 250,
VariableDeclaration = 251,
VariableDeclarationList = 252,
FunctionDeclaration = 253,
ClassDeclaration = 254,
InterfaceDeclaration = 255,
TypeAliasDeclaration = 256,
EnumDeclaration = 257,
ModuleDeclaration = 258,
ModuleBlock = 259,
CaseBlock = 260,
NamespaceExportDeclaration = 261,
ImportEqualsDeclaration = 262,
ImportDeclaration = 263,
ImportClause = 264,
NamespaceImport = 265,
NamedImports = 266,
ImportSpecifier = 267,
ExportAssignment = 268,
ExportDeclaration = 269,
NamedExports = 270,
NamespaceExport = 271,
ExportSpecifier = 272,
MissingDeclaration = 273,
ExternalModuleReference = 274,
JsxElement = 275,
JsxSelfClosingElement = 276,
JsxOpeningElement = 277,
JsxClosingElement = 278,
JsxFragment = 279,
JsxOpeningFragment = 280,
JsxClosingFragment = 281,
JsxAttribute = 282,
JsxAttributes = 283,
JsxSpreadAttribute = 284,
JsxExpression = 285,
CaseClause = 286,
DefaultClause = 287,
HeritageClause = 288,
CatchClause = 289,
PropertyAssignment = 290,
ShorthandPropertyAssignment = 291,
SpreadAssignment = 292,
EnumMember = 293,
UnparsedPrologue = 294,
UnparsedPrepend = 295,
UnparsedText = 296,
UnparsedInternalText = 297,
UnparsedSyntheticReference = 298,
SourceFile = 299,
Bundle = 300,
UnparsedSource = 301,
InputFiles = 302,
JSDocTypeExpression = 303,
JSDocNameReference = 304,
JSDocMemberName = 305,
JSDocAllType = 306,
JSDocUnknownType = 307,
JSDocNullableType = 308,
JSDocNonNullableType = 309,
JSDocOptionalType = 310,
JSDocFunctionType = 311,
JSDocVariadicType = 312,
JSDocNamepathType = 313,
JSDocComment = 314,
JSDocText = 315,
JSDocTypeLiteral = 316,
JSDocSignature = 317,
JSDocLink = 318,
JSDocTag = 319,
JSDocAugmentsTag = 320,
JSDocImplementsTag = 321,
JSDocAuthorTag = 322,
JSDocDeprecatedTag = 323,
JSDocClassTag = 324,
JSDocPublicTag = 325,
JSDocPrivateTag = 326,
JSDocProtectedTag = 327,
JSDocReadonlyTag = 328,
JSDocOverrideTag = 329,
JSDocCallbackTag = 330,
JSDocEnumTag = 331,
JSDocParameterTag = 332,
JSDocReturnTag = 333,
JSDocThisTag = 334,
JSDocTypeTag = 335,
JSDocTemplateTag = 336,
JSDocTypedefTag = 337,
JSDocSeeTag = 338,
JSDocPropertyTag = 339,
SyntaxList = 340,
NotEmittedStatement = 341,
PartiallyEmittedExpression = 342,
CommaListExpression = 343,
MergeDeclarationMarker = 344,
EndOfDeclarationMarker = 345,
SyntheticReferenceExpression = 346,
Count = 347,
FirstAssignment = 63,
LastAssignment = 78,
FirstCompoundAssignment = 64,
LastCompoundAssignment = 78,
FirstReservedWord = 81,
LastReservedWord = 116,
FirstKeyword = 81,
LastKeyword = 158,
FirstFutureReservedWord = 117,
LastFutureReservedWord = 125,
FirstTypeNode = 174,
LastTypeNode = 197,
FirstPunctuation = 18,
LastPunctuation = 77,
LastPunctuation = 78,
FirstToken = 0,
LastToken = 157,
LastToken = 158,
FirstTriviaToken = 2,
LastTriviaToken = 7,
FirstLiteralToken = 8,
@@ -473,25 +476,25 @@ declare namespace ts {
FirstTemplateToken = 14,
LastTemplateToken = 17,
FirstBinaryOperator = 29,
LastBinaryOperator = 77,
FirstStatement = 233,
LastStatement = 249,
FirstNode = 158,
FirstJSDocNode = 302,
LastJSDocNode = 337,
FirstJSDocTagNode = 317,
LastJSDocTagNode = 337,
LastBinaryOperator = 78,
FirstStatement = 234,
LastStatement = 250,
FirstNode = 159,
FirstJSDocNode = 303,
LastJSDocNode = 339,
FirstJSDocTagNode = 319,
LastJSDocTagNode = 339,
}
export type TriviaSyntaxKind = SyntaxKind.SingleLineCommentTrivia | SyntaxKind.MultiLineCommentTrivia | SyntaxKind.NewLineTrivia | SyntaxKind.WhitespaceTrivia | SyntaxKind.ShebangTrivia | SyntaxKind.ConflictMarkerTrivia;
export type LiteralSyntaxKind = SyntaxKind.NumericLiteral | SyntaxKind.BigIntLiteral | SyntaxKind.StringLiteral | SyntaxKind.JsxText | SyntaxKind.JsxTextAllWhiteSpaces | SyntaxKind.RegularExpressionLiteral | SyntaxKind.NoSubstitutionTemplateLiteral;
export type PseudoLiteralSyntaxKind = SyntaxKind.TemplateHead | SyntaxKind.TemplateMiddle | SyntaxKind.TemplateTail;
export type PunctuationSyntaxKind = SyntaxKind.OpenBraceToken | SyntaxKind.CloseBraceToken | SyntaxKind.OpenParenToken | SyntaxKind.CloseParenToken | SyntaxKind.OpenBracketToken | SyntaxKind.CloseBracketToken | SyntaxKind.DotToken | SyntaxKind.DotDotDotToken | SyntaxKind.SemicolonToken | SyntaxKind.CommaToken | SyntaxKind.QuestionDotToken | SyntaxKind.LessThanToken | SyntaxKind.LessThanSlashToken | SyntaxKind.GreaterThanToken | SyntaxKind.LessThanEqualsToken | SyntaxKind.GreaterThanEqualsToken | SyntaxKind.EqualsEqualsToken | SyntaxKind.ExclamationEqualsToken | SyntaxKind.EqualsEqualsEqualsToken | SyntaxKind.ExclamationEqualsEqualsToken | SyntaxKind.EqualsGreaterThanToken | SyntaxKind.PlusToken | SyntaxKind.MinusToken | SyntaxKind.AsteriskToken | SyntaxKind.AsteriskAsteriskToken | SyntaxKind.SlashToken | SyntaxKind.PercentToken | SyntaxKind.PlusPlusToken | SyntaxKind.MinusMinusToken | SyntaxKind.LessThanLessThanToken | SyntaxKind.GreaterThanGreaterThanToken | SyntaxKind.GreaterThanGreaterThanGreaterThanToken | SyntaxKind.AmpersandToken | SyntaxKind.BarToken | SyntaxKind.CaretToken | SyntaxKind.ExclamationToken | SyntaxKind.TildeToken | SyntaxKind.AmpersandAmpersandToken | SyntaxKind.BarBarToken | SyntaxKind.QuestionQuestionToken | SyntaxKind.QuestionToken | SyntaxKind.ColonToken | SyntaxKind.AtToken | SyntaxKind.BacktickToken | SyntaxKind.EqualsToken | SyntaxKind.PlusEqualsToken | SyntaxKind.MinusEqualsToken | SyntaxKind.AsteriskEqualsToken | SyntaxKind.AsteriskAsteriskEqualsToken | SyntaxKind.SlashEqualsToken | SyntaxKind.PercentEqualsToken | SyntaxKind.LessThanLessThanEqualsToken | SyntaxKind.GreaterThanGreaterThanEqualsToken | SyntaxKind.GreaterThanGreaterThanGreaterThanEqualsToken | SyntaxKind.AmpersandEqualsToken | SyntaxKind.BarEqualsToken | SyntaxKind.CaretEqualsToken;
export type PunctuationSyntaxKind = SyntaxKind.OpenBraceToken | SyntaxKind.CloseBraceToken | SyntaxKind.OpenParenToken | SyntaxKind.CloseParenToken | SyntaxKind.OpenBracketToken | SyntaxKind.CloseBracketToken | SyntaxKind.DotToken | SyntaxKind.DotDotDotToken | SyntaxKind.SemicolonToken | SyntaxKind.CommaToken | SyntaxKind.QuestionDotToken | SyntaxKind.LessThanToken | SyntaxKind.LessThanSlashToken | SyntaxKind.GreaterThanToken | SyntaxKind.LessThanEqualsToken | SyntaxKind.GreaterThanEqualsToken | SyntaxKind.EqualsEqualsToken | SyntaxKind.ExclamationEqualsToken | SyntaxKind.EqualsEqualsEqualsToken | SyntaxKind.ExclamationEqualsEqualsToken | SyntaxKind.EqualsGreaterThanToken | SyntaxKind.PlusToken | SyntaxKind.MinusToken | SyntaxKind.AsteriskToken | SyntaxKind.AsteriskAsteriskToken | SyntaxKind.SlashToken | SyntaxKind.PercentToken | SyntaxKind.PlusPlusToken | SyntaxKind.MinusMinusToken | SyntaxKind.LessThanLessThanToken | SyntaxKind.GreaterThanGreaterThanToken | SyntaxKind.GreaterThanGreaterThanGreaterThanToken | SyntaxKind.AmpersandToken | SyntaxKind.BarToken | SyntaxKind.CaretToken | SyntaxKind.ExclamationToken | SyntaxKind.TildeToken | SyntaxKind.AmpersandAmpersandToken | SyntaxKind.BarBarToken | SyntaxKind.QuestionQuestionToken | SyntaxKind.QuestionToken | SyntaxKind.ColonToken | SyntaxKind.AtToken | SyntaxKind.BacktickToken | SyntaxKind.HashToken | SyntaxKind.EqualsToken | SyntaxKind.PlusEqualsToken | SyntaxKind.MinusEqualsToken | SyntaxKind.AsteriskEqualsToken | SyntaxKind.AsteriskAsteriskEqualsToken | SyntaxKind.SlashEqualsToken | SyntaxKind.PercentEqualsToken | SyntaxKind.LessThanLessThanEqualsToken | SyntaxKind.GreaterThanGreaterThanEqualsToken | SyntaxKind.GreaterThanGreaterThanGreaterThanEqualsToken | SyntaxKind.AmpersandEqualsToken | SyntaxKind.BarEqualsToken | SyntaxKind.CaretEqualsToken;
export type KeywordSyntaxKind = SyntaxKind.AbstractKeyword | SyntaxKind.AnyKeyword | SyntaxKind.AsKeyword | SyntaxKind.AssertsKeyword | SyntaxKind.AsyncKeyword | SyntaxKind.AwaitKeyword | SyntaxKind.BigIntKeyword | SyntaxKind.BooleanKeyword | SyntaxKind.BreakKeyword | SyntaxKind.CaseKeyword | SyntaxKind.CatchKeyword | SyntaxKind.ClassKeyword | SyntaxKind.ConstKeyword | SyntaxKind.ConstructorKeyword | SyntaxKind.ContinueKeyword | SyntaxKind.DebuggerKeyword | SyntaxKind.DeclareKeyword | SyntaxKind.DefaultKeyword | SyntaxKind.DeleteKeyword | SyntaxKind.DoKeyword | SyntaxKind.ElseKeyword | SyntaxKind.EnumKeyword | SyntaxKind.ExportKeyword | SyntaxKind.ExtendsKeyword | SyntaxKind.FalseKeyword | SyntaxKind.FinallyKeyword | SyntaxKind.ForKeyword | SyntaxKind.FromKeyword | SyntaxKind.FunctionKeyword | SyntaxKind.GetKeyword | SyntaxKind.GlobalKeyword | SyntaxKind.IfKeyword | SyntaxKind.ImplementsKeyword | SyntaxKind.ImportKeyword | SyntaxKind.InferKeyword | SyntaxKind.InKeyword | SyntaxKind.InstanceOfKeyword | SyntaxKind.InterfaceKeyword | SyntaxKind.IntrinsicKeyword | SyntaxKind.IsKeyword | SyntaxKind.KeyOfKeyword | SyntaxKind.LetKeyword | SyntaxKind.ModuleKeyword | SyntaxKind.NamespaceKeyword | SyntaxKind.NeverKeyword | SyntaxKind.NewKeyword | SyntaxKind.NullKeyword | SyntaxKind.NumberKeyword | SyntaxKind.ObjectKeyword | SyntaxKind.OfKeyword | SyntaxKind.PackageKeyword | SyntaxKind.PrivateKeyword | SyntaxKind.ProtectedKeyword | SyntaxKind.PublicKeyword | SyntaxKind.ReadonlyKeyword | SyntaxKind.OverrideKeyword | SyntaxKind.RequireKeyword | SyntaxKind.ReturnKeyword | SyntaxKind.SetKeyword | SyntaxKind.StaticKeyword | SyntaxKind.StringKeyword | SyntaxKind.SuperKeyword | SyntaxKind.SwitchKeyword | SyntaxKind.SymbolKeyword | SyntaxKind.ThisKeyword | SyntaxKind.ThrowKeyword | SyntaxKind.TrueKeyword | SyntaxKind.TryKeyword | SyntaxKind.TypeKeyword | SyntaxKind.TypeOfKeyword | SyntaxKind.UndefinedKeyword | SyntaxKind.UniqueKeyword | SyntaxKind.UnknownKeyword | SyntaxKind.VarKeyword | SyntaxKind.VoidKeyword | SyntaxKind.WhileKeyword | SyntaxKind.WithKeyword | SyntaxKind.YieldKeyword;
export type ModifierSyntaxKind = SyntaxKind.AbstractKeyword | SyntaxKind.AsyncKeyword | SyntaxKind.ConstKeyword | SyntaxKind.DeclareKeyword | SyntaxKind.DefaultKeyword | SyntaxKind.ExportKeyword | SyntaxKind.PrivateKeyword | SyntaxKind.ProtectedKeyword | SyntaxKind.PublicKeyword | SyntaxKind.ReadonlyKeyword | SyntaxKind.OverrideKeyword | SyntaxKind.StaticKeyword;
export type KeywordTypeSyntaxKind = SyntaxKind.AnyKeyword | SyntaxKind.BigIntKeyword | SyntaxKind.BooleanKeyword | SyntaxKind.IntrinsicKeyword | SyntaxKind.NeverKeyword | SyntaxKind.NumberKeyword | SyntaxKind.ObjectKeyword | SyntaxKind.StringKeyword | SyntaxKind.SymbolKeyword | SyntaxKind.UndefinedKeyword | SyntaxKind.UnknownKeyword | SyntaxKind.VoidKeyword;
export type TokenSyntaxKind = SyntaxKind.Unknown | SyntaxKind.EndOfFileToken | TriviaSyntaxKind | LiteralSyntaxKind | PseudoLiteralSyntaxKind | PunctuationSyntaxKind | SyntaxKind.Identifier | KeywordSyntaxKind;
export type JsxTokenSyntaxKind = SyntaxKind.LessThanSlashToken | SyntaxKind.EndOfFileToken | SyntaxKind.ConflictMarkerTrivia | SyntaxKind.JsxText | SyntaxKind.JsxTextAllWhiteSpaces | SyntaxKind.OpenBraceToken | SyntaxKind.LessThanToken;
export type JSDocSyntaxKind = SyntaxKind.EndOfFileToken | SyntaxKind.WhitespaceTrivia | SyntaxKind.AtToken | SyntaxKind.NewLineTrivia | SyntaxKind.AsteriskToken | SyntaxKind.OpenBraceToken | SyntaxKind.CloseBraceToken | SyntaxKind.LessThanToken | SyntaxKind.GreaterThanToken | SyntaxKind.OpenBracketToken | SyntaxKind.CloseBracketToken | SyntaxKind.EqualsToken | SyntaxKind.CommaToken | SyntaxKind.DotToken | SyntaxKind.Identifier | SyntaxKind.BacktickToken | SyntaxKind.Unknown | KeywordSyntaxKind;
export type JSDocSyntaxKind = SyntaxKind.EndOfFileToken | SyntaxKind.WhitespaceTrivia | SyntaxKind.AtToken | SyntaxKind.NewLineTrivia | SyntaxKind.AsteriskToken | SyntaxKind.OpenBraceToken | SyntaxKind.CloseBraceToken | SyntaxKind.LessThanToken | SyntaxKind.GreaterThanToken | SyntaxKind.OpenBracketToken | SyntaxKind.CloseBracketToken | SyntaxKind.EqualsToken | SyntaxKind.CommaToken | SyntaxKind.DotToken | SyntaxKind.Identifier | SyntaxKind.BacktickToken | SyntaxKind.HashToken | SyntaxKind.Unknown | KeywordSyntaxKind;
export enum NodeFlags {
None = 0,
Let = 1,
@@ -1710,7 +1713,13 @@ declare namespace ts {
}
export interface JSDocNameReference extends Node {
readonly kind: SyntaxKind.JSDocNameReference;
readonly name: EntityName;
readonly name: EntityName | JSDocMemberName;
}
/** Class#method reference in JSDoc */
export interface JSDocMemberName extends Node {
readonly kind: SyntaxKind.JSDocMemberName;
readonly left: EntityName | JSDocMemberName;
readonly right: Identifier;
}
export interface JSDocType extends TypeNode {
_jsDocTypeBrand: any;
@@ -1758,7 +1767,7 @@ declare namespace ts {
}
export interface JSDocLink extends Node {
readonly kind: SyntaxKind.JSDocLink;
readonly name?: EntityName;
readonly name?: EntityName | JSDocMemberName;
text: string;
}
export interface JSDocText extends Node {
@@ -3496,10 +3505,12 @@ declare namespace ts {
updateJSDocNamepathType(node: JSDocNamepathType, type: TypeNode): JSDocNamepathType;
createJSDocTypeExpression(type: TypeNode): JSDocTypeExpression;
updateJSDocTypeExpression(node: JSDocTypeExpression, type: TypeNode): JSDocTypeExpression;
createJSDocNameReference(name: EntityName): JSDocNameReference;
updateJSDocNameReference(node: JSDocNameReference, name: EntityName): JSDocNameReference;
createJSDocLink(name: EntityName | undefined, text: string): JSDocLink;
updateJSDocLink(node: JSDocLink, name: EntityName | undefined, text: string): JSDocLink;
createJSDocNameReference(name: EntityName | JSDocMemberName): JSDocNameReference;
updateJSDocNameReference(node: JSDocNameReference, name: EntityName | JSDocMemberName): JSDocNameReference;
createJSDocMemberName(left: EntityName | JSDocMemberName, right: Identifier): JSDocMemberName;
updateJSDocMemberName(node: JSDocMemberName, left: EntityName | JSDocMemberName, right: Identifier): JSDocMemberName;
createJSDocLink(name: EntityName | JSDocMemberName | undefined, text: string): JSDocLink;
updateJSDocLink(node: JSDocLink, name: EntityName | JSDocMemberName | undefined, text: string): JSDocLink;
createJSDocTypeLiteral(jsDocPropertyTags?: readonly JSDocPropertyLikeTag[], isArrayType?: boolean): JSDocTypeLiteral;
updateJSDocTypeLiteral(node: JSDocTypeLiteral, jsDocPropertyTags: readonly JSDocPropertyLikeTag[] | undefined, isArrayType: boolean | undefined): JSDocTypeLiteral;
createJSDocSignature(typeParameters: readonly JSDocTemplateTag[] | undefined, parameters: readonly JSDocParameterTag[], type?: JSDocReturnTag): JSDocSignature;
@@ -4018,6 +4029,7 @@ declare namespace ts {
reScanJsxAttributeValue(): SyntaxKind;
reScanJsxToken(allowMultilineJsxText?: boolean): JsxTokenSyntaxKind;
reScanLessThanToken(): SyntaxKind;
reScanHashToken(): SyntaxKind;
reScanQuestionToken(): SyntaxKind;
reScanInvalidIdentifier(): SyntaxKind;
scanJsxToken(): JsxTokenSyntaxKind;
@@ -4556,6 +4568,7 @@ declare namespace ts {
function isUnparsedSource(node: Node): node is UnparsedSource;
function isJSDocTypeExpression(node: Node): node is JSDocTypeExpression;
function isJSDocNameReference(node: Node): node is JSDocNameReference;
function isJSDocMemberName(node: Node): node is JSDocMemberName;
function isJSDocLink(node: Node): node is JSDocLink;
function isJSDocAllType(node: Node): node is JSDocAllType;
function isJSDocUnknownType(node: Node): node is JSDocUnknownType;
+327 -314
View File
@@ -166,306 +166,309 @@ declare namespace ts {
QuestionQuestionToken = 60,
/** Only the JSDoc scanner produces BacktickToken. The normal scanner produces NoSubstitutionTemplateLiteral and related kinds. */
BacktickToken = 61,
EqualsToken = 62,
PlusEqualsToken = 63,
MinusEqualsToken = 64,
AsteriskEqualsToken = 65,
AsteriskAsteriskEqualsToken = 66,
SlashEqualsToken = 67,
PercentEqualsToken = 68,
LessThanLessThanEqualsToken = 69,
GreaterThanGreaterThanEqualsToken = 70,
GreaterThanGreaterThanGreaterThanEqualsToken = 71,
AmpersandEqualsToken = 72,
BarEqualsToken = 73,
BarBarEqualsToken = 74,
AmpersandAmpersandEqualsToken = 75,
QuestionQuestionEqualsToken = 76,
CaretEqualsToken = 77,
Identifier = 78,
PrivateIdentifier = 79,
BreakKeyword = 80,
CaseKeyword = 81,
CatchKeyword = 82,
ClassKeyword = 83,
ConstKeyword = 84,
ContinueKeyword = 85,
DebuggerKeyword = 86,
DefaultKeyword = 87,
DeleteKeyword = 88,
DoKeyword = 89,
ElseKeyword = 90,
EnumKeyword = 91,
ExportKeyword = 92,
ExtendsKeyword = 93,
FalseKeyword = 94,
FinallyKeyword = 95,
ForKeyword = 96,
FunctionKeyword = 97,
IfKeyword = 98,
ImportKeyword = 99,
InKeyword = 100,
InstanceOfKeyword = 101,
NewKeyword = 102,
NullKeyword = 103,
ReturnKeyword = 104,
SuperKeyword = 105,
SwitchKeyword = 106,
ThisKeyword = 107,
ThrowKeyword = 108,
TrueKeyword = 109,
TryKeyword = 110,
TypeOfKeyword = 111,
VarKeyword = 112,
VoidKeyword = 113,
WhileKeyword = 114,
WithKeyword = 115,
ImplementsKeyword = 116,
InterfaceKeyword = 117,
LetKeyword = 118,
PackageKeyword = 119,
PrivateKeyword = 120,
ProtectedKeyword = 121,
PublicKeyword = 122,
StaticKeyword = 123,
YieldKeyword = 124,
AbstractKeyword = 125,
AsKeyword = 126,
AssertsKeyword = 127,
AnyKeyword = 128,
AsyncKeyword = 129,
AwaitKeyword = 130,
BooleanKeyword = 131,
ConstructorKeyword = 132,
DeclareKeyword = 133,
GetKeyword = 134,
InferKeyword = 135,
IntrinsicKeyword = 136,
IsKeyword = 137,
KeyOfKeyword = 138,
ModuleKeyword = 139,
NamespaceKeyword = 140,
NeverKeyword = 141,
ReadonlyKeyword = 142,
RequireKeyword = 143,
NumberKeyword = 144,
ObjectKeyword = 145,
SetKeyword = 146,
StringKeyword = 147,
SymbolKeyword = 148,
TypeKeyword = 149,
UndefinedKeyword = 150,
UniqueKeyword = 151,
UnknownKeyword = 152,
FromKeyword = 153,
GlobalKeyword = 154,
BigIntKeyword = 155,
OverrideKeyword = 156,
OfKeyword = 157,
QualifiedName = 158,
ComputedPropertyName = 159,
TypeParameter = 160,
Parameter = 161,
Decorator = 162,
PropertySignature = 163,
PropertyDeclaration = 164,
MethodSignature = 165,
MethodDeclaration = 166,
Constructor = 167,
GetAccessor = 168,
SetAccessor = 169,
CallSignature = 170,
ConstructSignature = 171,
IndexSignature = 172,
TypePredicate = 173,
TypeReference = 174,
FunctionType = 175,
ConstructorType = 176,
TypeQuery = 177,
TypeLiteral = 178,
ArrayType = 179,
TupleType = 180,
OptionalType = 181,
RestType = 182,
UnionType = 183,
IntersectionType = 184,
ConditionalType = 185,
InferType = 186,
ParenthesizedType = 187,
ThisType = 188,
TypeOperator = 189,
IndexedAccessType = 190,
MappedType = 191,
LiteralType = 192,
NamedTupleMember = 193,
TemplateLiteralType = 194,
TemplateLiteralTypeSpan = 195,
ImportType = 196,
ObjectBindingPattern = 197,
ArrayBindingPattern = 198,
BindingElement = 199,
ArrayLiteralExpression = 200,
ObjectLiteralExpression = 201,
PropertyAccessExpression = 202,
ElementAccessExpression = 203,
CallExpression = 204,
NewExpression = 205,
TaggedTemplateExpression = 206,
TypeAssertionExpression = 207,
ParenthesizedExpression = 208,
FunctionExpression = 209,
ArrowFunction = 210,
DeleteExpression = 211,
TypeOfExpression = 212,
VoidExpression = 213,
AwaitExpression = 214,
PrefixUnaryExpression = 215,
PostfixUnaryExpression = 216,
BinaryExpression = 217,
ConditionalExpression = 218,
TemplateExpression = 219,
YieldExpression = 220,
SpreadElement = 221,
ClassExpression = 222,
OmittedExpression = 223,
ExpressionWithTypeArguments = 224,
AsExpression = 225,
NonNullExpression = 226,
MetaProperty = 227,
SyntheticExpression = 228,
TemplateSpan = 229,
SemicolonClassElement = 230,
Block = 231,
EmptyStatement = 232,
VariableStatement = 233,
ExpressionStatement = 234,
IfStatement = 235,
DoStatement = 236,
WhileStatement = 237,
ForStatement = 238,
ForInStatement = 239,
ForOfStatement = 240,
ContinueStatement = 241,
BreakStatement = 242,
ReturnStatement = 243,
WithStatement = 244,
SwitchStatement = 245,
LabeledStatement = 246,
ThrowStatement = 247,
TryStatement = 248,
DebuggerStatement = 249,
VariableDeclaration = 250,
VariableDeclarationList = 251,
FunctionDeclaration = 252,
ClassDeclaration = 253,
InterfaceDeclaration = 254,
TypeAliasDeclaration = 255,
EnumDeclaration = 256,
ModuleDeclaration = 257,
ModuleBlock = 258,
CaseBlock = 259,
NamespaceExportDeclaration = 260,
ImportEqualsDeclaration = 261,
ImportDeclaration = 262,
ImportClause = 263,
NamespaceImport = 264,
NamedImports = 265,
ImportSpecifier = 266,
ExportAssignment = 267,
ExportDeclaration = 268,
NamedExports = 269,
NamespaceExport = 270,
ExportSpecifier = 271,
MissingDeclaration = 272,
ExternalModuleReference = 273,
JsxElement = 274,
JsxSelfClosingElement = 275,
JsxOpeningElement = 276,
JsxClosingElement = 277,
JsxFragment = 278,
JsxOpeningFragment = 279,
JsxClosingFragment = 280,
JsxAttribute = 281,
JsxAttributes = 282,
JsxSpreadAttribute = 283,
JsxExpression = 284,
CaseClause = 285,
DefaultClause = 286,
HeritageClause = 287,
CatchClause = 288,
PropertyAssignment = 289,
ShorthandPropertyAssignment = 290,
SpreadAssignment = 291,
EnumMember = 292,
UnparsedPrologue = 293,
UnparsedPrepend = 294,
UnparsedText = 295,
UnparsedInternalText = 296,
UnparsedSyntheticReference = 297,
SourceFile = 298,
Bundle = 299,
UnparsedSource = 300,
InputFiles = 301,
JSDocTypeExpression = 302,
JSDocNameReference = 303,
JSDocAllType = 304,
JSDocUnknownType = 305,
JSDocNullableType = 306,
JSDocNonNullableType = 307,
JSDocOptionalType = 308,
JSDocFunctionType = 309,
JSDocVariadicType = 310,
JSDocNamepathType = 311,
JSDocComment = 312,
JSDocText = 313,
JSDocTypeLiteral = 314,
JSDocSignature = 315,
JSDocLink = 316,
JSDocTag = 317,
JSDocAugmentsTag = 318,
JSDocImplementsTag = 319,
JSDocAuthorTag = 320,
JSDocDeprecatedTag = 321,
JSDocClassTag = 322,
JSDocPublicTag = 323,
JSDocPrivateTag = 324,
JSDocProtectedTag = 325,
JSDocReadonlyTag = 326,
JSDocOverrideTag = 327,
JSDocCallbackTag = 328,
JSDocEnumTag = 329,
JSDocParameterTag = 330,
JSDocReturnTag = 331,
JSDocThisTag = 332,
JSDocTypeTag = 333,
JSDocTemplateTag = 334,
JSDocTypedefTag = 335,
JSDocSeeTag = 336,
JSDocPropertyTag = 337,
SyntaxList = 338,
NotEmittedStatement = 339,
PartiallyEmittedExpression = 340,
CommaListExpression = 341,
MergeDeclarationMarker = 342,
EndOfDeclarationMarker = 343,
SyntheticReferenceExpression = 344,
Count = 345,
FirstAssignment = 62,
LastAssignment = 77,
FirstCompoundAssignment = 63,
LastCompoundAssignment = 77,
FirstReservedWord = 80,
LastReservedWord = 115,
FirstKeyword = 80,
LastKeyword = 157,
FirstFutureReservedWord = 116,
LastFutureReservedWord = 124,
FirstTypeNode = 173,
LastTypeNode = 196,
/** Only the JSDoc scanner produces HashToken. The normal scanner produces PrivateIdentifier. */
HashToken = 62,
EqualsToken = 63,
PlusEqualsToken = 64,
MinusEqualsToken = 65,
AsteriskEqualsToken = 66,
AsteriskAsteriskEqualsToken = 67,
SlashEqualsToken = 68,
PercentEqualsToken = 69,
LessThanLessThanEqualsToken = 70,
GreaterThanGreaterThanEqualsToken = 71,
GreaterThanGreaterThanGreaterThanEqualsToken = 72,
AmpersandEqualsToken = 73,
BarEqualsToken = 74,
BarBarEqualsToken = 75,
AmpersandAmpersandEqualsToken = 76,
QuestionQuestionEqualsToken = 77,
CaretEqualsToken = 78,
Identifier = 79,
PrivateIdentifier = 80,
BreakKeyword = 81,
CaseKeyword = 82,
CatchKeyword = 83,
ClassKeyword = 84,
ConstKeyword = 85,
ContinueKeyword = 86,
DebuggerKeyword = 87,
DefaultKeyword = 88,
DeleteKeyword = 89,
DoKeyword = 90,
ElseKeyword = 91,
EnumKeyword = 92,
ExportKeyword = 93,
ExtendsKeyword = 94,
FalseKeyword = 95,
FinallyKeyword = 96,
ForKeyword = 97,
FunctionKeyword = 98,
IfKeyword = 99,
ImportKeyword = 100,
InKeyword = 101,
InstanceOfKeyword = 102,
NewKeyword = 103,
NullKeyword = 104,
ReturnKeyword = 105,
SuperKeyword = 106,
SwitchKeyword = 107,
ThisKeyword = 108,
ThrowKeyword = 109,
TrueKeyword = 110,
TryKeyword = 111,
TypeOfKeyword = 112,
VarKeyword = 113,
VoidKeyword = 114,
WhileKeyword = 115,
WithKeyword = 116,
ImplementsKeyword = 117,
InterfaceKeyword = 118,
LetKeyword = 119,
PackageKeyword = 120,
PrivateKeyword = 121,
ProtectedKeyword = 122,
PublicKeyword = 123,
StaticKeyword = 124,
YieldKeyword = 125,
AbstractKeyword = 126,
AsKeyword = 127,
AssertsKeyword = 128,
AnyKeyword = 129,
AsyncKeyword = 130,
AwaitKeyword = 131,
BooleanKeyword = 132,
ConstructorKeyword = 133,
DeclareKeyword = 134,
GetKeyword = 135,
InferKeyword = 136,
IntrinsicKeyword = 137,
IsKeyword = 138,
KeyOfKeyword = 139,
ModuleKeyword = 140,
NamespaceKeyword = 141,
NeverKeyword = 142,
ReadonlyKeyword = 143,
RequireKeyword = 144,
NumberKeyword = 145,
ObjectKeyword = 146,
SetKeyword = 147,
StringKeyword = 148,
SymbolKeyword = 149,
TypeKeyword = 150,
UndefinedKeyword = 151,
UniqueKeyword = 152,
UnknownKeyword = 153,
FromKeyword = 154,
GlobalKeyword = 155,
BigIntKeyword = 156,
OverrideKeyword = 157,
OfKeyword = 158,
QualifiedName = 159,
ComputedPropertyName = 160,
TypeParameter = 161,
Parameter = 162,
Decorator = 163,
PropertySignature = 164,
PropertyDeclaration = 165,
MethodSignature = 166,
MethodDeclaration = 167,
Constructor = 168,
GetAccessor = 169,
SetAccessor = 170,
CallSignature = 171,
ConstructSignature = 172,
IndexSignature = 173,
TypePredicate = 174,
TypeReference = 175,
FunctionType = 176,
ConstructorType = 177,
TypeQuery = 178,
TypeLiteral = 179,
ArrayType = 180,
TupleType = 181,
OptionalType = 182,
RestType = 183,
UnionType = 184,
IntersectionType = 185,
ConditionalType = 186,
InferType = 187,
ParenthesizedType = 188,
ThisType = 189,
TypeOperator = 190,
IndexedAccessType = 191,
MappedType = 192,
LiteralType = 193,
NamedTupleMember = 194,
TemplateLiteralType = 195,
TemplateLiteralTypeSpan = 196,
ImportType = 197,
ObjectBindingPattern = 198,
ArrayBindingPattern = 199,
BindingElement = 200,
ArrayLiteralExpression = 201,
ObjectLiteralExpression = 202,
PropertyAccessExpression = 203,
ElementAccessExpression = 204,
CallExpression = 205,
NewExpression = 206,
TaggedTemplateExpression = 207,
TypeAssertionExpression = 208,
ParenthesizedExpression = 209,
FunctionExpression = 210,
ArrowFunction = 211,
DeleteExpression = 212,
TypeOfExpression = 213,
VoidExpression = 214,
AwaitExpression = 215,
PrefixUnaryExpression = 216,
PostfixUnaryExpression = 217,
BinaryExpression = 218,
ConditionalExpression = 219,
TemplateExpression = 220,
YieldExpression = 221,
SpreadElement = 222,
ClassExpression = 223,
OmittedExpression = 224,
ExpressionWithTypeArguments = 225,
AsExpression = 226,
NonNullExpression = 227,
MetaProperty = 228,
SyntheticExpression = 229,
TemplateSpan = 230,
SemicolonClassElement = 231,
Block = 232,
EmptyStatement = 233,
VariableStatement = 234,
ExpressionStatement = 235,
IfStatement = 236,
DoStatement = 237,
WhileStatement = 238,
ForStatement = 239,
ForInStatement = 240,
ForOfStatement = 241,
ContinueStatement = 242,
BreakStatement = 243,
ReturnStatement = 244,
WithStatement = 245,
SwitchStatement = 246,
LabeledStatement = 247,
ThrowStatement = 248,
TryStatement = 249,
DebuggerStatement = 250,
VariableDeclaration = 251,
VariableDeclarationList = 252,
FunctionDeclaration = 253,
ClassDeclaration = 254,
InterfaceDeclaration = 255,
TypeAliasDeclaration = 256,
EnumDeclaration = 257,
ModuleDeclaration = 258,
ModuleBlock = 259,
CaseBlock = 260,
NamespaceExportDeclaration = 261,
ImportEqualsDeclaration = 262,
ImportDeclaration = 263,
ImportClause = 264,
NamespaceImport = 265,
NamedImports = 266,
ImportSpecifier = 267,
ExportAssignment = 268,
ExportDeclaration = 269,
NamedExports = 270,
NamespaceExport = 271,
ExportSpecifier = 272,
MissingDeclaration = 273,
ExternalModuleReference = 274,
JsxElement = 275,
JsxSelfClosingElement = 276,
JsxOpeningElement = 277,
JsxClosingElement = 278,
JsxFragment = 279,
JsxOpeningFragment = 280,
JsxClosingFragment = 281,
JsxAttribute = 282,
JsxAttributes = 283,
JsxSpreadAttribute = 284,
JsxExpression = 285,
CaseClause = 286,
DefaultClause = 287,
HeritageClause = 288,
CatchClause = 289,
PropertyAssignment = 290,
ShorthandPropertyAssignment = 291,
SpreadAssignment = 292,
EnumMember = 293,
UnparsedPrologue = 294,
UnparsedPrepend = 295,
UnparsedText = 296,
UnparsedInternalText = 297,
UnparsedSyntheticReference = 298,
SourceFile = 299,
Bundle = 300,
UnparsedSource = 301,
InputFiles = 302,
JSDocTypeExpression = 303,
JSDocNameReference = 304,
JSDocMemberName = 305,
JSDocAllType = 306,
JSDocUnknownType = 307,
JSDocNullableType = 308,
JSDocNonNullableType = 309,
JSDocOptionalType = 310,
JSDocFunctionType = 311,
JSDocVariadicType = 312,
JSDocNamepathType = 313,
JSDocComment = 314,
JSDocText = 315,
JSDocTypeLiteral = 316,
JSDocSignature = 317,
JSDocLink = 318,
JSDocTag = 319,
JSDocAugmentsTag = 320,
JSDocImplementsTag = 321,
JSDocAuthorTag = 322,
JSDocDeprecatedTag = 323,
JSDocClassTag = 324,
JSDocPublicTag = 325,
JSDocPrivateTag = 326,
JSDocProtectedTag = 327,
JSDocReadonlyTag = 328,
JSDocOverrideTag = 329,
JSDocCallbackTag = 330,
JSDocEnumTag = 331,
JSDocParameterTag = 332,
JSDocReturnTag = 333,
JSDocThisTag = 334,
JSDocTypeTag = 335,
JSDocTemplateTag = 336,
JSDocTypedefTag = 337,
JSDocSeeTag = 338,
JSDocPropertyTag = 339,
SyntaxList = 340,
NotEmittedStatement = 341,
PartiallyEmittedExpression = 342,
CommaListExpression = 343,
MergeDeclarationMarker = 344,
EndOfDeclarationMarker = 345,
SyntheticReferenceExpression = 346,
Count = 347,
FirstAssignment = 63,
LastAssignment = 78,
FirstCompoundAssignment = 64,
LastCompoundAssignment = 78,
FirstReservedWord = 81,
LastReservedWord = 116,
FirstKeyword = 81,
LastKeyword = 158,
FirstFutureReservedWord = 117,
LastFutureReservedWord = 125,
FirstTypeNode = 174,
LastTypeNode = 197,
FirstPunctuation = 18,
LastPunctuation = 77,
LastPunctuation = 78,
FirstToken = 0,
LastToken = 157,
LastToken = 158,
FirstTriviaToken = 2,
LastTriviaToken = 7,
FirstLiteralToken = 8,
@@ -473,25 +476,25 @@ declare namespace ts {
FirstTemplateToken = 14,
LastTemplateToken = 17,
FirstBinaryOperator = 29,
LastBinaryOperator = 77,
FirstStatement = 233,
LastStatement = 249,
FirstNode = 158,
FirstJSDocNode = 302,
LastJSDocNode = 337,
FirstJSDocTagNode = 317,
LastJSDocTagNode = 337,
LastBinaryOperator = 78,
FirstStatement = 234,
LastStatement = 250,
FirstNode = 159,
FirstJSDocNode = 303,
LastJSDocNode = 339,
FirstJSDocTagNode = 319,
LastJSDocTagNode = 339,
}
export type TriviaSyntaxKind = SyntaxKind.SingleLineCommentTrivia | SyntaxKind.MultiLineCommentTrivia | SyntaxKind.NewLineTrivia | SyntaxKind.WhitespaceTrivia | SyntaxKind.ShebangTrivia | SyntaxKind.ConflictMarkerTrivia;
export type LiteralSyntaxKind = SyntaxKind.NumericLiteral | SyntaxKind.BigIntLiteral | SyntaxKind.StringLiteral | SyntaxKind.JsxText | SyntaxKind.JsxTextAllWhiteSpaces | SyntaxKind.RegularExpressionLiteral | SyntaxKind.NoSubstitutionTemplateLiteral;
export type PseudoLiteralSyntaxKind = SyntaxKind.TemplateHead | SyntaxKind.TemplateMiddle | SyntaxKind.TemplateTail;
export type PunctuationSyntaxKind = SyntaxKind.OpenBraceToken | SyntaxKind.CloseBraceToken | SyntaxKind.OpenParenToken | SyntaxKind.CloseParenToken | SyntaxKind.OpenBracketToken | SyntaxKind.CloseBracketToken | SyntaxKind.DotToken | SyntaxKind.DotDotDotToken | SyntaxKind.SemicolonToken | SyntaxKind.CommaToken | SyntaxKind.QuestionDotToken | SyntaxKind.LessThanToken | SyntaxKind.LessThanSlashToken | SyntaxKind.GreaterThanToken | SyntaxKind.LessThanEqualsToken | SyntaxKind.GreaterThanEqualsToken | SyntaxKind.EqualsEqualsToken | SyntaxKind.ExclamationEqualsToken | SyntaxKind.EqualsEqualsEqualsToken | SyntaxKind.ExclamationEqualsEqualsToken | SyntaxKind.EqualsGreaterThanToken | SyntaxKind.PlusToken | SyntaxKind.MinusToken | SyntaxKind.AsteriskToken | SyntaxKind.AsteriskAsteriskToken | SyntaxKind.SlashToken | SyntaxKind.PercentToken | SyntaxKind.PlusPlusToken | SyntaxKind.MinusMinusToken | SyntaxKind.LessThanLessThanToken | SyntaxKind.GreaterThanGreaterThanToken | SyntaxKind.GreaterThanGreaterThanGreaterThanToken | SyntaxKind.AmpersandToken | SyntaxKind.BarToken | SyntaxKind.CaretToken | SyntaxKind.ExclamationToken | SyntaxKind.TildeToken | SyntaxKind.AmpersandAmpersandToken | SyntaxKind.BarBarToken | SyntaxKind.QuestionQuestionToken | SyntaxKind.QuestionToken | SyntaxKind.ColonToken | SyntaxKind.AtToken | SyntaxKind.BacktickToken | SyntaxKind.EqualsToken | SyntaxKind.PlusEqualsToken | SyntaxKind.MinusEqualsToken | SyntaxKind.AsteriskEqualsToken | SyntaxKind.AsteriskAsteriskEqualsToken | SyntaxKind.SlashEqualsToken | SyntaxKind.PercentEqualsToken | SyntaxKind.LessThanLessThanEqualsToken | SyntaxKind.GreaterThanGreaterThanEqualsToken | SyntaxKind.GreaterThanGreaterThanGreaterThanEqualsToken | SyntaxKind.AmpersandEqualsToken | SyntaxKind.BarEqualsToken | SyntaxKind.CaretEqualsToken;
export type PunctuationSyntaxKind = SyntaxKind.OpenBraceToken | SyntaxKind.CloseBraceToken | SyntaxKind.OpenParenToken | SyntaxKind.CloseParenToken | SyntaxKind.OpenBracketToken | SyntaxKind.CloseBracketToken | SyntaxKind.DotToken | SyntaxKind.DotDotDotToken | SyntaxKind.SemicolonToken | SyntaxKind.CommaToken | SyntaxKind.QuestionDotToken | SyntaxKind.LessThanToken | SyntaxKind.LessThanSlashToken | SyntaxKind.GreaterThanToken | SyntaxKind.LessThanEqualsToken | SyntaxKind.GreaterThanEqualsToken | SyntaxKind.EqualsEqualsToken | SyntaxKind.ExclamationEqualsToken | SyntaxKind.EqualsEqualsEqualsToken | SyntaxKind.ExclamationEqualsEqualsToken | SyntaxKind.EqualsGreaterThanToken | SyntaxKind.PlusToken | SyntaxKind.MinusToken | SyntaxKind.AsteriskToken | SyntaxKind.AsteriskAsteriskToken | SyntaxKind.SlashToken | SyntaxKind.PercentToken | SyntaxKind.PlusPlusToken | SyntaxKind.MinusMinusToken | SyntaxKind.LessThanLessThanToken | SyntaxKind.GreaterThanGreaterThanToken | SyntaxKind.GreaterThanGreaterThanGreaterThanToken | SyntaxKind.AmpersandToken | SyntaxKind.BarToken | SyntaxKind.CaretToken | SyntaxKind.ExclamationToken | SyntaxKind.TildeToken | SyntaxKind.AmpersandAmpersandToken | SyntaxKind.BarBarToken | SyntaxKind.QuestionQuestionToken | SyntaxKind.QuestionToken | SyntaxKind.ColonToken | SyntaxKind.AtToken | SyntaxKind.BacktickToken | SyntaxKind.HashToken | SyntaxKind.EqualsToken | SyntaxKind.PlusEqualsToken | SyntaxKind.MinusEqualsToken | SyntaxKind.AsteriskEqualsToken | SyntaxKind.AsteriskAsteriskEqualsToken | SyntaxKind.SlashEqualsToken | SyntaxKind.PercentEqualsToken | SyntaxKind.LessThanLessThanEqualsToken | SyntaxKind.GreaterThanGreaterThanEqualsToken | SyntaxKind.GreaterThanGreaterThanGreaterThanEqualsToken | SyntaxKind.AmpersandEqualsToken | SyntaxKind.BarEqualsToken | SyntaxKind.CaretEqualsToken;
export type KeywordSyntaxKind = SyntaxKind.AbstractKeyword | SyntaxKind.AnyKeyword | SyntaxKind.AsKeyword | SyntaxKind.AssertsKeyword | SyntaxKind.AsyncKeyword | SyntaxKind.AwaitKeyword | SyntaxKind.BigIntKeyword | SyntaxKind.BooleanKeyword | SyntaxKind.BreakKeyword | SyntaxKind.CaseKeyword | SyntaxKind.CatchKeyword | SyntaxKind.ClassKeyword | SyntaxKind.ConstKeyword | SyntaxKind.ConstructorKeyword | SyntaxKind.ContinueKeyword | SyntaxKind.DebuggerKeyword | SyntaxKind.DeclareKeyword | SyntaxKind.DefaultKeyword | SyntaxKind.DeleteKeyword | SyntaxKind.DoKeyword | SyntaxKind.ElseKeyword | SyntaxKind.EnumKeyword | SyntaxKind.ExportKeyword | SyntaxKind.ExtendsKeyword | SyntaxKind.FalseKeyword | SyntaxKind.FinallyKeyword | SyntaxKind.ForKeyword | SyntaxKind.FromKeyword | SyntaxKind.FunctionKeyword | SyntaxKind.GetKeyword | SyntaxKind.GlobalKeyword | SyntaxKind.IfKeyword | SyntaxKind.ImplementsKeyword | SyntaxKind.ImportKeyword | SyntaxKind.InferKeyword | SyntaxKind.InKeyword | SyntaxKind.InstanceOfKeyword | SyntaxKind.InterfaceKeyword | SyntaxKind.IntrinsicKeyword | SyntaxKind.IsKeyword | SyntaxKind.KeyOfKeyword | SyntaxKind.LetKeyword | SyntaxKind.ModuleKeyword | SyntaxKind.NamespaceKeyword | SyntaxKind.NeverKeyword | SyntaxKind.NewKeyword | SyntaxKind.NullKeyword | SyntaxKind.NumberKeyword | SyntaxKind.ObjectKeyword | SyntaxKind.OfKeyword | SyntaxKind.PackageKeyword | SyntaxKind.PrivateKeyword | SyntaxKind.ProtectedKeyword | SyntaxKind.PublicKeyword | SyntaxKind.ReadonlyKeyword | SyntaxKind.OverrideKeyword | SyntaxKind.RequireKeyword | SyntaxKind.ReturnKeyword | SyntaxKind.SetKeyword | SyntaxKind.StaticKeyword | SyntaxKind.StringKeyword | SyntaxKind.SuperKeyword | SyntaxKind.SwitchKeyword | SyntaxKind.SymbolKeyword | SyntaxKind.ThisKeyword | SyntaxKind.ThrowKeyword | SyntaxKind.TrueKeyword | SyntaxKind.TryKeyword | SyntaxKind.TypeKeyword | SyntaxKind.TypeOfKeyword | SyntaxKind.UndefinedKeyword | SyntaxKind.UniqueKeyword | SyntaxKind.UnknownKeyword | SyntaxKind.VarKeyword | SyntaxKind.VoidKeyword | SyntaxKind.WhileKeyword | SyntaxKind.WithKeyword | SyntaxKind.YieldKeyword;
export type ModifierSyntaxKind = SyntaxKind.AbstractKeyword | SyntaxKind.AsyncKeyword | SyntaxKind.ConstKeyword | SyntaxKind.DeclareKeyword | SyntaxKind.DefaultKeyword | SyntaxKind.ExportKeyword | SyntaxKind.PrivateKeyword | SyntaxKind.ProtectedKeyword | SyntaxKind.PublicKeyword | SyntaxKind.ReadonlyKeyword | SyntaxKind.OverrideKeyword | SyntaxKind.StaticKeyword;
export type KeywordTypeSyntaxKind = SyntaxKind.AnyKeyword | SyntaxKind.BigIntKeyword | SyntaxKind.BooleanKeyword | SyntaxKind.IntrinsicKeyword | SyntaxKind.NeverKeyword | SyntaxKind.NumberKeyword | SyntaxKind.ObjectKeyword | SyntaxKind.StringKeyword | SyntaxKind.SymbolKeyword | SyntaxKind.UndefinedKeyword | SyntaxKind.UnknownKeyword | SyntaxKind.VoidKeyword;
export type TokenSyntaxKind = SyntaxKind.Unknown | SyntaxKind.EndOfFileToken | TriviaSyntaxKind | LiteralSyntaxKind | PseudoLiteralSyntaxKind | PunctuationSyntaxKind | SyntaxKind.Identifier | KeywordSyntaxKind;
export type JsxTokenSyntaxKind = SyntaxKind.LessThanSlashToken | SyntaxKind.EndOfFileToken | SyntaxKind.ConflictMarkerTrivia | SyntaxKind.JsxText | SyntaxKind.JsxTextAllWhiteSpaces | SyntaxKind.OpenBraceToken | SyntaxKind.LessThanToken;
export type JSDocSyntaxKind = SyntaxKind.EndOfFileToken | SyntaxKind.WhitespaceTrivia | SyntaxKind.AtToken | SyntaxKind.NewLineTrivia | SyntaxKind.AsteriskToken | SyntaxKind.OpenBraceToken | SyntaxKind.CloseBraceToken | SyntaxKind.LessThanToken | SyntaxKind.GreaterThanToken | SyntaxKind.OpenBracketToken | SyntaxKind.CloseBracketToken | SyntaxKind.EqualsToken | SyntaxKind.CommaToken | SyntaxKind.DotToken | SyntaxKind.Identifier | SyntaxKind.BacktickToken | SyntaxKind.Unknown | KeywordSyntaxKind;
export type JSDocSyntaxKind = SyntaxKind.EndOfFileToken | SyntaxKind.WhitespaceTrivia | SyntaxKind.AtToken | SyntaxKind.NewLineTrivia | SyntaxKind.AsteriskToken | SyntaxKind.OpenBraceToken | SyntaxKind.CloseBraceToken | SyntaxKind.LessThanToken | SyntaxKind.GreaterThanToken | SyntaxKind.OpenBracketToken | SyntaxKind.CloseBracketToken | SyntaxKind.EqualsToken | SyntaxKind.CommaToken | SyntaxKind.DotToken | SyntaxKind.Identifier | SyntaxKind.BacktickToken | SyntaxKind.HashToken | SyntaxKind.Unknown | KeywordSyntaxKind;
export enum NodeFlags {
None = 0,
Let = 1,
@@ -1710,7 +1713,13 @@ declare namespace ts {
}
export interface JSDocNameReference extends Node {
readonly kind: SyntaxKind.JSDocNameReference;
readonly name: EntityName;
readonly name: EntityName | JSDocMemberName;
}
/** Class#method reference in JSDoc */
export interface JSDocMemberName extends Node {
readonly kind: SyntaxKind.JSDocMemberName;
readonly left: EntityName | JSDocMemberName;
readonly right: Identifier;
}
export interface JSDocType extends TypeNode {
_jsDocTypeBrand: any;
@@ -1758,7 +1767,7 @@ declare namespace ts {
}
export interface JSDocLink extends Node {
readonly kind: SyntaxKind.JSDocLink;
readonly name?: EntityName;
readonly name?: EntityName | JSDocMemberName;
text: string;
}
export interface JSDocText extends Node {
@@ -3496,10 +3505,12 @@ declare namespace ts {
updateJSDocNamepathType(node: JSDocNamepathType, type: TypeNode): JSDocNamepathType;
createJSDocTypeExpression(type: TypeNode): JSDocTypeExpression;
updateJSDocTypeExpression(node: JSDocTypeExpression, type: TypeNode): JSDocTypeExpression;
createJSDocNameReference(name: EntityName): JSDocNameReference;
updateJSDocNameReference(node: JSDocNameReference, name: EntityName): JSDocNameReference;
createJSDocLink(name: EntityName | undefined, text: string): JSDocLink;
updateJSDocLink(node: JSDocLink, name: EntityName | undefined, text: string): JSDocLink;
createJSDocNameReference(name: EntityName | JSDocMemberName): JSDocNameReference;
updateJSDocNameReference(node: JSDocNameReference, name: EntityName | JSDocMemberName): JSDocNameReference;
createJSDocMemberName(left: EntityName | JSDocMemberName, right: Identifier): JSDocMemberName;
updateJSDocMemberName(node: JSDocMemberName, left: EntityName | JSDocMemberName, right: Identifier): JSDocMemberName;
createJSDocLink(name: EntityName | JSDocMemberName | undefined, text: string): JSDocLink;
updateJSDocLink(node: JSDocLink, name: EntityName | JSDocMemberName | undefined, text: string): JSDocLink;
createJSDocTypeLiteral(jsDocPropertyTags?: readonly JSDocPropertyLikeTag[], isArrayType?: boolean): JSDocTypeLiteral;
updateJSDocTypeLiteral(node: JSDocTypeLiteral, jsDocPropertyTags: readonly JSDocPropertyLikeTag[] | undefined, isArrayType: boolean | undefined): JSDocTypeLiteral;
createJSDocSignature(typeParameters: readonly JSDocTemplateTag[] | undefined, parameters: readonly JSDocParameterTag[], type?: JSDocReturnTag): JSDocSignature;
@@ -4018,6 +4029,7 @@ declare namespace ts {
reScanJsxAttributeValue(): SyntaxKind;
reScanJsxToken(allowMultilineJsxText?: boolean): JsxTokenSyntaxKind;
reScanLessThanToken(): SyntaxKind;
reScanHashToken(): SyntaxKind;
reScanQuestionToken(): SyntaxKind;
reScanInvalidIdentifier(): SyntaxKind;
scanJsxToken(): JsxTokenSyntaxKind;
@@ -4556,6 +4568,7 @@ declare namespace ts {
function isUnparsedSource(node: Node): node is UnparsedSource;
function isJSDocTypeExpression(node: Node): node is JSDocTypeExpression;
function isJSDocNameReference(node: Node): node is JSDocNameReference;
function isJSDocMemberName(node: Node): node is JSDocMemberName;
function isJSDocLink(node: Node): node is JSDocLink;
function isJSDocAllType(node: Node): node is JSDocAllType;
function isJSDocUnknownType(node: Node): node is JSDocUnknownType;
@@ -8,10 +8,10 @@
// * @see {m}
// * {@link C.[|m|]}
// * @see {C.[|m|]}
// * {@link C#m}
// * @see {C#m}
// * {@link C.prototype.m}
// * @see {C.prototype.m}
// * {@link C#[|m|]}
// * @see {C#[|m|]}
// * {@link C.prototype.[|m|]}
// * @see {C.prototype.[|m|]}
// */
// p() { }
// /**
@@ -42,6 +42,8 @@
// * @see {a}
// * {@link I.a}
// * @see {I.a}
// * {@link I#a}
// * @see {I#a}
// */
// c()
// /**
@@ -159,6 +161,42 @@
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag1.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 145,
"length": 1
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag1.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 163,
"length": 1
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag1.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 192,
"length": 1
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag1.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 220,
"length": 1
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag1.ts",
"isWriteAccess": false,
"isDefinition": false
}
]
}
@@ -185,10 +223,10 @@
// * @see {n}
// * {@link C.[|n|]}
// * @see {C.[|n|]}
// * {@link C#n}
// * @see {C#n}
// * {@link C.prototype.n}
// * @see {C.prototype.n}
// * {@link C#[|n|]}
// * @see {C#[|n|]}
// * {@link C.prototype.[|n|]}
// * @see {C.prototype.[|n|]}
// */
// q() { }
// /**
@@ -208,6 +246,8 @@
// * @see {a}
// * {@link I.a}
// * @see {I.a}
// * {@link I#a}
// * @see {I#a}
// */
// c()
// /**
@@ -317,6 +357,42 @@
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag1.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 337,
"length": 1
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag1.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 355,
"length": 1
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag1.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 384,
"length": 1
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag1.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 412,
"length": 1
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag1.ts",
"isWriteAccess": false,
"isDefinition": false
}
]
}
@@ -366,6 +442,8 @@
// * @see {a}
// * {@link I.a}
// * @see {I.a}
// * {@link I#a}
// * @see {I#a}
// */
// c()
// /**
@@ -532,6 +610,8 @@
// * @see {a}
// * {@link I.[|a|]}
// * @see {I.[|a|]}
// * {@link I#[|a|]}
// * @see {I#[|a|]}
// */
// c()
// /**
@@ -649,6 +729,24 @@
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag1.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 661,
"length": 1
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag1.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 679,
"length": 1
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag1.ts",
"isWriteAccess": false,
"isDefinition": false
}
]
}
@@ -698,6 +796,8 @@
// * @see {a}
// * {@link I.a}
// * @see {I.a}
// * {@link I#a}
// * @see {I#a}
// */
// c()
// /**
@@ -792,7 +892,7 @@
},
{
"textSpan": {
"start": 718,
"start": 755,
"length": 1
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag1.ts",
@@ -801,7 +901,7 @@
},
{
"textSpan": {
"start": 736,
"start": 773,
"length": 1
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag1.ts",
@@ -856,6 +956,8 @@
// * @see {a}
// * {@link I.a}
// * @see {I.a}
// * {@link I#a}
// * @see {I#a}
// */
// c()
// /**
@@ -884,7 +986,7 @@
"kind": "local function",
"name": "(local function) r2(): void",
"textSpan": {
"start": 879,
"start": 916,
"length": 2
},
"displayParts": [
@@ -930,14 +1032,14 @@
}
],
"contextSpan": {
"start": 870,
"start": 907,
"length": 17
}
},
"references": [
{
"textSpan": {
"start": 793,
"start": 830,
"length": 2
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag1.ts",
@@ -946,7 +1048,7 @@
},
{
"textSpan": {
"start": 837,
"start": 874,
"length": 2
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag1.ts",
@@ -955,12 +1057,12 @@
},
{
"textSpan": {
"start": 879,
"start": 916,
"length": 2
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag1.ts",
"contextSpan": {
"start": 870,
"start": 907,
"length": 17
},
"isWriteAccess": true,
@@ -968,4 +1070,412 @@
}
]
}
]
// === /tests/cases/fourslash/findAllReferencesLinkTag1.ts ===
// class [|C|]/*FIND ALL REFS*/ {
// m() { }
// n = 1
// static s() { }
// /**
// * {@link m}
// * @see {m}
// * {@link [|C|].m}
// * @see {[|C|].m}
// * {@link [|C|]#m}
// * @see {[|C|]#m}
// * {@link [|C|].prototype.m}
// * @see {[|C|].prototype.m}
// */
// p() { }
// /**
// * {@link n}
// * @see {n}
// * {@link [|C|].n}
// * @see {[|C|].n}
// * {@link [|C|]#n}
// * @see {[|C|]#n}
// * {@link [|C|].prototype.n}
// * @see {[|C|].prototype.n}
// */
// q() { }
// /**
// * {@link s}
// * @see {s}
// * {@link [|C|].s}
// * @see {[|C|].s}
// */
// r() { }
// }
//
// interface I {
// a()
// b: 1
// /**
// * {@link a}
// * @see {a}
// * {@link I.a}
// * @see {I.a}
// * {@link I#a}
// * @see {I#a}
// */
// c()
// /**
// * {@link b}
// * @see {b}
// * {@link I.b}
// * @see {I.b}
// */
// d()
// }
//
// function nestor() {
// /** {@link r2} */
// function ref() { }
// /** @see {r2} */
// function d3() { }
// function r2() { }
// }
[
{
"definition": {
"containerKind": "",
"containerName": "",
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag1.ts",
"kind": "class",
"name": "class C",
"textSpan": {
"start": 6,
"length": 1
},
"displayParts": [
{
"text": "class",
"kind": "keyword"
},
{
"text": " ",
"kind": "space"
},
{
"text": "C",
"kind": "className"
}
],
"contextSpan": {
"start": 0,
"length": 534
}
},
"references": [
{
"textSpan": {
"start": 6,
"length": 1
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag1.ts",
"contextSpan": {
"start": 0,
"length": 534
},
"isWriteAccess": true,
"isDefinition": true
},
{
"textSpan": {
"start": 106,
"length": 1
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag1.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 124,
"length": 1
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag1.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 143,
"length": 1
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag1.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 161,
"length": 1
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag1.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 180,
"length": 1
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag1.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 208,
"length": 1
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag1.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 298,
"length": 1
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag1.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 316,
"length": 1
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag1.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 335,
"length": 1
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag1.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 353,
"length": 1
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag1.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 372,
"length": 1
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag1.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 400,
"length": 1
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag1.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 490,
"length": 1
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag1.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 508,
"length": 1
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag1.ts",
"isWriteAccess": false,
"isDefinition": false
}
]
}
]
// === /tests/cases/fourslash/findAllReferencesLinkTag1.ts ===
// class C {
// m() { }
// n = 1
// static s() { }
// /**
// * {@link m}
// * @see {m}
// * {@link C.m}
// * @see {C.m}
// * {@link C#m}
// * @see {C#m}
// * {@link C.prototype.m}
// * @see {C.prototype.m}
// */
// p() { }
// /**
// * {@link n}
// * @see {n}
// * {@link C.n}
// * @see {C.n}
// * {@link C#n}
// * @see {C#n}
// * {@link C.prototype.n}
// * @see {C.prototype.n}
// */
// q() { }
// /**
// * {@link s}
// * @see {s}
// * {@link C.s}
// * @see {C.s}
// */
// r() { }
// }
//
// interface [|I|]/*FIND ALL REFS*/ {
// a()
// b: 1
// /**
// * {@link a}
// * @see {a}
// * {@link [|I|].a}
// * @see {[|I|].a}
// * {@link [|I|]#a}
// * @see {[|I|]#a}
// */
// c()
// /**
// * {@link b}
// * @see {b}
// * {@link [|I|].b}
// * @see {[|I|].b}
// */
// d()
// }
//
// function nestor() {
// /** {@link r2} */
// function ref() { }
// /** @see {r2} */
// function d3() { }
// function r2() { }
// }
[
{
"definition": {
"containerKind": "",
"containerName": "",
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag1.ts",
"kind": "interface",
"name": "interface I",
"textSpan": {
"start": 546,
"length": 1
},
"displayParts": [
{
"text": "interface",
"kind": "keyword"
},
{
"text": " ",
"kind": "space"
},
{
"text": "I",
"kind": "interfaceName"
}
],
"contextSpan": {
"start": 536,
"length": 257
}
},
"references": [
{
"textSpan": {
"start": 546,
"length": 1
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag1.ts",
"contextSpan": {
"start": 536,
"length": 257
},
"isWriteAccess": true,
"isDefinition": true
},
{
"textSpan": {
"start": 622,
"length": 1
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag1.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 640,
"length": 1
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag1.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 659,
"length": 1
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag1.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 677,
"length": 1
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag1.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 753,
"length": 1
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag1.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 771,
"length": 1
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag1.ts",
"isWriteAccess": false,
"isDefinition": false
}
]
}
]
@@ -0,0 +1,876 @@
// === /tests/cases/fourslash/findAllReferencesLinkTag2.ts ===
// namespace NPR {
// export class Consider {
// This = class {
// show() { }
// }
// [|m|]/*FIND ALL REFS*/() { }
// }
// /**
// * @see {Consider.prototype.[|m|]}
// * {@link Consider#[|m|]}
// * @see {Consider#This#show}
// * {@link Consider.This.show}
// * @see {NPR.Consider#This#show}
// * {@link NPR.Consider.This#show}
// * @see {NPR.Consider#This.show} # doesn't parse trailing .
// * @see {NPR.Consider.This.show}
// */
// export function ref() { }
// }
// /**
// * {@link NPR.Consider#This#show hello hello}
// * {@link NPR.Consider.This#show}
// * @see {NPR.Consider#This.show} # doesn't parse trailing .
// * @see {NPR.Consider.This.show}
// */
// export function outerref() { }
[
{
"definition": {
"containerKind": "",
"containerName": "",
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag2.ts",
"kind": "method",
"name": "(method) NPR.Consider.m(): void",
"textSpan": {
"start": 108,
"length": 1
},
"displayParts": [
{
"text": "(",
"kind": "punctuation"
},
{
"text": "method",
"kind": "text"
},
{
"text": ")",
"kind": "punctuation"
},
{
"text": " ",
"kind": "space"
},
{
"text": "NPR",
"kind": "moduleName"
},
{
"text": ".",
"kind": "punctuation"
},
{
"text": "Consider",
"kind": "className"
},
{
"text": ".",
"kind": "punctuation"
},
{
"text": "m",
"kind": "methodName"
},
{
"text": "(",
"kind": "punctuation"
},
{
"text": ")",
"kind": "punctuation"
},
{
"text": ":",
"kind": "punctuation"
},
{
"text": " ",
"kind": "space"
},
{
"text": "void",
"kind": "keyword"
}
],
"contextSpan": {
"start": 108,
"length": 7
}
},
"references": [
{
"textSpan": {
"start": 108,
"length": 1
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag2.ts",
"contextSpan": {
"start": 108,
"length": 7
},
"isWriteAccess": true,
"isDefinition": true
},
{
"textSpan": {
"start": 162,
"length": 1
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag2.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 188,
"length": 1
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag2.ts",
"isWriteAccess": false,
"isDefinition": false
}
]
}
]
// === /tests/cases/fourslash/findAllReferencesLinkTag2.ts ===
// namespace NPR {
// export class Consider {
// This = class {
// [|show|]/*FIND ALL REFS*/() { }
// }
// m() { }
// }
// /**
// * @see {Consider.prototype.m}
// * {@link Consider#m}
// * @see {Consider#This#[|show|]}
// * {@link Consider.This.[|show|]}
// * @see {NPR.Consider#This#[|show|]}
// * {@link NPR.Consider.This#[|show|]}
// * @see {NPR.Consider#This.show} # doesn't parse trailing .
// * @see {NPR.Consider.This.[|show|]}
// */
// export function ref() { }
// }
// /**
// * {@link NPR.Consider#This#[|show|] hello hello}
// * {@link NPR.Consider.This#[|show|]}
// * @see {NPR.Consider#This.show} # doesn't parse trailing .
// * @see {NPR.Consider.This.[|show|]}
// */
// export function outerref() { }
[
{
"definition": {
"containerKind": "",
"containerName": "",
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag2.ts",
"kind": "method",
"name": "(method) (Anonymous class).show(): void",
"textSpan": {
"start": 79,
"length": 4
},
"displayParts": [
{
"text": "(",
"kind": "punctuation"
},
{
"text": "method",
"kind": "text"
},
{
"text": ")",
"kind": "punctuation"
},
{
"text": " ",
"kind": "space"
},
{
"text": "(Anonymous class)",
"kind": "className"
},
{
"text": ".",
"kind": "punctuation"
},
{
"text": "show",
"kind": "methodName"
},
{
"text": "(",
"kind": "punctuation"
},
{
"text": ")",
"kind": "punctuation"
},
{
"text": ":",
"kind": "punctuation"
},
{
"text": " ",
"kind": "space"
},
{
"text": "void",
"kind": "keyword"
}
],
"contextSpan": {
"start": 79,
"length": 10
}
},
"references": [
{
"textSpan": {
"start": 79,
"length": 4
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag2.ts",
"contextSpan": {
"start": 79,
"length": 10
},
"isWriteAccess": true,
"isDefinition": true
},
{
"textSpan": {
"start": 218,
"length": 4
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag2.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 252,
"length": 4
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag2.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 289,
"length": 4
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag2.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 327,
"length": 4
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag2.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 428,
"length": 4
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag2.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 506,
"length": 4
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag2.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 552,
"length": 4
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag2.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 645,
"length": 4
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag2.ts",
"isWriteAccess": false,
"isDefinition": false
}
]
}
]
// === /tests/cases/fourslash/findAllReferencesLinkTag2.ts ===
// namespace NPR {
// export class Consider {
// [|This|]/*FIND ALL REFS*/ = class {
// show() { }
// }
// m() { }
// }
// /**
// * @see {Consider.prototype.m}
// * {@link Consider#m}
// * @see {Consider#[|This|]#show}
// * {@link Consider.[|This|].show}
// * @see {NPR.Consider#[|This|]#show}
// * {@link NPR.Consider.[|This|]#show}
// * @see {NPR.Consider#[|This|].show} # doesn't parse trailing .
// * @see {NPR.Consider.[|This|].show}
// */
// export function ref() { }
// }
// /**
// * {@link NPR.Consider#[|This|]#show hello hello}
// * {@link NPR.Consider.[|This|]#show}
// * @see {NPR.Consider#[|This|].show} # doesn't parse trailing .
// * @see {NPR.Consider.[|This|].show}
// */
// export function outerref() { }
[
{
"definition": {
"containerKind": "",
"containerName": "",
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag2.ts",
"kind": "property",
"name": "(property) NPR.Consider.This: typeof (Anonymous class)",
"textSpan": {
"start": 52,
"length": 4
},
"displayParts": [
{
"text": "(",
"kind": "punctuation"
},
{
"text": "property",
"kind": "text"
},
{
"text": ")",
"kind": "punctuation"
},
{
"text": " ",
"kind": "space"
},
{
"text": "NPR",
"kind": "moduleName"
},
{
"text": ".",
"kind": "punctuation"
},
{
"text": "Consider",
"kind": "className"
},
{
"text": ".",
"kind": "punctuation"
},
{
"text": "This",
"kind": "propertyName"
},
{
"text": ":",
"kind": "punctuation"
},
{
"text": " ",
"kind": "space"
},
{
"text": "typeof",
"kind": "keyword"
},
{
"text": " ",
"kind": "space"
},
{
"text": "(Anonymous class)",
"kind": "className"
}
],
"contextSpan": {
"start": 52,
"length": 47
}
},
"references": [
{
"textSpan": {
"start": 52,
"length": 4
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag2.ts",
"contextSpan": {
"start": 52,
"length": 47
},
"isWriteAccess": true,
"isDefinition": true
},
{
"textSpan": {
"start": 213,
"length": 4
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag2.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 247,
"length": 4
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag2.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 284,
"length": 4
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag2.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 322,
"length": 4
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag2.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 359,
"length": 4
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag2.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 423,
"length": 4
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag2.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 501,
"length": 4
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag2.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 547,
"length": 4
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag2.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 580,
"length": 4
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag2.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 640,
"length": 4
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag2.ts",
"isWriteAccess": false,
"isDefinition": false
}
]
}
]
// === /tests/cases/fourslash/findAllReferencesLinkTag2.ts ===
// namespace NPR {
// export class [|Consider|]/*FIND ALL REFS*/ {
// This = class {
// show() { }
// }
// m() { }
// }
// /**
// * @see {[|Consider|].prototype.m}
// * {@link [|Consider|]#m}
// * @see {[|Consider|]#This#show}
// * {@link [|Consider|].This.show}
// * @see {NPR.[|Consider|]#This#show}
// * {@link NPR.[|Consider|].This#show}
// * @see {NPR.[|Consider|]#This.show} # doesn't parse trailing .
// * @see {NPR.[|Consider|].This.show}
// */
// export function ref() { }
// }
// /**
// * {@link NPR.[|Consider|]#This#show hello hello}
// * {@link NPR.[|Consider|].This#show}
// * @see {NPR.[|Consider|]#This.show} # doesn't parse trailing .
// * @see {NPR.[|Consider|].This.show}
// */
// export function outerref() { }
[
{
"definition": {
"containerKind": "",
"containerName": "",
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag2.ts",
"kind": "class",
"name": "class NPR.Consider",
"textSpan": {
"start": 33,
"length": 8
},
"displayParts": [
{
"text": "class",
"kind": "keyword"
},
{
"text": " ",
"kind": "space"
},
{
"text": "NPR",
"kind": "moduleName"
},
{
"text": ".",
"kind": "punctuation"
},
{
"text": "Consider",
"kind": "className"
}
],
"contextSpan": {
"start": 20,
"length": 101
}
},
"references": [
{
"textSpan": {
"start": 33,
"length": 8
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag2.ts",
"contextSpan": {
"start": 20,
"length": 101
},
"isWriteAccess": true,
"isDefinition": true
},
{
"textSpan": {
"start": 143,
"length": 8
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag2.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 179,
"length": 8
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag2.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 204,
"length": 8
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag2.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 238,
"length": 8
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag2.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 275,
"length": 8
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag2.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 313,
"length": 8
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag2.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 350,
"length": 8
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag2.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 414,
"length": 8
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag2.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 492,
"length": 8
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag2.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 538,
"length": 8
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag2.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 571,
"length": 8
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag2.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 631,
"length": 8
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag2.ts",
"isWriteAccess": false,
"isDefinition": false
}
]
}
]
// === /tests/cases/fourslash/findAllReferencesLinkTag2.ts ===
// namespace [|NPR|]/*FIND ALL REFS*/ {
// export class Consider {
// This = class {
// show() { }
// }
// m() { }
// }
// /**
// * @see {Consider.prototype.m}
// * {@link Consider#m}
// * @see {Consider#This#show}
// * {@link Consider.This.show}
// * @see {[|NPR|].Consider#This#show}
// * {@link [|NPR|].Consider.This#show}
// * @see {[|NPR|].Consider#This.show} # doesn't parse trailing .
// * @see {[|NPR|].Consider.This.show}
// */
// export function ref() { }
// }
// /**
// * {@link [|NPR|].Consider#This#show hello hello}
// * {@link [|NPR|].Consider.This#show}
// * @see {[|NPR|].Consider#This.show} # doesn't parse trailing .
// * @see {[|NPR|].Consider.This.show}
// */
// export function outerref() { }
[
{
"definition": {
"containerKind": "",
"containerName": "",
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag2.ts",
"kind": "module",
"name": "namespace NPR",
"textSpan": {
"start": 10,
"length": 3
},
"displayParts": [
{
"text": "namespace",
"kind": "keyword"
},
{
"text": " ",
"kind": "space"
},
{
"text": "NPR",
"kind": "moduleName"
}
],
"contextSpan": {
"start": 0,
"length": 473
}
},
"references": [
{
"textSpan": {
"start": 10,
"length": 3
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag2.ts",
"contextSpan": {
"start": 0,
"length": 473
},
"isWriteAccess": true,
"isDefinition": true
},
{
"textSpan": {
"start": 271,
"length": 3
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag2.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 309,
"length": 3
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag2.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 346,
"length": 3
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag2.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 410,
"length": 3
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag2.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 488,
"length": 3
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag2.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 534,
"length": 3
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag2.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 567,
"length": 3
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag2.ts",
"isWriteAccess": false,
"isDefinition": false
},
{
"textSpan": {
"start": 627,
"length": 3
},
"fileName": "/tests/cases/fourslash/findAllReferencesLinkTag2.ts",
"isWriteAccess": false,
"isDefinition": false
}
]
}
]
@@ -161,7 +161,7 @@
"kind": "link"
},
{
"text": "unformattedpostfix text",
"text": "unformatted postfix text",
"kind": "linkText"
},
{
@@ -161,7 +161,7 @@
"kind": "link"
},
{
"text": "unformattedpostfix text",
"text": "unformatted postfix text",
"kind": "linkText"
},
{
@@ -161,7 +161,7 @@
"kind": "link"
},
{
"text": "unformattedpostfix text",
"text": "unformatted postfix text",
"kind": "linkText"
},
{
@@ -1,5 +1,5 @@
/// <reference path="fourslash.ts" />
//// class C {
//// class C/*7*/ {
//// m/*1*/() { }
//// n/*2*/ = 1
//// static s/*3*/() { }
@@ -34,7 +34,7 @@
//// r() { }
//// }
////
//// interface I {
//// interface I/*8*/ {
//// a/*4*/()
//// b/*5*/: 1
//// /**
@@ -42,6 +42,8 @@
//// * @see {a}
//// * {@link I.a}
//// * @see {I.a}
//// * {@link I#a}
//// * @see {I#a}
//// */
//// c()
//// /**
@@ -61,4 +63,4 @@
//// function r2/*6*/() { }
//// }
verify.baselineFindAllReferences('1', '2', '3', '4', '5', '6')
verify.baselineFindAllReferences('1', '2', '3', '4', '5', '6', '7', '8')
@@ -0,0 +1,28 @@
/// <reference path="fourslash.ts" />
//// namespace NPR/*5*/ {
//// export class Consider/*4*/ {
//// This/*3*/ = class {
//// show/*2*/() { }
//// }
//// m/*1*/() { }
//// }
//// /**
//// * @see {Consider.prototype.m}
//// * {@link Consider#m}
//// * @see {Consider#This#show}
//// * {@link Consider.This.show}
//// * @see {NPR.Consider#This#show}
//// * {@link NPR.Consider.This#show}
//// * @see {NPR.Consider#This.show} # doesn't parse trailing .
//// * @see {NPR.Consider.This.show}
//// */
//// export function ref() { }
//// }
//// /**
//// * {@link NPR.Consider#This#show hello hello}
//// * {@link NPR.Consider.This#show}
//// * @see {NPR.Consider#This.show} # doesn't parse trailing .
//// * @see {NPR.Consider.This.show}
//// */
//// export function outerref() { }
verify.baselineFindAllReferences('1', '2', '3', '4', '5')
+1 -1
View File
@@ -24,4 +24,4 @@ goTo.marker("use2");
verify.goToDefinitionIs(["def2"]);
goTo.marker("use3");
verify.goToDefinitionIs([]);
verify.goToDefinitionIs(["def2"]);