Giant blob of minor changes
[dotfiles/.git] / .config / coc / extensions / node_modules / coc-prettier / node_modules / prettier-eslint / node_modules / typescript / lib / typescript.d.ts
1 /*! *****************************************************************************
2 Copyright (c) Microsoft Corporation. All rights reserved.
3 Licensed under the Apache License, Version 2.0 (the "License"); you may not use
4 this file except in compliance with the License. You may obtain a copy of the
5 License at http://www.apache.org/licenses/LICENSE-2.0
6
7 THIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
8 KIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED
9 WARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,
10 MERCHANTABLITY OR NON-INFRINGEMENT.
11
12 See the Apache Version 2.0 License for specific language governing permissions
13 and limitations under the License.
14 ***************************************************************************** */
15
16 declare namespace ts {
17     const versionMajorMinor = "3.9";
18     /** The version of the TypeScript compiler release */
19     const version: string;
20     /**
21      * Type of objects whose values are all of the same type.
22      * The `in` and `for-in` operators can *not* be safely used,
23      * since `Object.prototype` may be modified by outside code.
24      */
25     interface MapLike<T> {
26         [index: string]: T;
27     }
28     interface SortedReadonlyArray<T> extends ReadonlyArray<T> {
29         " __sortedArrayBrand": any;
30     }
31     interface SortedArray<T> extends Array<T> {
32         " __sortedArrayBrand": any;
33     }
34     /** ES6 Map interface, only read methods included. */
35     interface ReadonlyMap<T> {
36         get(key: string): T | undefined;
37         has(key: string): boolean;
38         forEach(action: (value: T, key: string) => void): void;
39         readonly size: number;
40         keys(): Iterator<string>;
41         values(): Iterator<T>;
42         entries(): Iterator<[string, T]>;
43     }
44     /** ES6 Map interface. */
45     interface Map<T> extends ReadonlyMap<T> {
46         set(key: string, value: T): this;
47         delete(key: string): boolean;
48         clear(): void;
49     }
50     /** ES6 Iterator type. */
51     interface Iterator<T> {
52         next(): {
53             value: T;
54             done?: false;
55         } | {
56             value: never;
57             done: true;
58         };
59     }
60     /** Array that is only intended to be pushed to, never read. */
61     interface Push<T> {
62         push(...values: T[]): void;
63     }
64 }
65 declare namespace ts {
66     export type Path = string & {
67         __pathBrand: any;
68     };
69     export interface TextRange {
70         pos: number;
71         end: number;
72     }
73     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;
74     export type KeywordSyntaxKind = SyntaxKind.AbstractKeyword | SyntaxKind.AnyKeyword | SyntaxKind.AsKeyword | SyntaxKind.AssertsKeyword | SyntaxKind.BigIntKeyword | SyntaxKind.BooleanKeyword | SyntaxKind.BreakKeyword | SyntaxKind.CaseKeyword | SyntaxKind.CatchKeyword | SyntaxKind.ClassKeyword | SyntaxKind.ContinueKeyword | SyntaxKind.ConstKeyword | SyntaxKind.ConstructorKeyword | 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.IfKeyword | SyntaxKind.ImplementsKeyword | SyntaxKind.ImportKeyword | SyntaxKind.InKeyword | SyntaxKind.InferKeyword | SyntaxKind.InstanceOfKeyword | SyntaxKind.InterfaceKeyword | SyntaxKind.IsKeyword | SyntaxKind.KeyOfKeyword | SyntaxKind.LetKeyword | SyntaxKind.ModuleKeyword | SyntaxKind.NamespaceKeyword | SyntaxKind.NeverKeyword | SyntaxKind.NewKeyword | SyntaxKind.NullKeyword | SyntaxKind.NumberKeyword | SyntaxKind.ObjectKeyword | SyntaxKind.PackageKeyword | SyntaxKind.PrivateKeyword | SyntaxKind.ProtectedKeyword | SyntaxKind.PublicKeyword | SyntaxKind.ReadonlyKeyword | SyntaxKind.RequireKeyword | SyntaxKind.GlobalKeyword | 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 | SyntaxKind.AsyncKeyword | SyntaxKind.AwaitKeyword | SyntaxKind.OfKeyword;
75     export type JsxTokenSyntaxKind = SyntaxKind.LessThanSlashToken | SyntaxKind.EndOfFileToken | SyntaxKind.ConflictMarkerTrivia | SyntaxKind.JsxText | SyntaxKind.JsxTextAllWhiteSpaces | SyntaxKind.OpenBraceToken | SyntaxKind.LessThanToken;
76     export enum SyntaxKind {
77         Unknown = 0,
78         EndOfFileToken = 1,
79         SingleLineCommentTrivia = 2,
80         MultiLineCommentTrivia = 3,
81         NewLineTrivia = 4,
82         WhitespaceTrivia = 5,
83         ShebangTrivia = 6,
84         ConflictMarkerTrivia = 7,
85         NumericLiteral = 8,
86         BigIntLiteral = 9,
87         StringLiteral = 10,
88         JsxText = 11,
89         JsxTextAllWhiteSpaces = 12,
90         RegularExpressionLiteral = 13,
91         NoSubstitutionTemplateLiteral = 14,
92         TemplateHead = 15,
93         TemplateMiddle = 16,
94         TemplateTail = 17,
95         OpenBraceToken = 18,
96         CloseBraceToken = 19,
97         OpenParenToken = 20,
98         CloseParenToken = 21,
99         OpenBracketToken = 22,
100         CloseBracketToken = 23,
101         DotToken = 24,
102         DotDotDotToken = 25,
103         SemicolonToken = 26,
104         CommaToken = 27,
105         QuestionDotToken = 28,
106         LessThanToken = 29,
107         LessThanSlashToken = 30,
108         GreaterThanToken = 31,
109         LessThanEqualsToken = 32,
110         GreaterThanEqualsToken = 33,
111         EqualsEqualsToken = 34,
112         ExclamationEqualsToken = 35,
113         EqualsEqualsEqualsToken = 36,
114         ExclamationEqualsEqualsToken = 37,
115         EqualsGreaterThanToken = 38,
116         PlusToken = 39,
117         MinusToken = 40,
118         AsteriskToken = 41,
119         AsteriskAsteriskToken = 42,
120         SlashToken = 43,
121         PercentToken = 44,
122         PlusPlusToken = 45,
123         MinusMinusToken = 46,
124         LessThanLessThanToken = 47,
125         GreaterThanGreaterThanToken = 48,
126         GreaterThanGreaterThanGreaterThanToken = 49,
127         AmpersandToken = 50,
128         BarToken = 51,
129         CaretToken = 52,
130         ExclamationToken = 53,
131         TildeToken = 54,
132         AmpersandAmpersandToken = 55,
133         BarBarToken = 56,
134         QuestionToken = 57,
135         ColonToken = 58,
136         AtToken = 59,
137         QuestionQuestionToken = 60,
138         /** Only the JSDoc scanner produces BacktickToken. The normal scanner produces NoSubstitutionTemplateLiteral and related kinds. */
139         BacktickToken = 61,
140         EqualsToken = 62,
141         PlusEqualsToken = 63,
142         MinusEqualsToken = 64,
143         AsteriskEqualsToken = 65,
144         AsteriskAsteriskEqualsToken = 66,
145         SlashEqualsToken = 67,
146         PercentEqualsToken = 68,
147         LessThanLessThanEqualsToken = 69,
148         GreaterThanGreaterThanEqualsToken = 70,
149         GreaterThanGreaterThanGreaterThanEqualsToken = 71,
150         AmpersandEqualsToken = 72,
151         BarEqualsToken = 73,
152         CaretEqualsToken = 74,
153         Identifier = 75,
154         PrivateIdentifier = 76,
155         BreakKeyword = 77,
156         CaseKeyword = 78,
157         CatchKeyword = 79,
158         ClassKeyword = 80,
159         ConstKeyword = 81,
160         ContinueKeyword = 82,
161         DebuggerKeyword = 83,
162         DefaultKeyword = 84,
163         DeleteKeyword = 85,
164         DoKeyword = 86,
165         ElseKeyword = 87,
166         EnumKeyword = 88,
167         ExportKeyword = 89,
168         ExtendsKeyword = 90,
169         FalseKeyword = 91,
170         FinallyKeyword = 92,
171         ForKeyword = 93,
172         FunctionKeyword = 94,
173         IfKeyword = 95,
174         ImportKeyword = 96,
175         InKeyword = 97,
176         InstanceOfKeyword = 98,
177         NewKeyword = 99,
178         NullKeyword = 100,
179         ReturnKeyword = 101,
180         SuperKeyword = 102,
181         SwitchKeyword = 103,
182         ThisKeyword = 104,
183         ThrowKeyword = 105,
184         TrueKeyword = 106,
185         TryKeyword = 107,
186         TypeOfKeyword = 108,
187         VarKeyword = 109,
188         VoidKeyword = 110,
189         WhileKeyword = 111,
190         WithKeyword = 112,
191         ImplementsKeyword = 113,
192         InterfaceKeyword = 114,
193         LetKeyword = 115,
194         PackageKeyword = 116,
195         PrivateKeyword = 117,
196         ProtectedKeyword = 118,
197         PublicKeyword = 119,
198         StaticKeyword = 120,
199         YieldKeyword = 121,
200         AbstractKeyword = 122,
201         AsKeyword = 123,
202         AssertsKeyword = 124,
203         AnyKeyword = 125,
204         AsyncKeyword = 126,
205         AwaitKeyword = 127,
206         BooleanKeyword = 128,
207         ConstructorKeyword = 129,
208         DeclareKeyword = 130,
209         GetKeyword = 131,
210         InferKeyword = 132,
211         IsKeyword = 133,
212         KeyOfKeyword = 134,
213         ModuleKeyword = 135,
214         NamespaceKeyword = 136,
215         NeverKeyword = 137,
216         ReadonlyKeyword = 138,
217         RequireKeyword = 139,
218         NumberKeyword = 140,
219         ObjectKeyword = 141,
220         SetKeyword = 142,
221         StringKeyword = 143,
222         SymbolKeyword = 144,
223         TypeKeyword = 145,
224         UndefinedKeyword = 146,
225         UniqueKeyword = 147,
226         UnknownKeyword = 148,
227         FromKeyword = 149,
228         GlobalKeyword = 150,
229         BigIntKeyword = 151,
230         OfKeyword = 152,
231         QualifiedName = 153,
232         ComputedPropertyName = 154,
233         TypeParameter = 155,
234         Parameter = 156,
235         Decorator = 157,
236         PropertySignature = 158,
237         PropertyDeclaration = 159,
238         MethodSignature = 160,
239         MethodDeclaration = 161,
240         Constructor = 162,
241         GetAccessor = 163,
242         SetAccessor = 164,
243         CallSignature = 165,
244         ConstructSignature = 166,
245         IndexSignature = 167,
246         TypePredicate = 168,
247         TypeReference = 169,
248         FunctionType = 170,
249         ConstructorType = 171,
250         TypeQuery = 172,
251         TypeLiteral = 173,
252         ArrayType = 174,
253         TupleType = 175,
254         OptionalType = 176,
255         RestType = 177,
256         UnionType = 178,
257         IntersectionType = 179,
258         ConditionalType = 180,
259         InferType = 181,
260         ParenthesizedType = 182,
261         ThisType = 183,
262         TypeOperator = 184,
263         IndexedAccessType = 185,
264         MappedType = 186,
265         LiteralType = 187,
266         ImportType = 188,
267         ObjectBindingPattern = 189,
268         ArrayBindingPattern = 190,
269         BindingElement = 191,
270         ArrayLiteralExpression = 192,
271         ObjectLiteralExpression = 193,
272         PropertyAccessExpression = 194,
273         ElementAccessExpression = 195,
274         CallExpression = 196,
275         NewExpression = 197,
276         TaggedTemplateExpression = 198,
277         TypeAssertionExpression = 199,
278         ParenthesizedExpression = 200,
279         FunctionExpression = 201,
280         ArrowFunction = 202,
281         DeleteExpression = 203,
282         TypeOfExpression = 204,
283         VoidExpression = 205,
284         AwaitExpression = 206,
285         PrefixUnaryExpression = 207,
286         PostfixUnaryExpression = 208,
287         BinaryExpression = 209,
288         ConditionalExpression = 210,
289         TemplateExpression = 211,
290         YieldExpression = 212,
291         SpreadElement = 213,
292         ClassExpression = 214,
293         OmittedExpression = 215,
294         ExpressionWithTypeArguments = 216,
295         AsExpression = 217,
296         NonNullExpression = 218,
297         MetaProperty = 219,
298         SyntheticExpression = 220,
299         TemplateSpan = 221,
300         SemicolonClassElement = 222,
301         Block = 223,
302         EmptyStatement = 224,
303         VariableStatement = 225,
304         ExpressionStatement = 226,
305         IfStatement = 227,
306         DoStatement = 228,
307         WhileStatement = 229,
308         ForStatement = 230,
309         ForInStatement = 231,
310         ForOfStatement = 232,
311         ContinueStatement = 233,
312         BreakStatement = 234,
313         ReturnStatement = 235,
314         WithStatement = 236,
315         SwitchStatement = 237,
316         LabeledStatement = 238,
317         ThrowStatement = 239,
318         TryStatement = 240,
319         DebuggerStatement = 241,
320         VariableDeclaration = 242,
321         VariableDeclarationList = 243,
322         FunctionDeclaration = 244,
323         ClassDeclaration = 245,
324         InterfaceDeclaration = 246,
325         TypeAliasDeclaration = 247,
326         EnumDeclaration = 248,
327         ModuleDeclaration = 249,
328         ModuleBlock = 250,
329         CaseBlock = 251,
330         NamespaceExportDeclaration = 252,
331         ImportEqualsDeclaration = 253,
332         ImportDeclaration = 254,
333         ImportClause = 255,
334         NamespaceImport = 256,
335         NamedImports = 257,
336         ImportSpecifier = 258,
337         ExportAssignment = 259,
338         ExportDeclaration = 260,
339         NamedExports = 261,
340         NamespaceExport = 262,
341         ExportSpecifier = 263,
342         MissingDeclaration = 264,
343         ExternalModuleReference = 265,
344         JsxElement = 266,
345         JsxSelfClosingElement = 267,
346         JsxOpeningElement = 268,
347         JsxClosingElement = 269,
348         JsxFragment = 270,
349         JsxOpeningFragment = 271,
350         JsxClosingFragment = 272,
351         JsxAttribute = 273,
352         JsxAttributes = 274,
353         JsxSpreadAttribute = 275,
354         JsxExpression = 276,
355         CaseClause = 277,
356         DefaultClause = 278,
357         HeritageClause = 279,
358         CatchClause = 280,
359         PropertyAssignment = 281,
360         ShorthandPropertyAssignment = 282,
361         SpreadAssignment = 283,
362         EnumMember = 284,
363         UnparsedPrologue = 285,
364         UnparsedPrepend = 286,
365         UnparsedText = 287,
366         UnparsedInternalText = 288,
367         UnparsedSyntheticReference = 289,
368         SourceFile = 290,
369         Bundle = 291,
370         UnparsedSource = 292,
371         InputFiles = 293,
372         JSDocTypeExpression = 294,
373         JSDocAllType = 295,
374         JSDocUnknownType = 296,
375         JSDocNullableType = 297,
376         JSDocNonNullableType = 298,
377         JSDocOptionalType = 299,
378         JSDocFunctionType = 300,
379         JSDocVariadicType = 301,
380         JSDocNamepathType = 302,
381         JSDocComment = 303,
382         JSDocTypeLiteral = 304,
383         JSDocSignature = 305,
384         JSDocTag = 306,
385         JSDocAugmentsTag = 307,
386         JSDocImplementsTag = 308,
387         JSDocAuthorTag = 309,
388         JSDocClassTag = 310,
389         JSDocPublicTag = 311,
390         JSDocPrivateTag = 312,
391         JSDocProtectedTag = 313,
392         JSDocReadonlyTag = 314,
393         JSDocCallbackTag = 315,
394         JSDocEnumTag = 316,
395         JSDocParameterTag = 317,
396         JSDocReturnTag = 318,
397         JSDocThisTag = 319,
398         JSDocTypeTag = 320,
399         JSDocTemplateTag = 321,
400         JSDocTypedefTag = 322,
401         JSDocPropertyTag = 323,
402         SyntaxList = 324,
403         NotEmittedStatement = 325,
404         PartiallyEmittedExpression = 326,
405         CommaListExpression = 327,
406         MergeDeclarationMarker = 328,
407         EndOfDeclarationMarker = 329,
408         SyntheticReferenceExpression = 330,
409         Count = 331,
410         FirstAssignment = 62,
411         LastAssignment = 74,
412         FirstCompoundAssignment = 63,
413         LastCompoundAssignment = 74,
414         FirstReservedWord = 77,
415         LastReservedWord = 112,
416         FirstKeyword = 77,
417         LastKeyword = 152,
418         FirstFutureReservedWord = 113,
419         LastFutureReservedWord = 121,
420         FirstTypeNode = 168,
421         LastTypeNode = 188,
422         FirstPunctuation = 18,
423         LastPunctuation = 74,
424         FirstToken = 0,
425         LastToken = 152,
426         FirstTriviaToken = 2,
427         LastTriviaToken = 7,
428         FirstLiteralToken = 8,
429         LastLiteralToken = 14,
430         FirstTemplateToken = 14,
431         LastTemplateToken = 17,
432         FirstBinaryOperator = 29,
433         LastBinaryOperator = 74,
434         FirstStatement = 225,
435         LastStatement = 241,
436         FirstNode = 153,
437         FirstJSDocNode = 294,
438         LastJSDocNode = 323,
439         FirstJSDocTagNode = 306,
440         LastJSDocTagNode = 323,
441     }
442     export enum NodeFlags {
443         None = 0,
444         Let = 1,
445         Const = 2,
446         NestedNamespace = 4,
447         Synthesized = 8,
448         Namespace = 16,
449         OptionalChain = 32,
450         ExportContext = 64,
451         ContainsThis = 128,
452         HasImplicitReturn = 256,
453         HasExplicitReturn = 512,
454         GlobalAugmentation = 1024,
455         HasAsyncFunctions = 2048,
456         DisallowInContext = 4096,
457         YieldContext = 8192,
458         DecoratorContext = 16384,
459         AwaitContext = 32768,
460         ThisNodeHasError = 65536,
461         JavaScriptFile = 131072,
462         ThisNodeOrAnySubNodesHasError = 262144,
463         HasAggregatedChildData = 524288,
464         JSDoc = 4194304,
465         JsonFile = 33554432,
466         BlockScoped = 3,
467         ReachabilityCheckFlags = 768,
468         ReachabilityAndEmitFlags = 2816,
469         ContextFlags = 25358336,
470         TypeExcludesFlags = 40960,
471     }
472     export enum ModifierFlags {
473         None = 0,
474         Export = 1,
475         Ambient = 2,
476         Public = 4,
477         Private = 8,
478         Protected = 16,
479         Static = 32,
480         Readonly = 64,
481         Abstract = 128,
482         Async = 256,
483         Default = 512,
484         Const = 2048,
485         HasComputedFlags = 536870912,
486         AccessibilityModifier = 28,
487         ParameterPropertyModifier = 92,
488         NonPublicAccessibilityModifier = 24,
489         TypeScriptModifier = 2270,
490         ExportDefault = 513,
491         All = 3071
492     }
493     export enum JsxFlags {
494         None = 0,
495         /** An element from a named property of the JSX.IntrinsicElements interface */
496         IntrinsicNamedElement = 1,
497         /** An element inferred from the string index signature of the JSX.IntrinsicElements interface */
498         IntrinsicIndexedElement = 2,
499         IntrinsicElement = 3
500     }
501     export interface Node extends TextRange {
502         kind: SyntaxKind;
503         flags: NodeFlags;
504         decorators?: NodeArray<Decorator>;
505         modifiers?: ModifiersArray;
506         parent: Node;
507     }
508     export interface JSDocContainer {
509     }
510     export type HasJSDoc = ParameterDeclaration | CallSignatureDeclaration | ConstructSignatureDeclaration | MethodSignature | PropertySignature | ArrowFunction | ParenthesizedExpression | SpreadAssignment | ShorthandPropertyAssignment | PropertyAssignment | FunctionExpression | LabeledStatement | ExpressionStatement | VariableStatement | FunctionDeclaration | ConstructorDeclaration | MethodDeclaration | PropertyDeclaration | AccessorDeclaration | ClassLikeDeclaration | InterfaceDeclaration | TypeAliasDeclaration | EnumMember | EnumDeclaration | ModuleDeclaration | ImportEqualsDeclaration | IndexSignatureDeclaration | FunctionTypeNode | ConstructorTypeNode | JSDocFunctionType | ExportDeclaration | EndOfFileToken;
511     export type HasType = SignatureDeclaration | VariableDeclaration | ParameterDeclaration | PropertySignature | PropertyDeclaration | TypePredicateNode | ParenthesizedTypeNode | TypeOperatorNode | MappedTypeNode | AssertionExpression | TypeAliasDeclaration | JSDocTypeExpression | JSDocNonNullableType | JSDocNullableType | JSDocOptionalType | JSDocVariadicType;
512     export type HasTypeArguments = CallExpression | NewExpression | TaggedTemplateExpression | JsxOpeningElement | JsxSelfClosingElement;
513     export type HasInitializer = HasExpressionInitializer | ForStatement | ForInStatement | ForOfStatement | JsxAttribute;
514     export type HasExpressionInitializer = VariableDeclaration | ParameterDeclaration | BindingElement | PropertySignature | PropertyDeclaration | PropertyAssignment | EnumMember;
515     export interface NodeArray<T extends Node> extends ReadonlyArray<T>, TextRange {
516         hasTrailingComma?: boolean;
517     }
518     export interface Token<TKind extends SyntaxKind> extends Node {
519         kind: TKind;
520     }
521     export type DotToken = Token<SyntaxKind.DotToken>;
522     export type DotDotDotToken = Token<SyntaxKind.DotDotDotToken>;
523     export type QuestionToken = Token<SyntaxKind.QuestionToken>;
524     export type QuestionDotToken = Token<SyntaxKind.QuestionDotToken>;
525     export type ExclamationToken = Token<SyntaxKind.ExclamationToken>;
526     export type ColonToken = Token<SyntaxKind.ColonToken>;
527     export type EqualsToken = Token<SyntaxKind.EqualsToken>;
528     export type AsteriskToken = Token<SyntaxKind.AsteriskToken>;
529     export type EqualsGreaterThanToken = Token<SyntaxKind.EqualsGreaterThanToken>;
530     export type EndOfFileToken = Token<SyntaxKind.EndOfFileToken> & JSDocContainer;
531     export type ReadonlyToken = Token<SyntaxKind.ReadonlyKeyword>;
532     export type AwaitKeywordToken = Token<SyntaxKind.AwaitKeyword>;
533     export type PlusToken = Token<SyntaxKind.PlusToken>;
534     export type MinusToken = Token<SyntaxKind.MinusToken>;
535     export type AssertsToken = Token<SyntaxKind.AssertsKeyword>;
536     export type Modifier = Token<SyntaxKind.AbstractKeyword> | Token<SyntaxKind.AsyncKeyword> | Token<SyntaxKind.ConstKeyword> | Token<SyntaxKind.DeclareKeyword> | Token<SyntaxKind.DefaultKeyword> | Token<SyntaxKind.ExportKeyword> | Token<SyntaxKind.PublicKeyword> | Token<SyntaxKind.PrivateKeyword> | Token<SyntaxKind.ProtectedKeyword> | Token<SyntaxKind.ReadonlyKeyword> | Token<SyntaxKind.StaticKeyword>;
537     export type ModifiersArray = NodeArray<Modifier>;
538     export interface Identifier extends PrimaryExpression, Declaration {
539         kind: SyntaxKind.Identifier;
540         /**
541          * Prefer to use `id.unescapedText`. (Note: This is available only in services, not internally to the TypeScript compiler.)
542          * Text of identifier, but if the identifier begins with two underscores, this will begin with three.
543          */
544         escapedText: __String;
545         originalKeywordKind?: SyntaxKind;
546         isInJSDocNamespace?: boolean;
547     }
548     export interface TransientIdentifier extends Identifier {
549         resolvedSymbol: Symbol;
550     }
551     export interface QualifiedName extends Node {
552         kind: SyntaxKind.QualifiedName;
553         left: EntityName;
554         right: Identifier;
555     }
556     export type EntityName = Identifier | QualifiedName;
557     export type PropertyName = Identifier | StringLiteral | NumericLiteral | ComputedPropertyName | PrivateIdentifier;
558     export type DeclarationName = Identifier | PrivateIdentifier | StringLiteralLike | NumericLiteral | ComputedPropertyName | ElementAccessExpression | BindingPattern | EntityNameExpression;
559     export interface Declaration extends Node {
560         _declarationBrand: any;
561     }
562     export interface NamedDeclaration extends Declaration {
563         name?: DeclarationName;
564     }
565     export interface DeclarationStatement extends NamedDeclaration, Statement {
566         name?: Identifier | StringLiteral | NumericLiteral;
567     }
568     export interface ComputedPropertyName extends Node {
569         parent: Declaration;
570         kind: SyntaxKind.ComputedPropertyName;
571         expression: Expression;
572     }
573     export interface PrivateIdentifier extends Node {
574         kind: SyntaxKind.PrivateIdentifier;
575         escapedText: __String;
576     }
577     export interface Decorator extends Node {
578         kind: SyntaxKind.Decorator;
579         parent: NamedDeclaration;
580         expression: LeftHandSideExpression;
581     }
582     export interface TypeParameterDeclaration extends NamedDeclaration {
583         kind: SyntaxKind.TypeParameter;
584         parent: DeclarationWithTypeParameterChildren | InferTypeNode;
585         name: Identifier;
586         /** Note: Consider calling `getEffectiveConstraintOfTypeParameter` */
587         constraint?: TypeNode;
588         default?: TypeNode;
589         expression?: Expression;
590     }
591     export interface SignatureDeclarationBase extends NamedDeclaration, JSDocContainer {
592         kind: SignatureDeclaration["kind"];
593         name?: PropertyName;
594         typeParameters?: NodeArray<TypeParameterDeclaration>;
595         parameters: NodeArray<ParameterDeclaration>;
596         type?: TypeNode;
597     }
598     export type SignatureDeclaration = CallSignatureDeclaration | ConstructSignatureDeclaration | MethodSignature | IndexSignatureDeclaration | FunctionTypeNode | ConstructorTypeNode | JSDocFunctionType | FunctionDeclaration | MethodDeclaration | ConstructorDeclaration | AccessorDeclaration | FunctionExpression | ArrowFunction;
599     export interface CallSignatureDeclaration extends SignatureDeclarationBase, TypeElement {
600         kind: SyntaxKind.CallSignature;
601     }
602     export interface ConstructSignatureDeclaration extends SignatureDeclarationBase, TypeElement {
603         kind: SyntaxKind.ConstructSignature;
604     }
605     export type BindingName = Identifier | BindingPattern;
606     export interface VariableDeclaration extends NamedDeclaration {
607         kind: SyntaxKind.VariableDeclaration;
608         parent: VariableDeclarationList | CatchClause;
609         name: BindingName;
610         exclamationToken?: ExclamationToken;
611         type?: TypeNode;
612         initializer?: Expression;
613     }
614     export interface VariableDeclarationList extends Node {
615         kind: SyntaxKind.VariableDeclarationList;
616         parent: VariableStatement | ForStatement | ForOfStatement | ForInStatement;
617         declarations: NodeArray<VariableDeclaration>;
618     }
619     export interface ParameterDeclaration extends NamedDeclaration, JSDocContainer {
620         kind: SyntaxKind.Parameter;
621         parent: SignatureDeclaration;
622         dotDotDotToken?: DotDotDotToken;
623         name: BindingName;
624         questionToken?: QuestionToken;
625         type?: TypeNode;
626         initializer?: Expression;
627     }
628     export interface BindingElement extends NamedDeclaration {
629         kind: SyntaxKind.BindingElement;
630         parent: BindingPattern;
631         propertyName?: PropertyName;
632         dotDotDotToken?: DotDotDotToken;
633         name: BindingName;
634         initializer?: Expression;
635     }
636     export interface PropertySignature extends TypeElement, JSDocContainer {
637         kind: SyntaxKind.PropertySignature;
638         name: PropertyName;
639         questionToken?: QuestionToken;
640         type?: TypeNode;
641         initializer?: Expression;
642     }
643     export interface PropertyDeclaration extends ClassElement, JSDocContainer {
644         kind: SyntaxKind.PropertyDeclaration;
645         parent: ClassLikeDeclaration;
646         name: PropertyName;
647         questionToken?: QuestionToken;
648         exclamationToken?: ExclamationToken;
649         type?: TypeNode;
650         initializer?: Expression;
651     }
652     export interface ObjectLiteralElement extends NamedDeclaration {
653         _objectLiteralBrand: any;
654         name?: PropertyName;
655     }
656     /** Unlike ObjectLiteralElement, excludes JSXAttribute and JSXSpreadAttribute. */
657     export type ObjectLiteralElementLike = PropertyAssignment | ShorthandPropertyAssignment | SpreadAssignment | MethodDeclaration | AccessorDeclaration;
658     export interface PropertyAssignment extends ObjectLiteralElement, JSDocContainer {
659         parent: ObjectLiteralExpression;
660         kind: SyntaxKind.PropertyAssignment;
661         name: PropertyName;
662         questionToken?: QuestionToken;
663         initializer: Expression;
664     }
665     export interface ShorthandPropertyAssignment extends ObjectLiteralElement, JSDocContainer {
666         parent: ObjectLiteralExpression;
667         kind: SyntaxKind.ShorthandPropertyAssignment;
668         name: Identifier;
669         questionToken?: QuestionToken;
670         exclamationToken?: ExclamationToken;
671         equalsToken?: Token<SyntaxKind.EqualsToken>;
672         objectAssignmentInitializer?: Expression;
673     }
674     export interface SpreadAssignment extends ObjectLiteralElement, JSDocContainer {
675         parent: ObjectLiteralExpression;
676         kind: SyntaxKind.SpreadAssignment;
677         expression: Expression;
678     }
679     export type VariableLikeDeclaration = VariableDeclaration | ParameterDeclaration | BindingElement | PropertyDeclaration | PropertyAssignment | PropertySignature | JsxAttribute | ShorthandPropertyAssignment | EnumMember | JSDocPropertyTag | JSDocParameterTag;
680     export interface PropertyLikeDeclaration extends NamedDeclaration {
681         name: PropertyName;
682     }
683     export interface ObjectBindingPattern extends Node {
684         kind: SyntaxKind.ObjectBindingPattern;
685         parent: VariableDeclaration | ParameterDeclaration | BindingElement;
686         elements: NodeArray<BindingElement>;
687     }
688     export interface ArrayBindingPattern extends Node {
689         kind: SyntaxKind.ArrayBindingPattern;
690         parent: VariableDeclaration | ParameterDeclaration | BindingElement;
691         elements: NodeArray<ArrayBindingElement>;
692     }
693     export type BindingPattern = ObjectBindingPattern | ArrayBindingPattern;
694     export type ArrayBindingElement = BindingElement | OmittedExpression;
695     /**
696      * Several node kinds share function-like features such as a signature,
697      * a name, and a body. These nodes should extend FunctionLikeDeclarationBase.
698      * Examples:
699      * - FunctionDeclaration
700      * - MethodDeclaration
701      * - AccessorDeclaration
702      */
703     export interface FunctionLikeDeclarationBase extends SignatureDeclarationBase {
704         _functionLikeDeclarationBrand: any;
705         asteriskToken?: AsteriskToken;
706         questionToken?: QuestionToken;
707         exclamationToken?: ExclamationToken;
708         body?: Block | Expression;
709     }
710     export type FunctionLikeDeclaration = FunctionDeclaration | MethodDeclaration | GetAccessorDeclaration | SetAccessorDeclaration | ConstructorDeclaration | FunctionExpression | ArrowFunction;
711     /** @deprecated Use SignatureDeclaration */
712     export type FunctionLike = SignatureDeclaration;
713     export interface FunctionDeclaration extends FunctionLikeDeclarationBase, DeclarationStatement {
714         kind: SyntaxKind.FunctionDeclaration;
715         name?: Identifier;
716         body?: FunctionBody;
717     }
718     export interface MethodSignature extends SignatureDeclarationBase, TypeElement {
719         kind: SyntaxKind.MethodSignature;
720         parent: ObjectTypeDeclaration;
721         name: PropertyName;
722     }
723     export interface MethodDeclaration extends FunctionLikeDeclarationBase, ClassElement, ObjectLiteralElement, JSDocContainer {
724         kind: SyntaxKind.MethodDeclaration;
725         parent: ClassLikeDeclaration | ObjectLiteralExpression;
726         name: PropertyName;
727         body?: FunctionBody;
728     }
729     export interface ConstructorDeclaration extends FunctionLikeDeclarationBase, ClassElement, JSDocContainer {
730         kind: SyntaxKind.Constructor;
731         parent: ClassLikeDeclaration;
732         body?: FunctionBody;
733     }
734     /** For when we encounter a semicolon in a class declaration. ES6 allows these as class elements. */
735     export interface SemicolonClassElement extends ClassElement {
736         kind: SyntaxKind.SemicolonClassElement;
737         parent: ClassLikeDeclaration;
738     }
739     export interface GetAccessorDeclaration extends FunctionLikeDeclarationBase, ClassElement, ObjectLiteralElement, JSDocContainer {
740         kind: SyntaxKind.GetAccessor;
741         parent: ClassLikeDeclaration | ObjectLiteralExpression;
742         name: PropertyName;
743         body?: FunctionBody;
744     }
745     export interface SetAccessorDeclaration extends FunctionLikeDeclarationBase, ClassElement, ObjectLiteralElement, JSDocContainer {
746         kind: SyntaxKind.SetAccessor;
747         parent: ClassLikeDeclaration | ObjectLiteralExpression;
748         name: PropertyName;
749         body?: FunctionBody;
750     }
751     export type AccessorDeclaration = GetAccessorDeclaration | SetAccessorDeclaration;
752     export interface IndexSignatureDeclaration extends SignatureDeclarationBase, ClassElement, TypeElement {
753         kind: SyntaxKind.IndexSignature;
754         parent: ObjectTypeDeclaration;
755     }
756     export interface TypeNode extends Node {
757         _typeNodeBrand: any;
758     }
759     export interface KeywordTypeNode extends TypeNode {
760         kind: SyntaxKind.AnyKeyword | SyntaxKind.UnknownKeyword | SyntaxKind.NumberKeyword | SyntaxKind.BigIntKeyword | SyntaxKind.ObjectKeyword | SyntaxKind.BooleanKeyword | SyntaxKind.StringKeyword | SyntaxKind.SymbolKeyword | SyntaxKind.ThisKeyword | SyntaxKind.VoidKeyword | SyntaxKind.UndefinedKeyword | SyntaxKind.NullKeyword | SyntaxKind.NeverKeyword;
761     }
762     export interface ImportTypeNode extends NodeWithTypeArguments {
763         kind: SyntaxKind.ImportType;
764         isTypeOf?: boolean;
765         argument: TypeNode;
766         qualifier?: EntityName;
767     }
768     export interface ThisTypeNode extends TypeNode {
769         kind: SyntaxKind.ThisType;
770     }
771     export type FunctionOrConstructorTypeNode = FunctionTypeNode | ConstructorTypeNode;
772     export interface FunctionOrConstructorTypeNodeBase extends TypeNode, SignatureDeclarationBase {
773         kind: SyntaxKind.FunctionType | SyntaxKind.ConstructorType;
774         type: TypeNode;
775     }
776     export interface FunctionTypeNode extends FunctionOrConstructorTypeNodeBase {
777         kind: SyntaxKind.FunctionType;
778     }
779     export interface ConstructorTypeNode extends FunctionOrConstructorTypeNodeBase {
780         kind: SyntaxKind.ConstructorType;
781     }
782     export interface NodeWithTypeArguments extends TypeNode {
783         typeArguments?: NodeArray<TypeNode>;
784     }
785     export type TypeReferenceType = TypeReferenceNode | ExpressionWithTypeArguments;
786     export interface TypeReferenceNode extends NodeWithTypeArguments {
787         kind: SyntaxKind.TypeReference;
788         typeName: EntityName;
789     }
790     export interface TypePredicateNode extends TypeNode {
791         kind: SyntaxKind.TypePredicate;
792         parent: SignatureDeclaration | JSDocTypeExpression;
793         assertsModifier?: AssertsToken;
794         parameterName: Identifier | ThisTypeNode;
795         type?: TypeNode;
796     }
797     export interface TypeQueryNode extends TypeNode {
798         kind: SyntaxKind.TypeQuery;
799         exprName: EntityName;
800     }
801     export interface TypeLiteralNode extends TypeNode, Declaration {
802         kind: SyntaxKind.TypeLiteral;
803         members: NodeArray<TypeElement>;
804     }
805     export interface ArrayTypeNode extends TypeNode {
806         kind: SyntaxKind.ArrayType;
807         elementType: TypeNode;
808     }
809     export interface TupleTypeNode extends TypeNode {
810         kind: SyntaxKind.TupleType;
811         elementTypes: NodeArray<TypeNode>;
812     }
813     export interface OptionalTypeNode extends TypeNode {
814         kind: SyntaxKind.OptionalType;
815         type: TypeNode;
816     }
817     export interface RestTypeNode extends TypeNode {
818         kind: SyntaxKind.RestType;
819         type: TypeNode;
820     }
821     export type UnionOrIntersectionTypeNode = UnionTypeNode | IntersectionTypeNode;
822     export interface UnionTypeNode extends TypeNode {
823         kind: SyntaxKind.UnionType;
824         types: NodeArray<TypeNode>;
825     }
826     export interface IntersectionTypeNode extends TypeNode {
827         kind: SyntaxKind.IntersectionType;
828         types: NodeArray<TypeNode>;
829     }
830     export interface ConditionalTypeNode extends TypeNode {
831         kind: SyntaxKind.ConditionalType;
832         checkType: TypeNode;
833         extendsType: TypeNode;
834         trueType: TypeNode;
835         falseType: TypeNode;
836     }
837     export interface InferTypeNode extends TypeNode {
838         kind: SyntaxKind.InferType;
839         typeParameter: TypeParameterDeclaration;
840     }
841     export interface ParenthesizedTypeNode extends TypeNode {
842         kind: SyntaxKind.ParenthesizedType;
843         type: TypeNode;
844     }
845     export interface TypeOperatorNode extends TypeNode {
846         kind: SyntaxKind.TypeOperator;
847         operator: SyntaxKind.KeyOfKeyword | SyntaxKind.UniqueKeyword | SyntaxKind.ReadonlyKeyword;
848         type: TypeNode;
849     }
850     export interface IndexedAccessTypeNode extends TypeNode {
851         kind: SyntaxKind.IndexedAccessType;
852         objectType: TypeNode;
853         indexType: TypeNode;
854     }
855     export interface MappedTypeNode extends TypeNode, Declaration {
856         kind: SyntaxKind.MappedType;
857         readonlyToken?: ReadonlyToken | PlusToken | MinusToken;
858         typeParameter: TypeParameterDeclaration;
859         questionToken?: QuestionToken | PlusToken | MinusToken;
860         type?: TypeNode;
861     }
862     export interface LiteralTypeNode extends TypeNode {
863         kind: SyntaxKind.LiteralType;
864         literal: BooleanLiteral | LiteralExpression | PrefixUnaryExpression;
865     }
866     export interface StringLiteral extends LiteralExpression, Declaration {
867         kind: SyntaxKind.StringLiteral;
868     }
869     export type StringLiteralLike = StringLiteral | NoSubstitutionTemplateLiteral;
870     export interface Expression extends Node {
871         _expressionBrand: any;
872     }
873     export interface OmittedExpression extends Expression {
874         kind: SyntaxKind.OmittedExpression;
875     }
876     export interface PartiallyEmittedExpression extends LeftHandSideExpression {
877         kind: SyntaxKind.PartiallyEmittedExpression;
878         expression: Expression;
879     }
880     export interface UnaryExpression extends Expression {
881         _unaryExpressionBrand: any;
882     }
883     /** Deprecated, please use UpdateExpression */
884     export type IncrementExpression = UpdateExpression;
885     export interface UpdateExpression extends UnaryExpression {
886         _updateExpressionBrand: any;
887     }
888     export type PrefixUnaryOperator = SyntaxKind.PlusPlusToken | SyntaxKind.MinusMinusToken | SyntaxKind.PlusToken | SyntaxKind.MinusToken | SyntaxKind.TildeToken | SyntaxKind.ExclamationToken;
889     export interface PrefixUnaryExpression extends UpdateExpression {
890         kind: SyntaxKind.PrefixUnaryExpression;
891         operator: PrefixUnaryOperator;
892         operand: UnaryExpression;
893     }
894     export type PostfixUnaryOperator = SyntaxKind.PlusPlusToken | SyntaxKind.MinusMinusToken;
895     export interface PostfixUnaryExpression extends UpdateExpression {
896         kind: SyntaxKind.PostfixUnaryExpression;
897         operand: LeftHandSideExpression;
898         operator: PostfixUnaryOperator;
899     }
900     export interface LeftHandSideExpression extends UpdateExpression {
901         _leftHandSideExpressionBrand: any;
902     }
903     export interface MemberExpression extends LeftHandSideExpression {
904         _memberExpressionBrand: any;
905     }
906     export interface PrimaryExpression extends MemberExpression {
907         _primaryExpressionBrand: any;
908     }
909     export interface NullLiteral extends PrimaryExpression, TypeNode {
910         kind: SyntaxKind.NullKeyword;
911     }
912     export interface BooleanLiteral extends PrimaryExpression, TypeNode {
913         kind: SyntaxKind.TrueKeyword | SyntaxKind.FalseKeyword;
914     }
915     export interface ThisExpression extends PrimaryExpression, KeywordTypeNode {
916         kind: SyntaxKind.ThisKeyword;
917     }
918     export interface SuperExpression extends PrimaryExpression {
919         kind: SyntaxKind.SuperKeyword;
920     }
921     export interface ImportExpression extends PrimaryExpression {
922         kind: SyntaxKind.ImportKeyword;
923     }
924     export interface DeleteExpression extends UnaryExpression {
925         kind: SyntaxKind.DeleteExpression;
926         expression: UnaryExpression;
927     }
928     export interface TypeOfExpression extends UnaryExpression {
929         kind: SyntaxKind.TypeOfExpression;
930         expression: UnaryExpression;
931     }
932     export interface VoidExpression extends UnaryExpression {
933         kind: SyntaxKind.VoidExpression;
934         expression: UnaryExpression;
935     }
936     export interface AwaitExpression extends UnaryExpression {
937         kind: SyntaxKind.AwaitExpression;
938         expression: UnaryExpression;
939     }
940     export interface YieldExpression extends Expression {
941         kind: SyntaxKind.YieldExpression;
942         asteriskToken?: AsteriskToken;
943         expression?: Expression;
944     }
945     export interface SyntheticExpression extends Expression {
946         kind: SyntaxKind.SyntheticExpression;
947         isSpread: boolean;
948         type: Type;
949     }
950     export type ExponentiationOperator = SyntaxKind.AsteriskAsteriskToken;
951     export type MultiplicativeOperator = SyntaxKind.AsteriskToken | SyntaxKind.SlashToken | SyntaxKind.PercentToken;
952     export type MultiplicativeOperatorOrHigher = ExponentiationOperator | MultiplicativeOperator;
953     export type AdditiveOperator = SyntaxKind.PlusToken | SyntaxKind.MinusToken;
954     export type AdditiveOperatorOrHigher = MultiplicativeOperatorOrHigher | AdditiveOperator;
955     export type ShiftOperator = SyntaxKind.LessThanLessThanToken | SyntaxKind.GreaterThanGreaterThanToken | SyntaxKind.GreaterThanGreaterThanGreaterThanToken;
956     export type ShiftOperatorOrHigher = AdditiveOperatorOrHigher | ShiftOperator;
957     export type RelationalOperator = SyntaxKind.LessThanToken | SyntaxKind.LessThanEqualsToken | SyntaxKind.GreaterThanToken | SyntaxKind.GreaterThanEqualsToken | SyntaxKind.InstanceOfKeyword | SyntaxKind.InKeyword;
958     export type RelationalOperatorOrHigher = ShiftOperatorOrHigher | RelationalOperator;
959     export type EqualityOperator = SyntaxKind.EqualsEqualsToken | SyntaxKind.EqualsEqualsEqualsToken | SyntaxKind.ExclamationEqualsEqualsToken | SyntaxKind.ExclamationEqualsToken;
960     export type EqualityOperatorOrHigher = RelationalOperatorOrHigher | EqualityOperator;
961     export type BitwiseOperator = SyntaxKind.AmpersandToken | SyntaxKind.BarToken | SyntaxKind.CaretToken;
962     export type BitwiseOperatorOrHigher = EqualityOperatorOrHigher | BitwiseOperator;
963     export type LogicalOperator = SyntaxKind.AmpersandAmpersandToken | SyntaxKind.BarBarToken;
964     export type LogicalOperatorOrHigher = BitwiseOperatorOrHigher | LogicalOperator;
965     export type CompoundAssignmentOperator = SyntaxKind.PlusEqualsToken | SyntaxKind.MinusEqualsToken | SyntaxKind.AsteriskAsteriskEqualsToken | SyntaxKind.AsteriskEqualsToken | SyntaxKind.SlashEqualsToken | SyntaxKind.PercentEqualsToken | SyntaxKind.AmpersandEqualsToken | SyntaxKind.BarEqualsToken | SyntaxKind.CaretEqualsToken | SyntaxKind.LessThanLessThanEqualsToken | SyntaxKind.GreaterThanGreaterThanGreaterThanEqualsToken | SyntaxKind.GreaterThanGreaterThanEqualsToken;
966     export type AssignmentOperator = SyntaxKind.EqualsToken | CompoundAssignmentOperator;
967     export type AssignmentOperatorOrHigher = SyntaxKind.QuestionQuestionToken | LogicalOperatorOrHigher | AssignmentOperator;
968     export type BinaryOperator = AssignmentOperatorOrHigher | SyntaxKind.CommaToken;
969     export type BinaryOperatorToken = Token<BinaryOperator>;
970     export interface BinaryExpression extends Expression, Declaration {
971         kind: SyntaxKind.BinaryExpression;
972         left: Expression;
973         operatorToken: BinaryOperatorToken;
974         right: Expression;
975     }
976     export type AssignmentOperatorToken = Token<AssignmentOperator>;
977     export interface AssignmentExpression<TOperator extends AssignmentOperatorToken> extends BinaryExpression {
978         left: LeftHandSideExpression;
979         operatorToken: TOperator;
980     }
981     export interface ObjectDestructuringAssignment extends AssignmentExpression<EqualsToken> {
982         left: ObjectLiteralExpression;
983     }
984     export interface ArrayDestructuringAssignment extends AssignmentExpression<EqualsToken> {
985         left: ArrayLiteralExpression;
986     }
987     export type DestructuringAssignment = ObjectDestructuringAssignment | ArrayDestructuringAssignment;
988     export type BindingOrAssignmentElement = VariableDeclaration | ParameterDeclaration | BindingElement | PropertyAssignment | ShorthandPropertyAssignment | SpreadAssignment | OmittedExpression | SpreadElement | ArrayLiteralExpression | ObjectLiteralExpression | AssignmentExpression<EqualsToken> | Identifier | PropertyAccessExpression | ElementAccessExpression;
989     export type BindingOrAssignmentElementRestIndicator = DotDotDotToken | SpreadElement | SpreadAssignment;
990     export type BindingOrAssignmentElementTarget = BindingOrAssignmentPattern | Identifier | PropertyAccessExpression | ElementAccessExpression | OmittedExpression;
991     export type ObjectBindingOrAssignmentPattern = ObjectBindingPattern | ObjectLiteralExpression;
992     export type ArrayBindingOrAssignmentPattern = ArrayBindingPattern | ArrayLiteralExpression;
993     export type AssignmentPattern = ObjectLiteralExpression | ArrayLiteralExpression;
994     export type BindingOrAssignmentPattern = ObjectBindingOrAssignmentPattern | ArrayBindingOrAssignmentPattern;
995     export interface ConditionalExpression extends Expression {
996         kind: SyntaxKind.ConditionalExpression;
997         condition: Expression;
998         questionToken: QuestionToken;
999         whenTrue: Expression;
1000         colonToken: ColonToken;
1001         whenFalse: Expression;
1002     }
1003     export type FunctionBody = Block;
1004     export type ConciseBody = FunctionBody | Expression;
1005     export interface FunctionExpression extends PrimaryExpression, FunctionLikeDeclarationBase, JSDocContainer {
1006         kind: SyntaxKind.FunctionExpression;
1007         name?: Identifier;
1008         body: FunctionBody;
1009     }
1010     export interface ArrowFunction extends Expression, FunctionLikeDeclarationBase, JSDocContainer {
1011         kind: SyntaxKind.ArrowFunction;
1012         equalsGreaterThanToken: EqualsGreaterThanToken;
1013         body: ConciseBody;
1014         name: never;
1015     }
1016     export interface LiteralLikeNode extends Node {
1017         text: string;
1018         isUnterminated?: boolean;
1019         hasExtendedUnicodeEscape?: boolean;
1020     }
1021     export interface TemplateLiteralLikeNode extends LiteralLikeNode {
1022         rawText?: string;
1023     }
1024     export interface LiteralExpression extends LiteralLikeNode, PrimaryExpression {
1025         _literalExpressionBrand: any;
1026     }
1027     export interface RegularExpressionLiteral extends LiteralExpression {
1028         kind: SyntaxKind.RegularExpressionLiteral;
1029     }
1030     export interface NoSubstitutionTemplateLiteral extends LiteralExpression, TemplateLiteralLikeNode, Declaration {
1031         kind: SyntaxKind.NoSubstitutionTemplateLiteral;
1032     }
1033     export enum TokenFlags {
1034         None = 0,
1035         Scientific = 16,
1036         Octal = 32,
1037         HexSpecifier = 64,
1038         BinarySpecifier = 128,
1039         OctalSpecifier = 256,
1040     }
1041     export interface NumericLiteral extends LiteralExpression, Declaration {
1042         kind: SyntaxKind.NumericLiteral;
1043     }
1044     export interface BigIntLiteral extends LiteralExpression {
1045         kind: SyntaxKind.BigIntLiteral;
1046     }
1047     export interface TemplateHead extends TemplateLiteralLikeNode {
1048         kind: SyntaxKind.TemplateHead;
1049         parent: TemplateExpression;
1050     }
1051     export interface TemplateMiddle extends TemplateLiteralLikeNode {
1052         kind: SyntaxKind.TemplateMiddle;
1053         parent: TemplateSpan;
1054     }
1055     export interface TemplateTail extends TemplateLiteralLikeNode {
1056         kind: SyntaxKind.TemplateTail;
1057         parent: TemplateSpan;
1058     }
1059     export type TemplateLiteral = TemplateExpression | NoSubstitutionTemplateLiteral;
1060     export interface TemplateExpression extends PrimaryExpression {
1061         kind: SyntaxKind.TemplateExpression;
1062         head: TemplateHead;
1063         templateSpans: NodeArray<TemplateSpan>;
1064     }
1065     export interface TemplateSpan extends Node {
1066         kind: SyntaxKind.TemplateSpan;
1067         parent: TemplateExpression;
1068         expression: Expression;
1069         literal: TemplateMiddle | TemplateTail;
1070     }
1071     export interface ParenthesizedExpression extends PrimaryExpression, JSDocContainer {
1072         kind: SyntaxKind.ParenthesizedExpression;
1073         expression: Expression;
1074     }
1075     export interface ArrayLiteralExpression extends PrimaryExpression {
1076         kind: SyntaxKind.ArrayLiteralExpression;
1077         elements: NodeArray<Expression>;
1078     }
1079     export interface SpreadElement extends Expression {
1080         kind: SyntaxKind.SpreadElement;
1081         parent: ArrayLiteralExpression | CallExpression | NewExpression;
1082         expression: Expression;
1083     }
1084     /**
1085      * This interface is a base interface for ObjectLiteralExpression and JSXAttributes to extend from. JSXAttributes is similar to
1086      * ObjectLiteralExpression in that it contains array of properties; however, JSXAttributes' properties can only be
1087      * JSXAttribute or JSXSpreadAttribute. ObjectLiteralExpression, on the other hand, can only have properties of type
1088      * ObjectLiteralElement (e.g. PropertyAssignment, ShorthandPropertyAssignment etc.)
1089      */
1090     export interface ObjectLiteralExpressionBase<T extends ObjectLiteralElement> extends PrimaryExpression, Declaration {
1091         properties: NodeArray<T>;
1092     }
1093     export interface ObjectLiteralExpression extends ObjectLiteralExpressionBase<ObjectLiteralElementLike> {
1094         kind: SyntaxKind.ObjectLiteralExpression;
1095     }
1096     export type EntityNameExpression = Identifier | PropertyAccessEntityNameExpression;
1097     export type EntityNameOrEntityNameExpression = EntityName | EntityNameExpression;
1098     export interface PropertyAccessExpression extends MemberExpression, NamedDeclaration {
1099         kind: SyntaxKind.PropertyAccessExpression;
1100         expression: LeftHandSideExpression;
1101         questionDotToken?: QuestionDotToken;
1102         name: Identifier | PrivateIdentifier;
1103     }
1104     export interface PropertyAccessChain extends PropertyAccessExpression {
1105         _optionalChainBrand: any;
1106         name: Identifier;
1107     }
1108     export interface SuperPropertyAccessExpression extends PropertyAccessExpression {
1109         expression: SuperExpression;
1110     }
1111     /** Brand for a PropertyAccessExpression which, like a QualifiedName, consists of a sequence of identifiers separated by dots. */
1112     export interface PropertyAccessEntityNameExpression extends PropertyAccessExpression {
1113         _propertyAccessExpressionLikeQualifiedNameBrand?: any;
1114         expression: EntityNameExpression;
1115         name: Identifier;
1116     }
1117     export interface ElementAccessExpression extends MemberExpression {
1118         kind: SyntaxKind.ElementAccessExpression;
1119         expression: LeftHandSideExpression;
1120         questionDotToken?: QuestionDotToken;
1121         argumentExpression: Expression;
1122     }
1123     export interface ElementAccessChain extends ElementAccessExpression {
1124         _optionalChainBrand: any;
1125     }
1126     export interface SuperElementAccessExpression extends ElementAccessExpression {
1127         expression: SuperExpression;
1128     }
1129     export type SuperProperty = SuperPropertyAccessExpression | SuperElementAccessExpression;
1130     export interface CallExpression extends LeftHandSideExpression, Declaration {
1131         kind: SyntaxKind.CallExpression;
1132         expression: LeftHandSideExpression;
1133         questionDotToken?: QuestionDotToken;
1134         typeArguments?: NodeArray<TypeNode>;
1135         arguments: NodeArray<Expression>;
1136     }
1137     export interface CallChain extends CallExpression {
1138         _optionalChainBrand: any;
1139     }
1140     export type OptionalChain = PropertyAccessChain | ElementAccessChain | CallChain | NonNullChain;
1141     export interface SuperCall extends CallExpression {
1142         expression: SuperExpression;
1143     }
1144     export interface ImportCall extends CallExpression {
1145         expression: ImportExpression;
1146     }
1147     export interface ExpressionWithTypeArguments extends NodeWithTypeArguments {
1148         kind: SyntaxKind.ExpressionWithTypeArguments;
1149         parent: HeritageClause | JSDocAugmentsTag | JSDocImplementsTag;
1150         expression: LeftHandSideExpression;
1151     }
1152     export interface NewExpression extends PrimaryExpression, Declaration {
1153         kind: SyntaxKind.NewExpression;
1154         expression: LeftHandSideExpression;
1155         typeArguments?: NodeArray<TypeNode>;
1156         arguments?: NodeArray<Expression>;
1157     }
1158     export interface TaggedTemplateExpression extends MemberExpression {
1159         kind: SyntaxKind.TaggedTemplateExpression;
1160         tag: LeftHandSideExpression;
1161         typeArguments?: NodeArray<TypeNode>;
1162         template: TemplateLiteral;
1163     }
1164     export type CallLikeExpression = CallExpression | NewExpression | TaggedTemplateExpression | Decorator | JsxOpeningLikeElement;
1165     export interface AsExpression extends Expression {
1166         kind: SyntaxKind.AsExpression;
1167         expression: Expression;
1168         type: TypeNode;
1169     }
1170     export interface TypeAssertion extends UnaryExpression {
1171         kind: SyntaxKind.TypeAssertionExpression;
1172         type: TypeNode;
1173         expression: UnaryExpression;
1174     }
1175     export type AssertionExpression = TypeAssertion | AsExpression;
1176     export interface NonNullExpression extends LeftHandSideExpression {
1177         kind: SyntaxKind.NonNullExpression;
1178         expression: Expression;
1179     }
1180     export interface NonNullChain extends NonNullExpression {
1181         _optionalChainBrand: any;
1182     }
1183     export interface MetaProperty extends PrimaryExpression {
1184         kind: SyntaxKind.MetaProperty;
1185         keywordToken: SyntaxKind.NewKeyword | SyntaxKind.ImportKeyword;
1186         name: Identifier;
1187     }
1188     export interface JsxElement extends PrimaryExpression {
1189         kind: SyntaxKind.JsxElement;
1190         openingElement: JsxOpeningElement;
1191         children: NodeArray<JsxChild>;
1192         closingElement: JsxClosingElement;
1193     }
1194     export type JsxOpeningLikeElement = JsxSelfClosingElement | JsxOpeningElement;
1195     export type JsxAttributeLike = JsxAttribute | JsxSpreadAttribute;
1196     export type JsxTagNameExpression = Identifier | ThisExpression | JsxTagNamePropertyAccess;
1197     export interface JsxTagNamePropertyAccess extends PropertyAccessExpression {
1198         expression: JsxTagNameExpression;
1199     }
1200     export interface JsxAttributes extends ObjectLiteralExpressionBase<JsxAttributeLike> {
1201         kind: SyntaxKind.JsxAttributes;
1202         parent: JsxOpeningLikeElement;
1203     }
1204     export interface JsxOpeningElement extends Expression {
1205         kind: SyntaxKind.JsxOpeningElement;
1206         parent: JsxElement;
1207         tagName: JsxTagNameExpression;
1208         typeArguments?: NodeArray<TypeNode>;
1209         attributes: JsxAttributes;
1210     }
1211     export interface JsxSelfClosingElement extends PrimaryExpression {
1212         kind: SyntaxKind.JsxSelfClosingElement;
1213         tagName: JsxTagNameExpression;
1214         typeArguments?: NodeArray<TypeNode>;
1215         attributes: JsxAttributes;
1216     }
1217     export interface JsxFragment extends PrimaryExpression {
1218         kind: SyntaxKind.JsxFragment;
1219         openingFragment: JsxOpeningFragment;
1220         children: NodeArray<JsxChild>;
1221         closingFragment: JsxClosingFragment;
1222     }
1223     export interface JsxOpeningFragment extends Expression {
1224         kind: SyntaxKind.JsxOpeningFragment;
1225         parent: JsxFragment;
1226     }
1227     export interface JsxClosingFragment extends Expression {
1228         kind: SyntaxKind.JsxClosingFragment;
1229         parent: JsxFragment;
1230     }
1231     export interface JsxAttribute extends ObjectLiteralElement {
1232         kind: SyntaxKind.JsxAttribute;
1233         parent: JsxAttributes;
1234         name: Identifier;
1235         initializer?: StringLiteral | JsxExpression;
1236     }
1237     export interface JsxSpreadAttribute extends ObjectLiteralElement {
1238         kind: SyntaxKind.JsxSpreadAttribute;
1239         parent: JsxAttributes;
1240         expression: Expression;
1241     }
1242     export interface JsxClosingElement extends Node {
1243         kind: SyntaxKind.JsxClosingElement;
1244         parent: JsxElement;
1245         tagName: JsxTagNameExpression;
1246     }
1247     export interface JsxExpression extends Expression {
1248         kind: SyntaxKind.JsxExpression;
1249         parent: JsxElement | JsxAttributeLike;
1250         dotDotDotToken?: Token<SyntaxKind.DotDotDotToken>;
1251         expression?: Expression;
1252     }
1253     export interface JsxText extends LiteralLikeNode {
1254         kind: SyntaxKind.JsxText;
1255         containsOnlyTriviaWhiteSpaces: boolean;
1256         parent: JsxElement;
1257     }
1258     export type JsxChild = JsxText | JsxExpression | JsxElement | JsxSelfClosingElement | JsxFragment;
1259     export interface Statement extends Node {
1260         _statementBrand: any;
1261     }
1262     export interface NotEmittedStatement extends Statement {
1263         kind: SyntaxKind.NotEmittedStatement;
1264     }
1265     /**
1266      * A list of comma-separated expressions. This node is only created by transformations.
1267      */
1268     export interface CommaListExpression extends Expression {
1269         kind: SyntaxKind.CommaListExpression;
1270         elements: NodeArray<Expression>;
1271     }
1272     export interface EmptyStatement extends Statement {
1273         kind: SyntaxKind.EmptyStatement;
1274     }
1275     export interface DebuggerStatement extends Statement {
1276         kind: SyntaxKind.DebuggerStatement;
1277     }
1278     export interface MissingDeclaration extends DeclarationStatement {
1279         kind: SyntaxKind.MissingDeclaration;
1280         name?: Identifier;
1281     }
1282     export type BlockLike = SourceFile | Block | ModuleBlock | CaseOrDefaultClause;
1283     export interface Block extends Statement {
1284         kind: SyntaxKind.Block;
1285         statements: NodeArray<Statement>;
1286     }
1287     export interface VariableStatement extends Statement, JSDocContainer {
1288         kind: SyntaxKind.VariableStatement;
1289         declarationList: VariableDeclarationList;
1290     }
1291     export interface ExpressionStatement extends Statement, JSDocContainer {
1292         kind: SyntaxKind.ExpressionStatement;
1293         expression: Expression;
1294     }
1295     export interface IfStatement extends Statement {
1296         kind: SyntaxKind.IfStatement;
1297         expression: Expression;
1298         thenStatement: Statement;
1299         elseStatement?: Statement;
1300     }
1301     export interface IterationStatement extends Statement {
1302         statement: Statement;
1303     }
1304     export interface DoStatement extends IterationStatement {
1305         kind: SyntaxKind.DoStatement;
1306         expression: Expression;
1307     }
1308     export interface WhileStatement extends IterationStatement {
1309         kind: SyntaxKind.WhileStatement;
1310         expression: Expression;
1311     }
1312     export type ForInitializer = VariableDeclarationList | Expression;
1313     export interface ForStatement extends IterationStatement {
1314         kind: SyntaxKind.ForStatement;
1315         initializer?: ForInitializer;
1316         condition?: Expression;
1317         incrementor?: Expression;
1318     }
1319     export type ForInOrOfStatement = ForInStatement | ForOfStatement;
1320     export interface ForInStatement extends IterationStatement {
1321         kind: SyntaxKind.ForInStatement;
1322         initializer: ForInitializer;
1323         expression: Expression;
1324     }
1325     export interface ForOfStatement extends IterationStatement {
1326         kind: SyntaxKind.ForOfStatement;
1327         awaitModifier?: AwaitKeywordToken;
1328         initializer: ForInitializer;
1329         expression: Expression;
1330     }
1331     export interface BreakStatement extends Statement {
1332         kind: SyntaxKind.BreakStatement;
1333         label?: Identifier;
1334     }
1335     export interface ContinueStatement extends Statement {
1336         kind: SyntaxKind.ContinueStatement;
1337         label?: Identifier;
1338     }
1339     export type BreakOrContinueStatement = BreakStatement | ContinueStatement;
1340     export interface ReturnStatement extends Statement {
1341         kind: SyntaxKind.ReturnStatement;
1342         expression?: Expression;
1343     }
1344     export interface WithStatement extends Statement {
1345         kind: SyntaxKind.WithStatement;
1346         expression: Expression;
1347         statement: Statement;
1348     }
1349     export interface SwitchStatement extends Statement {
1350         kind: SyntaxKind.SwitchStatement;
1351         expression: Expression;
1352         caseBlock: CaseBlock;
1353         possiblyExhaustive?: boolean;
1354     }
1355     export interface CaseBlock extends Node {
1356         kind: SyntaxKind.CaseBlock;
1357         parent: SwitchStatement;
1358         clauses: NodeArray<CaseOrDefaultClause>;
1359     }
1360     export interface CaseClause extends Node {
1361         kind: SyntaxKind.CaseClause;
1362         parent: CaseBlock;
1363         expression: Expression;
1364         statements: NodeArray<Statement>;
1365     }
1366     export interface DefaultClause extends Node {
1367         kind: SyntaxKind.DefaultClause;
1368         parent: CaseBlock;
1369         statements: NodeArray<Statement>;
1370     }
1371     export type CaseOrDefaultClause = CaseClause | DefaultClause;
1372     export interface LabeledStatement extends Statement, JSDocContainer {
1373         kind: SyntaxKind.LabeledStatement;
1374         label: Identifier;
1375         statement: Statement;
1376     }
1377     export interface ThrowStatement extends Statement {
1378         kind: SyntaxKind.ThrowStatement;
1379         expression?: Expression;
1380     }
1381     export interface TryStatement extends Statement {
1382         kind: SyntaxKind.TryStatement;
1383         tryBlock: Block;
1384         catchClause?: CatchClause;
1385         finallyBlock?: Block;
1386     }
1387     export interface CatchClause extends Node {
1388         kind: SyntaxKind.CatchClause;
1389         parent: TryStatement;
1390         variableDeclaration?: VariableDeclaration;
1391         block: Block;
1392     }
1393     export type ObjectTypeDeclaration = ClassLikeDeclaration | InterfaceDeclaration | TypeLiteralNode;
1394     export type DeclarationWithTypeParameters = DeclarationWithTypeParameterChildren | JSDocTypedefTag | JSDocCallbackTag | JSDocSignature;
1395     export type DeclarationWithTypeParameterChildren = SignatureDeclaration | ClassLikeDeclaration | InterfaceDeclaration | TypeAliasDeclaration | JSDocTemplateTag;
1396     export interface ClassLikeDeclarationBase extends NamedDeclaration, JSDocContainer {
1397         kind: SyntaxKind.ClassDeclaration | SyntaxKind.ClassExpression;
1398         name?: Identifier;
1399         typeParameters?: NodeArray<TypeParameterDeclaration>;
1400         heritageClauses?: NodeArray<HeritageClause>;
1401         members: NodeArray<ClassElement>;
1402     }
1403     export interface ClassDeclaration extends ClassLikeDeclarationBase, DeclarationStatement {
1404         kind: SyntaxKind.ClassDeclaration;
1405         /** May be undefined in `export default class { ... }`. */
1406         name?: Identifier;
1407     }
1408     export interface ClassExpression extends ClassLikeDeclarationBase, PrimaryExpression {
1409         kind: SyntaxKind.ClassExpression;
1410     }
1411     export type ClassLikeDeclaration = ClassDeclaration | ClassExpression;
1412     export interface ClassElement extends NamedDeclaration {
1413         _classElementBrand: any;
1414         name?: PropertyName;
1415     }
1416     export interface TypeElement extends NamedDeclaration {
1417         _typeElementBrand: any;
1418         name?: PropertyName;
1419         questionToken?: QuestionToken;
1420     }
1421     export interface InterfaceDeclaration extends DeclarationStatement, JSDocContainer {
1422         kind: SyntaxKind.InterfaceDeclaration;
1423         name: Identifier;
1424         typeParameters?: NodeArray<TypeParameterDeclaration>;
1425         heritageClauses?: NodeArray<HeritageClause>;
1426         members: NodeArray<TypeElement>;
1427     }
1428     export interface HeritageClause extends Node {
1429         kind: SyntaxKind.HeritageClause;
1430         parent: InterfaceDeclaration | ClassLikeDeclaration;
1431         token: SyntaxKind.ExtendsKeyword | SyntaxKind.ImplementsKeyword;
1432         types: NodeArray<ExpressionWithTypeArguments>;
1433     }
1434     export interface TypeAliasDeclaration extends DeclarationStatement, JSDocContainer {
1435         kind: SyntaxKind.TypeAliasDeclaration;
1436         name: Identifier;
1437         typeParameters?: NodeArray<TypeParameterDeclaration>;
1438         type: TypeNode;
1439     }
1440     export interface EnumMember extends NamedDeclaration, JSDocContainer {
1441         kind: SyntaxKind.EnumMember;
1442         parent: EnumDeclaration;
1443         name: PropertyName;
1444         initializer?: Expression;
1445     }
1446     export interface EnumDeclaration extends DeclarationStatement, JSDocContainer {
1447         kind: SyntaxKind.EnumDeclaration;
1448         name: Identifier;
1449         members: NodeArray<EnumMember>;
1450     }
1451     export type ModuleName = Identifier | StringLiteral;
1452     export type ModuleBody = NamespaceBody | JSDocNamespaceBody;
1453     export interface ModuleDeclaration extends DeclarationStatement, JSDocContainer {
1454         kind: SyntaxKind.ModuleDeclaration;
1455         parent: ModuleBody | SourceFile;
1456         name: ModuleName;
1457         body?: ModuleBody | JSDocNamespaceDeclaration;
1458     }
1459     export type NamespaceBody = ModuleBlock | NamespaceDeclaration;
1460     export interface NamespaceDeclaration extends ModuleDeclaration {
1461         name: Identifier;
1462         body: NamespaceBody;
1463     }
1464     export type JSDocNamespaceBody = Identifier | JSDocNamespaceDeclaration;
1465     export interface JSDocNamespaceDeclaration extends ModuleDeclaration {
1466         name: Identifier;
1467         body?: JSDocNamespaceBody;
1468     }
1469     export interface ModuleBlock extends Node, Statement {
1470         kind: SyntaxKind.ModuleBlock;
1471         parent: ModuleDeclaration;
1472         statements: NodeArray<Statement>;
1473     }
1474     export type ModuleReference = EntityName | ExternalModuleReference;
1475     /**
1476      * One of:
1477      * - import x = require("mod");
1478      * - import x = M.x;
1479      */
1480     export interface ImportEqualsDeclaration extends DeclarationStatement, JSDocContainer {
1481         kind: SyntaxKind.ImportEqualsDeclaration;
1482         parent: SourceFile | ModuleBlock;
1483         name: Identifier;
1484         moduleReference: ModuleReference;
1485     }
1486     export interface ExternalModuleReference extends Node {
1487         kind: SyntaxKind.ExternalModuleReference;
1488         parent: ImportEqualsDeclaration;
1489         expression: Expression;
1490     }
1491     export interface ImportDeclaration extends Statement {
1492         kind: SyntaxKind.ImportDeclaration;
1493         parent: SourceFile | ModuleBlock;
1494         importClause?: ImportClause;
1495         /** If this is not a StringLiteral it will be a grammar error. */
1496         moduleSpecifier: Expression;
1497     }
1498     export type NamedImportBindings = NamespaceImport | NamedImports;
1499     export type NamedExportBindings = NamespaceExport | NamedExports;
1500     export interface ImportClause extends NamedDeclaration {
1501         kind: SyntaxKind.ImportClause;
1502         parent: ImportDeclaration;
1503         isTypeOnly: boolean;
1504         name?: Identifier;
1505         namedBindings?: NamedImportBindings;
1506     }
1507     export interface NamespaceImport extends NamedDeclaration {
1508         kind: SyntaxKind.NamespaceImport;
1509         parent: ImportClause;
1510         name: Identifier;
1511     }
1512     export interface NamespaceExport extends NamedDeclaration {
1513         kind: SyntaxKind.NamespaceExport;
1514         parent: ExportDeclaration;
1515         name: Identifier;
1516     }
1517     export interface NamespaceExportDeclaration extends DeclarationStatement {
1518         kind: SyntaxKind.NamespaceExportDeclaration;
1519         name: Identifier;
1520     }
1521     export interface ExportDeclaration extends DeclarationStatement, JSDocContainer {
1522         kind: SyntaxKind.ExportDeclaration;
1523         parent: SourceFile | ModuleBlock;
1524         isTypeOnly: boolean;
1525         /** Will not be assigned in the case of `export * from "foo";` */
1526         exportClause?: NamedExportBindings;
1527         /** If this is not a StringLiteral it will be a grammar error. */
1528         moduleSpecifier?: Expression;
1529     }
1530     export interface NamedImports extends Node {
1531         kind: SyntaxKind.NamedImports;
1532         parent: ImportClause;
1533         elements: NodeArray<ImportSpecifier>;
1534     }
1535     export interface NamedExports extends Node {
1536         kind: SyntaxKind.NamedExports;
1537         parent: ExportDeclaration;
1538         elements: NodeArray<ExportSpecifier>;
1539     }
1540     export type NamedImportsOrExports = NamedImports | NamedExports;
1541     export interface ImportSpecifier extends NamedDeclaration {
1542         kind: SyntaxKind.ImportSpecifier;
1543         parent: NamedImports;
1544         propertyName?: Identifier;
1545         name: Identifier;
1546     }
1547     export interface ExportSpecifier extends NamedDeclaration {
1548         kind: SyntaxKind.ExportSpecifier;
1549         parent: NamedExports;
1550         propertyName?: Identifier;
1551         name: Identifier;
1552     }
1553     export type ImportOrExportSpecifier = ImportSpecifier | ExportSpecifier;
1554     export type TypeOnlyCompatibleAliasDeclaration = ImportClause | NamespaceImport | ImportOrExportSpecifier;
1555     /**
1556      * This is either an `export =` or an `export default` declaration.
1557      * Unless `isExportEquals` is set, this node was parsed as an `export default`.
1558      */
1559     export interface ExportAssignment extends DeclarationStatement {
1560         kind: SyntaxKind.ExportAssignment;
1561         parent: SourceFile;
1562         isExportEquals?: boolean;
1563         expression: Expression;
1564     }
1565     export interface FileReference extends TextRange {
1566         fileName: string;
1567     }
1568     export interface CheckJsDirective extends TextRange {
1569         enabled: boolean;
1570     }
1571     export type CommentKind = SyntaxKind.SingleLineCommentTrivia | SyntaxKind.MultiLineCommentTrivia;
1572     export interface CommentRange extends TextRange {
1573         hasTrailingNewLine?: boolean;
1574         kind: CommentKind;
1575     }
1576     export interface SynthesizedComment extends CommentRange {
1577         text: string;
1578         pos: -1;
1579         end: -1;
1580     }
1581     export interface JSDocTypeExpression extends TypeNode {
1582         kind: SyntaxKind.JSDocTypeExpression;
1583         type: TypeNode;
1584     }
1585     export interface JSDocType extends TypeNode {
1586         _jsDocTypeBrand: any;
1587     }
1588     export interface JSDocAllType extends JSDocType {
1589         kind: SyntaxKind.JSDocAllType;
1590     }
1591     export interface JSDocUnknownType extends JSDocType {
1592         kind: SyntaxKind.JSDocUnknownType;
1593     }
1594     export interface JSDocNonNullableType extends JSDocType {
1595         kind: SyntaxKind.JSDocNonNullableType;
1596         type: TypeNode;
1597     }
1598     export interface JSDocNullableType extends JSDocType {
1599         kind: SyntaxKind.JSDocNullableType;
1600         type: TypeNode;
1601     }
1602     export interface JSDocOptionalType extends JSDocType {
1603         kind: SyntaxKind.JSDocOptionalType;
1604         type: TypeNode;
1605     }
1606     export interface JSDocFunctionType extends JSDocType, SignatureDeclarationBase {
1607         kind: SyntaxKind.JSDocFunctionType;
1608     }
1609     export interface JSDocVariadicType extends JSDocType {
1610         kind: SyntaxKind.JSDocVariadicType;
1611         type: TypeNode;
1612     }
1613     export interface JSDocNamepathType extends JSDocType {
1614         kind: SyntaxKind.JSDocNamepathType;
1615         type: TypeNode;
1616     }
1617     export type JSDocTypeReferencingNode = JSDocVariadicType | JSDocOptionalType | JSDocNullableType | JSDocNonNullableType;
1618     export interface JSDoc extends Node {
1619         kind: SyntaxKind.JSDocComment;
1620         parent: HasJSDoc;
1621         tags?: NodeArray<JSDocTag>;
1622         comment?: string;
1623     }
1624     export interface JSDocTag extends Node {
1625         parent: JSDoc | JSDocTypeLiteral;
1626         tagName: Identifier;
1627         comment?: string;
1628     }
1629     export interface JSDocUnknownTag extends JSDocTag {
1630         kind: SyntaxKind.JSDocTag;
1631     }
1632     /**
1633      * Note that `@extends` is a synonym of `@augments`.
1634      * Both tags are represented by this interface.
1635      */
1636     export interface JSDocAugmentsTag extends JSDocTag {
1637         kind: SyntaxKind.JSDocAugmentsTag;
1638         class: ExpressionWithTypeArguments & {
1639             expression: Identifier | PropertyAccessEntityNameExpression;
1640         };
1641     }
1642     export interface JSDocImplementsTag extends JSDocTag {
1643         kind: SyntaxKind.JSDocImplementsTag;
1644         class: ExpressionWithTypeArguments & {
1645             expression: Identifier | PropertyAccessEntityNameExpression;
1646         };
1647     }
1648     export interface JSDocAuthorTag extends JSDocTag {
1649         kind: SyntaxKind.JSDocAuthorTag;
1650     }
1651     export interface JSDocClassTag extends JSDocTag {
1652         kind: SyntaxKind.JSDocClassTag;
1653     }
1654     export interface JSDocPublicTag extends JSDocTag {
1655         kind: SyntaxKind.JSDocPublicTag;
1656     }
1657     export interface JSDocPrivateTag extends JSDocTag {
1658         kind: SyntaxKind.JSDocPrivateTag;
1659     }
1660     export interface JSDocProtectedTag extends JSDocTag {
1661         kind: SyntaxKind.JSDocProtectedTag;
1662     }
1663     export interface JSDocReadonlyTag extends JSDocTag {
1664         kind: SyntaxKind.JSDocReadonlyTag;
1665     }
1666     export interface JSDocEnumTag extends JSDocTag, Declaration {
1667         parent: JSDoc;
1668         kind: SyntaxKind.JSDocEnumTag;
1669         typeExpression?: JSDocTypeExpression;
1670     }
1671     export interface JSDocThisTag extends JSDocTag {
1672         kind: SyntaxKind.JSDocThisTag;
1673         typeExpression?: JSDocTypeExpression;
1674     }
1675     export interface JSDocTemplateTag extends JSDocTag {
1676         kind: SyntaxKind.JSDocTemplateTag;
1677         constraint: JSDocTypeExpression | undefined;
1678         typeParameters: NodeArray<TypeParameterDeclaration>;
1679     }
1680     export interface JSDocReturnTag extends JSDocTag {
1681         kind: SyntaxKind.JSDocReturnTag;
1682         typeExpression?: JSDocTypeExpression;
1683     }
1684     export interface JSDocTypeTag extends JSDocTag {
1685         kind: SyntaxKind.JSDocTypeTag;
1686         typeExpression: JSDocTypeExpression;
1687     }
1688     export interface JSDocTypedefTag extends JSDocTag, NamedDeclaration {
1689         parent: JSDoc;
1690         kind: SyntaxKind.JSDocTypedefTag;
1691         fullName?: JSDocNamespaceDeclaration | Identifier;
1692         name?: Identifier;
1693         typeExpression?: JSDocTypeExpression | JSDocTypeLiteral;
1694     }
1695     export interface JSDocCallbackTag extends JSDocTag, NamedDeclaration {
1696         parent: JSDoc;
1697         kind: SyntaxKind.JSDocCallbackTag;
1698         fullName?: JSDocNamespaceDeclaration | Identifier;
1699         name?: Identifier;
1700         typeExpression: JSDocSignature;
1701     }
1702     export interface JSDocSignature extends JSDocType, Declaration {
1703         kind: SyntaxKind.JSDocSignature;
1704         typeParameters?: readonly JSDocTemplateTag[];
1705         parameters: readonly JSDocParameterTag[];
1706         type: JSDocReturnTag | undefined;
1707     }
1708     export interface JSDocPropertyLikeTag extends JSDocTag, Declaration {
1709         parent: JSDoc;
1710         name: EntityName;
1711         typeExpression?: JSDocTypeExpression;
1712         /** Whether the property name came before the type -- non-standard for JSDoc, but Typescript-like */
1713         isNameFirst: boolean;
1714         isBracketed: boolean;
1715     }
1716     export interface JSDocPropertyTag extends JSDocPropertyLikeTag {
1717         kind: SyntaxKind.JSDocPropertyTag;
1718     }
1719     export interface JSDocParameterTag extends JSDocPropertyLikeTag {
1720         kind: SyntaxKind.JSDocParameterTag;
1721     }
1722     export interface JSDocTypeLiteral extends JSDocType {
1723         kind: SyntaxKind.JSDocTypeLiteral;
1724         jsDocPropertyTags?: readonly JSDocPropertyLikeTag[];
1725         /** If true, then this type literal represents an *array* of its type. */
1726         isArrayType?: boolean;
1727     }
1728     export enum FlowFlags {
1729         Unreachable = 1,
1730         Start = 2,
1731         BranchLabel = 4,
1732         LoopLabel = 8,
1733         Assignment = 16,
1734         TrueCondition = 32,
1735         FalseCondition = 64,
1736         SwitchClause = 128,
1737         ArrayMutation = 256,
1738         Call = 512,
1739         ReduceLabel = 1024,
1740         Referenced = 2048,
1741         Shared = 4096,
1742         Label = 12,
1743         Condition = 96
1744     }
1745     export type FlowNode = AfterFinallyFlow | PreFinallyFlow | FlowStart | FlowLabel | FlowAssignment | FlowCall | FlowCondition | FlowSwitchClause | FlowArrayMutation;
1746     export interface FlowNodeBase {
1747         flags: FlowFlags;
1748         id?: number;
1749     }
1750     export interface FlowLock {
1751         locked?: boolean;
1752     }
1753     export interface AfterFinallyFlow extends FlowNodeBase, FlowLock {
1754         antecedent: FlowNode;
1755     }
1756     export interface PreFinallyFlow extends FlowNodeBase {
1757         antecedent: FlowNode;
1758         lock: FlowLock;
1759     }
1760     export interface FlowStart extends FlowNodeBase {
1761         node?: FunctionExpression | ArrowFunction | MethodDeclaration;
1762     }
1763     export interface FlowLabel extends FlowNodeBase {
1764         antecedents: FlowNode[] | undefined;
1765     }
1766     export interface FlowAssignment extends FlowNodeBase {
1767         node: Expression | VariableDeclaration | BindingElement;
1768         antecedent: FlowNode;
1769     }
1770     export interface FlowCall extends FlowNodeBase {
1771         node: CallExpression;
1772         antecedent: FlowNode;
1773     }
1774     export interface FlowCondition extends FlowNodeBase {
1775         node: Expression;
1776         antecedent: FlowNode;
1777     }
1778     export interface FlowSwitchClause extends FlowNodeBase {
1779         switchStatement: SwitchStatement;
1780         clauseStart: number;
1781         clauseEnd: number;
1782         antecedent: FlowNode;
1783     }
1784     export interface FlowArrayMutation extends FlowNodeBase {
1785         node: CallExpression | BinaryExpression;
1786         antecedent: FlowNode;
1787     }
1788     export interface FlowReduceLabel extends FlowNodeBase {
1789         target: FlowLabel;
1790         antecedents: FlowNode[];
1791         antecedent: FlowNode;
1792     }
1793     export type FlowType = Type | IncompleteType;
1794     export interface IncompleteType {
1795         flags: TypeFlags;
1796         type: Type;
1797     }
1798     export interface AmdDependency {
1799         path: string;
1800         name?: string;
1801     }
1802     export interface SourceFile extends Declaration {
1803         kind: SyntaxKind.SourceFile;
1804         statements: NodeArray<Statement>;
1805         endOfFileToken: Token<SyntaxKind.EndOfFileToken>;
1806         fileName: string;
1807         text: string;
1808         amdDependencies: readonly AmdDependency[];
1809         moduleName?: string;
1810         referencedFiles: readonly FileReference[];
1811         typeReferenceDirectives: readonly FileReference[];
1812         libReferenceDirectives: readonly FileReference[];
1813         languageVariant: LanguageVariant;
1814         isDeclarationFile: boolean;
1815         /**
1816          * lib.d.ts should have a reference comment like
1817          *
1818          *  /// <reference no-default-lib="true"/>
1819          *
1820          * If any other file has this comment, it signals not to include lib.d.ts
1821          * because this containing file is intended to act as a default library.
1822          */
1823         hasNoDefaultLib: boolean;
1824         languageVersion: ScriptTarget;
1825     }
1826     export interface Bundle extends Node {
1827         kind: SyntaxKind.Bundle;
1828         prepends: readonly (InputFiles | UnparsedSource)[];
1829         sourceFiles: readonly SourceFile[];
1830     }
1831     export interface InputFiles extends Node {
1832         kind: SyntaxKind.InputFiles;
1833         javascriptPath?: string;
1834         javascriptText: string;
1835         javascriptMapPath?: string;
1836         javascriptMapText?: string;
1837         declarationPath?: string;
1838         declarationText: string;
1839         declarationMapPath?: string;
1840         declarationMapText?: string;
1841     }
1842     export interface UnparsedSource extends Node {
1843         kind: SyntaxKind.UnparsedSource;
1844         fileName: string;
1845         text: string;
1846         prologues: readonly UnparsedPrologue[];
1847         helpers: readonly UnscopedEmitHelper[] | undefined;
1848         referencedFiles: readonly FileReference[];
1849         typeReferenceDirectives: readonly string[] | undefined;
1850         libReferenceDirectives: readonly FileReference[];
1851         hasNoDefaultLib?: boolean;
1852         sourceMapPath?: string;
1853         sourceMapText?: string;
1854         syntheticReferences?: readonly UnparsedSyntheticReference[];
1855         texts: readonly UnparsedSourceText[];
1856     }
1857     export type UnparsedSourceText = UnparsedPrepend | UnparsedTextLike;
1858     export type UnparsedNode = UnparsedPrologue | UnparsedSourceText | UnparsedSyntheticReference;
1859     export interface UnparsedSection extends Node {
1860         kind: SyntaxKind;
1861         data?: string;
1862         parent: UnparsedSource;
1863     }
1864     export interface UnparsedPrologue extends UnparsedSection {
1865         kind: SyntaxKind.UnparsedPrologue;
1866         data: string;
1867         parent: UnparsedSource;
1868     }
1869     export interface UnparsedPrepend extends UnparsedSection {
1870         kind: SyntaxKind.UnparsedPrepend;
1871         data: string;
1872         parent: UnparsedSource;
1873         texts: readonly UnparsedTextLike[];
1874     }
1875     export interface UnparsedTextLike extends UnparsedSection {
1876         kind: SyntaxKind.UnparsedText | SyntaxKind.UnparsedInternalText;
1877         parent: UnparsedSource;
1878     }
1879     export interface UnparsedSyntheticReference extends UnparsedSection {
1880         kind: SyntaxKind.UnparsedSyntheticReference;
1881         parent: UnparsedSource;
1882     }
1883     export interface JsonSourceFile extends SourceFile {
1884         statements: NodeArray<JsonObjectExpressionStatement>;
1885     }
1886     export interface TsConfigSourceFile extends JsonSourceFile {
1887         extendedSourceFiles?: string[];
1888     }
1889     export interface JsonMinusNumericLiteral extends PrefixUnaryExpression {
1890         kind: SyntaxKind.PrefixUnaryExpression;
1891         operator: SyntaxKind.MinusToken;
1892         operand: NumericLiteral;
1893     }
1894     export interface JsonObjectExpressionStatement extends ExpressionStatement {
1895         expression: ObjectLiteralExpression | ArrayLiteralExpression | JsonMinusNumericLiteral | NumericLiteral | StringLiteral | BooleanLiteral | NullLiteral;
1896     }
1897     export interface ScriptReferenceHost {
1898         getCompilerOptions(): CompilerOptions;
1899         getSourceFile(fileName: string): SourceFile | undefined;
1900         getSourceFileByPath(path: Path): SourceFile | undefined;
1901         getCurrentDirectory(): string;
1902     }
1903     export interface ParseConfigHost {
1904         useCaseSensitiveFileNames: boolean;
1905         readDirectory(rootDir: string, extensions: readonly string[], excludes: readonly string[] | undefined, includes: readonly string[], depth?: number): readonly string[];
1906         /**
1907          * Gets a value indicating whether the specified path exists and is a file.
1908          * @param path The path to test.
1909          */
1910         fileExists(path: string): boolean;
1911         readFile(path: string): string | undefined;
1912         trace?(s: string): void;
1913     }
1914     /**
1915      * Branded string for keeping track of when we've turned an ambiguous path
1916      * specified like "./blah" to an absolute path to an actual
1917      * tsconfig file, e.g. "/root/blah/tsconfig.json"
1918      */
1919     export type ResolvedConfigFileName = string & {
1920         _isResolvedConfigFileName: never;
1921     };
1922     export type WriteFileCallback = (fileName: string, data: string, writeByteOrderMark: boolean, onError?: (message: string) => void, sourceFiles?: readonly SourceFile[]) => void;
1923     export class OperationCanceledException {
1924     }
1925     export interface CancellationToken {
1926         isCancellationRequested(): boolean;
1927         /** @throws OperationCanceledException if isCancellationRequested is true */
1928         throwIfCancellationRequested(): void;
1929     }
1930     export interface Program extends ScriptReferenceHost {
1931         getCurrentDirectory(): string;
1932         /**
1933          * Get a list of root file names that were passed to a 'createProgram'
1934          */
1935         getRootFileNames(): readonly string[];
1936         /**
1937          * Get a list of files in the program
1938          */
1939         getSourceFiles(): readonly SourceFile[];
1940         /**
1941          * Emits the JavaScript and declaration files.  If targetSourceFile is not specified, then
1942          * the JavaScript and declaration files will be produced for all the files in this program.
1943          * If targetSourceFile is specified, then only the JavaScript and declaration for that
1944          * specific file will be generated.
1945          *
1946          * If writeFile is not specified then the writeFile callback from the compiler host will be
1947          * used for writing the JavaScript and declaration files.  Otherwise, the writeFile parameter
1948          * will be invoked when writing the JavaScript and declaration files.
1949          */
1950         emit(targetSourceFile?: SourceFile, writeFile?: WriteFileCallback, cancellationToken?: CancellationToken, emitOnlyDtsFiles?: boolean, customTransformers?: CustomTransformers): EmitResult;
1951         getOptionsDiagnostics(cancellationToken?: CancellationToken): readonly Diagnostic[];
1952         getGlobalDiagnostics(cancellationToken?: CancellationToken): readonly Diagnostic[];
1953         getSyntacticDiagnostics(sourceFile?: SourceFile, cancellationToken?: CancellationToken): readonly DiagnosticWithLocation[];
1954         /** The first time this is called, it will return global diagnostics (no location). */
1955         getSemanticDiagnostics(sourceFile?: SourceFile, cancellationToken?: CancellationToken): readonly Diagnostic[];
1956         getDeclarationDiagnostics(sourceFile?: SourceFile, cancellationToken?: CancellationToken): readonly DiagnosticWithLocation[];
1957         getConfigFileParsingDiagnostics(): readonly Diagnostic[];
1958         /**
1959          * Gets a type checker that can be used to semantically analyze source files in the program.
1960          */
1961         getTypeChecker(): TypeChecker;
1962         getNodeCount(): number;
1963         getIdentifierCount(): number;
1964         getSymbolCount(): number;
1965         getTypeCount(): number;
1966         getInstantiationCount(): number;
1967         getRelationCacheSizes(): {
1968             assignable: number;
1969             identity: number;
1970             subtype: number;
1971             strictSubtype: number;
1972         };
1973         isSourceFileFromExternalLibrary(file: SourceFile): boolean;
1974         isSourceFileDefaultLibrary(file: SourceFile): boolean;
1975         getProjectReferences(): readonly ProjectReference[] | undefined;
1976         getResolvedProjectReferences(): readonly (ResolvedProjectReference | undefined)[] | undefined;
1977     }
1978     export interface ResolvedProjectReference {
1979         commandLine: ParsedCommandLine;
1980         sourceFile: SourceFile;
1981         references?: readonly (ResolvedProjectReference | undefined)[];
1982     }
1983     export type CustomTransformerFactory = (context: TransformationContext) => CustomTransformer;
1984     export interface CustomTransformer {
1985         transformSourceFile(node: SourceFile): SourceFile;
1986         transformBundle(node: Bundle): Bundle;
1987     }
1988     export interface CustomTransformers {
1989         /** Custom transformers to evaluate before built-in .js transformations. */
1990         before?: (TransformerFactory<SourceFile> | CustomTransformerFactory)[];
1991         /** Custom transformers to evaluate after built-in .js transformations. */
1992         after?: (TransformerFactory<SourceFile> | CustomTransformerFactory)[];
1993         /** Custom transformers to evaluate after built-in .d.ts transformations. */
1994         afterDeclarations?: (TransformerFactory<Bundle | SourceFile> | CustomTransformerFactory)[];
1995     }
1996     export interface SourceMapSpan {
1997         /** Line number in the .js file. */
1998         emittedLine: number;
1999         /** Column number in the .js file. */
2000         emittedColumn: number;
2001         /** Line number in the .ts file. */
2002         sourceLine: number;
2003         /** Column number in the .ts file. */
2004         sourceColumn: number;
2005         /** Optional name (index into names array) associated with this span. */
2006         nameIndex?: number;
2007         /** .ts file (index into sources array) associated with this span */
2008         sourceIndex: number;
2009     }
2010     /** Return code used by getEmitOutput function to indicate status of the function */
2011     export enum ExitStatus {
2012         Success = 0,
2013         DiagnosticsPresent_OutputsSkipped = 1,
2014         DiagnosticsPresent_OutputsGenerated = 2,
2015         InvalidProject_OutputsSkipped = 3,
2016         ProjectReferenceCycle_OutputsSkipped = 4,
2017         /** @deprecated Use ProjectReferenceCycle_OutputsSkipped instead. */
2018         ProjectReferenceCycle_OutputsSkupped = 4
2019     }
2020     export interface EmitResult {
2021         emitSkipped: boolean;
2022         /** Contains declaration emit diagnostics */
2023         diagnostics: readonly Diagnostic[];
2024         emittedFiles?: string[];
2025     }
2026     export interface TypeChecker {
2027         getTypeOfSymbolAtLocation(symbol: Symbol, node: Node): Type;
2028         getDeclaredTypeOfSymbol(symbol: Symbol): Type;
2029         getPropertiesOfType(type: Type): Symbol[];
2030         getPropertyOfType(type: Type, propertyName: string): Symbol | undefined;
2031         getPrivateIdentifierPropertyOfType(leftType: Type, name: string, location: Node): Symbol | undefined;
2032         getIndexInfoOfType(type: Type, kind: IndexKind): IndexInfo | undefined;
2033         getSignaturesOfType(type: Type, kind: SignatureKind): readonly Signature[];
2034         getIndexTypeOfType(type: Type, kind: IndexKind): Type | undefined;
2035         getBaseTypes(type: InterfaceType): BaseType[];
2036         getBaseTypeOfLiteralType(type: Type): Type;
2037         getWidenedType(type: Type): Type;
2038         getReturnTypeOfSignature(signature: Signature): Type;
2039         getNullableType(type: Type, flags: TypeFlags): Type;
2040         getNonNullableType(type: Type): Type;
2041         getTypeArguments(type: TypeReference): readonly Type[];
2042         /** Note that the resulting nodes cannot be checked. */
2043         typeToTypeNode(type: Type, enclosingDeclaration?: Node, flags?: NodeBuilderFlags): TypeNode | undefined;
2044         /** Note that the resulting nodes cannot be checked. */
2045         signatureToSignatureDeclaration(signature: Signature, kind: SyntaxKind, enclosingDeclaration?: Node, flags?: NodeBuilderFlags): (SignatureDeclaration & {
2046             typeArguments?: NodeArray<TypeNode>;
2047         }) | undefined;
2048         /** Note that the resulting nodes cannot be checked. */
2049         indexInfoToIndexSignatureDeclaration(indexInfo: IndexInfo, kind: IndexKind, enclosingDeclaration?: Node, flags?: NodeBuilderFlags): IndexSignatureDeclaration | undefined;
2050         /** Note that the resulting nodes cannot be checked. */
2051         symbolToEntityName(symbol: Symbol, meaning: SymbolFlags, enclosingDeclaration?: Node, flags?: NodeBuilderFlags): EntityName | undefined;
2052         /** Note that the resulting nodes cannot be checked. */
2053         symbolToExpression(symbol: Symbol, meaning: SymbolFlags, enclosingDeclaration?: Node, flags?: NodeBuilderFlags): Expression | undefined;
2054         /** Note that the resulting nodes cannot be checked. */
2055         symbolToTypeParameterDeclarations(symbol: Symbol, enclosingDeclaration?: Node, flags?: NodeBuilderFlags): NodeArray<TypeParameterDeclaration> | undefined;
2056         /** Note that the resulting nodes cannot be checked. */
2057         symbolToParameterDeclaration(symbol: Symbol, enclosingDeclaration?: Node, flags?: NodeBuilderFlags): ParameterDeclaration | undefined;
2058         /** Note that the resulting nodes cannot be checked. */
2059         typeParameterToDeclaration(parameter: TypeParameter, enclosingDeclaration?: Node, flags?: NodeBuilderFlags): TypeParameterDeclaration | undefined;
2060         getSymbolsInScope(location: Node, meaning: SymbolFlags): Symbol[];
2061         getSymbolAtLocation(node: Node): Symbol | undefined;
2062         getSymbolsOfParameterPropertyDeclaration(parameter: ParameterDeclaration, parameterName: string): Symbol[];
2063         /**
2064          * The function returns the value (local variable) symbol of an identifier in the short-hand property assignment.
2065          * This is necessary as an identifier in short-hand property assignment can contains two meaning: property name and property value.
2066          */
2067         getShorthandAssignmentValueSymbol(location: Node): Symbol | undefined;
2068         getExportSpecifierLocalTargetSymbol(location: ExportSpecifier): Symbol | undefined;
2069         /**
2070          * If a symbol is a local symbol with an associated exported symbol, returns the exported symbol.
2071          * Otherwise returns its input.
2072          * For example, at `export type T = number;`:
2073          *     - `getSymbolAtLocation` at the location `T` will return the exported symbol for `T`.
2074          *     - But the result of `getSymbolsInScope` will contain the *local* symbol for `T`, not the exported symbol.
2075          *     - Calling `getExportSymbolOfSymbol` on that local symbol will return the exported symbol.
2076          */
2077         getExportSymbolOfSymbol(symbol: Symbol): Symbol;
2078         getPropertySymbolOfDestructuringAssignment(location: Identifier): Symbol | undefined;
2079         getTypeOfAssignmentPattern(pattern: AssignmentPattern): Type;
2080         getTypeAtLocation(node: Node): Type;
2081         getTypeFromTypeNode(node: TypeNode): Type;
2082         signatureToString(signature: Signature, enclosingDeclaration?: Node, flags?: TypeFormatFlags, kind?: SignatureKind): string;
2083         typeToString(type: Type, enclosingDeclaration?: Node, flags?: TypeFormatFlags): string;
2084         symbolToString(symbol: Symbol, enclosingDeclaration?: Node, meaning?: SymbolFlags, flags?: SymbolFormatFlags): string;
2085         typePredicateToString(predicate: TypePredicate, enclosingDeclaration?: Node, flags?: TypeFormatFlags): string;
2086         getFullyQualifiedName(symbol: Symbol): string;
2087         getAugmentedPropertiesOfType(type: Type): Symbol[];
2088         getRootSymbols(symbol: Symbol): readonly Symbol[];
2089         getContextualType(node: Expression): Type | undefined;
2090         /**
2091          * returns unknownSignature in the case of an error.
2092          * returns undefined if the node is not valid.
2093          * @param argumentCount Apparent number of arguments, passed in case of a possibly incomplete call. This should come from an ArgumentListInfo. See `signatureHelp.ts`.
2094          */
2095         getResolvedSignature(node: CallLikeExpression, candidatesOutArray?: Signature[], argumentCount?: number): Signature | undefined;
2096         getSignatureFromDeclaration(declaration: SignatureDeclaration): Signature | undefined;
2097         isImplementationOfOverload(node: SignatureDeclaration): boolean | undefined;
2098         isUndefinedSymbol(symbol: Symbol): boolean;
2099         isArgumentsSymbol(symbol: Symbol): boolean;
2100         isUnknownSymbol(symbol: Symbol): boolean;
2101         getConstantValue(node: EnumMember | PropertyAccessExpression | ElementAccessExpression): string | number | undefined;
2102         isValidPropertyAccess(node: PropertyAccessExpression | QualifiedName | ImportTypeNode, propertyName: string): boolean;
2103         /** Follow all aliases to get the original symbol. */
2104         getAliasedSymbol(symbol: Symbol): Symbol;
2105         getExportsOfModule(moduleSymbol: Symbol): Symbol[];
2106         getJsxIntrinsicTagNamesAt(location: Node): Symbol[];
2107         isOptionalParameter(node: ParameterDeclaration): boolean;
2108         getAmbientModules(): Symbol[];
2109         tryGetMemberInModuleExports(memberName: string, moduleSymbol: Symbol): Symbol | undefined;
2110         getApparentType(type: Type): Type;
2111         getBaseConstraintOfType(type: Type): Type | undefined;
2112         getDefaultFromTypeParameter(type: Type): Type | undefined;
2113         /**
2114          * Depending on the operation performed, it may be appropriate to throw away the checker
2115          * if the cancellation token is triggered. Typically, if it is used for error checking
2116          * and the operation is cancelled, then it should be discarded, otherwise it is safe to keep.
2117          */
2118         runWithCancellationToken<T>(token: CancellationToken, cb: (checker: TypeChecker) => T): T;
2119     }
2120     export enum NodeBuilderFlags {
2121         None = 0,
2122         NoTruncation = 1,
2123         WriteArrayAsGenericType = 2,
2124         GenerateNamesForShadowedTypeParams = 4,
2125         UseStructuralFallback = 8,
2126         ForbidIndexedAccessSymbolReferences = 16,
2127         WriteTypeArgumentsOfSignature = 32,
2128         UseFullyQualifiedType = 64,
2129         UseOnlyExternalAliasing = 128,
2130         SuppressAnyReturnType = 256,
2131         WriteTypeParametersInQualifiedName = 512,
2132         MultilineObjectLiterals = 1024,
2133         WriteClassExpressionAsTypeLiteral = 2048,
2134         UseTypeOfFunction = 4096,
2135         OmitParameterModifiers = 8192,
2136         UseAliasDefinedOutsideCurrentScope = 16384,
2137         UseSingleQuotesForStringLiteralType = 268435456,
2138         NoTypeReduction = 536870912,
2139         AllowThisInObjectLiteral = 32768,
2140         AllowQualifedNameInPlaceOfIdentifier = 65536,
2141         AllowAnonymousIdentifier = 131072,
2142         AllowEmptyUnionOrIntersection = 262144,
2143         AllowEmptyTuple = 524288,
2144         AllowUniqueESSymbolType = 1048576,
2145         AllowEmptyIndexInfoType = 2097152,
2146         AllowNodeModulesRelativePaths = 67108864,
2147         IgnoreErrors = 70221824,
2148         InObjectTypeLiteral = 4194304,
2149         InTypeAlias = 8388608,
2150         InInitialEntityName = 16777216,
2151         InReverseMappedType = 33554432
2152     }
2153     export enum TypeFormatFlags {
2154         None = 0,
2155         NoTruncation = 1,
2156         WriteArrayAsGenericType = 2,
2157         UseStructuralFallback = 8,
2158         WriteTypeArgumentsOfSignature = 32,
2159         UseFullyQualifiedType = 64,
2160         SuppressAnyReturnType = 256,
2161         MultilineObjectLiterals = 1024,
2162         WriteClassExpressionAsTypeLiteral = 2048,
2163         UseTypeOfFunction = 4096,
2164         OmitParameterModifiers = 8192,
2165         UseAliasDefinedOutsideCurrentScope = 16384,
2166         UseSingleQuotesForStringLiteralType = 268435456,
2167         NoTypeReduction = 536870912,
2168         AllowUniqueESSymbolType = 1048576,
2169         AddUndefined = 131072,
2170         WriteArrowStyleSignature = 262144,
2171         InArrayType = 524288,
2172         InElementType = 2097152,
2173         InFirstTypeArgument = 4194304,
2174         InTypeAlias = 8388608,
2175         /** @deprecated */ WriteOwnNameForAnyLike = 0,
2176         NodeBuilderFlagsMask = 814775659
2177     }
2178     export enum SymbolFormatFlags {
2179         None = 0,
2180         WriteTypeParametersOrArguments = 1,
2181         UseOnlyExternalAliasing = 2,
2182         AllowAnyNodeKind = 4,
2183         UseAliasDefinedOutsideCurrentScope = 8,
2184     }
2185     export enum TypePredicateKind {
2186         This = 0,
2187         Identifier = 1,
2188         AssertsThis = 2,
2189         AssertsIdentifier = 3
2190     }
2191     export interface TypePredicateBase {
2192         kind: TypePredicateKind;
2193         type: Type | undefined;
2194     }
2195     export interface ThisTypePredicate extends TypePredicateBase {
2196         kind: TypePredicateKind.This;
2197         parameterName: undefined;
2198         parameterIndex: undefined;
2199         type: Type;
2200     }
2201     export interface IdentifierTypePredicate extends TypePredicateBase {
2202         kind: TypePredicateKind.Identifier;
2203         parameterName: string;
2204         parameterIndex: number;
2205         type: Type;
2206     }
2207     export interface AssertsThisTypePredicate extends TypePredicateBase {
2208         kind: TypePredicateKind.AssertsThis;
2209         parameterName: undefined;
2210         parameterIndex: undefined;
2211         type: Type | undefined;
2212     }
2213     export interface AssertsIdentifierTypePredicate extends TypePredicateBase {
2214         kind: TypePredicateKind.AssertsIdentifier;
2215         parameterName: string;
2216         parameterIndex: number;
2217         type: Type | undefined;
2218     }
2219     export type TypePredicate = ThisTypePredicate | IdentifierTypePredicate | AssertsThisTypePredicate | AssertsIdentifierTypePredicate;
2220     export enum SymbolFlags {
2221         None = 0,
2222         FunctionScopedVariable = 1,
2223         BlockScopedVariable = 2,
2224         Property = 4,
2225         EnumMember = 8,
2226         Function = 16,
2227         Class = 32,
2228         Interface = 64,
2229         ConstEnum = 128,
2230         RegularEnum = 256,
2231         ValueModule = 512,
2232         NamespaceModule = 1024,
2233         TypeLiteral = 2048,
2234         ObjectLiteral = 4096,
2235         Method = 8192,
2236         Constructor = 16384,
2237         GetAccessor = 32768,
2238         SetAccessor = 65536,
2239         Signature = 131072,
2240         TypeParameter = 262144,
2241         TypeAlias = 524288,
2242         ExportValue = 1048576,
2243         Alias = 2097152,
2244         Prototype = 4194304,
2245         ExportStar = 8388608,
2246         Optional = 16777216,
2247         Transient = 33554432,
2248         Assignment = 67108864,
2249         ModuleExports = 134217728,
2250         Enum = 384,
2251         Variable = 3,
2252         Value = 111551,
2253         Type = 788968,
2254         Namespace = 1920,
2255         Module = 1536,
2256         Accessor = 98304,
2257         FunctionScopedVariableExcludes = 111550,
2258         BlockScopedVariableExcludes = 111551,
2259         ParameterExcludes = 111551,
2260         PropertyExcludes = 0,
2261         EnumMemberExcludes = 900095,
2262         FunctionExcludes = 110991,
2263         ClassExcludes = 899503,
2264         InterfaceExcludes = 788872,
2265         RegularEnumExcludes = 899327,
2266         ConstEnumExcludes = 899967,
2267         ValueModuleExcludes = 110735,
2268         NamespaceModuleExcludes = 0,
2269         MethodExcludes = 103359,
2270         GetAccessorExcludes = 46015,
2271         SetAccessorExcludes = 78783,
2272         TypeParameterExcludes = 526824,
2273         TypeAliasExcludes = 788968,
2274         AliasExcludes = 2097152,
2275         ModuleMember = 2623475,
2276         ExportHasLocal = 944,
2277         BlockScoped = 418,
2278         PropertyOrAccessor = 98308,
2279         ClassMember = 106500,
2280     }
2281     export interface Symbol {
2282         flags: SymbolFlags;
2283         escapedName: __String;
2284         declarations: Declaration[];
2285         valueDeclaration: Declaration;
2286         members?: SymbolTable;
2287         exports?: SymbolTable;
2288         globalExports?: SymbolTable;
2289     }
2290     export enum InternalSymbolName {
2291         Call = "__call",
2292         Constructor = "__constructor",
2293         New = "__new",
2294         Index = "__index",
2295         ExportStar = "__export",
2296         Global = "__global",
2297         Missing = "__missing",
2298         Type = "__type",
2299         Object = "__object",
2300         JSXAttributes = "__jsxAttributes",
2301         Class = "__class",
2302         Function = "__function",
2303         Computed = "__computed",
2304         Resolving = "__resolving__",
2305         ExportEquals = "export=",
2306         Default = "default",
2307         This = "this"
2308     }
2309     /**
2310      * This represents a string whose leading underscore have been escaped by adding extra leading underscores.
2311      * The shape of this brand is rather unique compared to others we've used.
2312      * Instead of just an intersection of a string and an object, it is that union-ed
2313      * with an intersection of void and an object. This makes it wholly incompatible
2314      * with a normal string (which is good, it cannot be misused on assignment or on usage),
2315      * while still being comparable with a normal string via === (also good) and castable from a string.
2316      */
2317     export type __String = (string & {
2318         __escapedIdentifier: void;
2319     }) | (void & {
2320         __escapedIdentifier: void;
2321     }) | InternalSymbolName;
2322     /** ReadonlyMap where keys are `__String`s. */
2323     export interface ReadonlyUnderscoreEscapedMap<T> {
2324         get(key: __String): T | undefined;
2325         has(key: __String): boolean;
2326         forEach(action: (value: T, key: __String) => void): void;
2327         readonly size: number;
2328         keys(): Iterator<__String>;
2329         values(): Iterator<T>;
2330         entries(): Iterator<[__String, T]>;
2331     }
2332     /** Map where keys are `__String`s. */
2333     export interface UnderscoreEscapedMap<T> extends ReadonlyUnderscoreEscapedMap<T> {
2334         set(key: __String, value: T): this;
2335         delete(key: __String): boolean;
2336         clear(): void;
2337     }
2338     /** SymbolTable based on ES6 Map interface. */
2339     export type SymbolTable = UnderscoreEscapedMap<Symbol>;
2340     export enum TypeFlags {
2341         Any = 1,
2342         Unknown = 2,
2343         String = 4,
2344         Number = 8,
2345         Boolean = 16,
2346         Enum = 32,
2347         BigInt = 64,
2348         StringLiteral = 128,
2349         NumberLiteral = 256,
2350         BooleanLiteral = 512,
2351         EnumLiteral = 1024,
2352         BigIntLiteral = 2048,
2353         ESSymbol = 4096,
2354         UniqueESSymbol = 8192,
2355         Void = 16384,
2356         Undefined = 32768,
2357         Null = 65536,
2358         Never = 131072,
2359         TypeParameter = 262144,
2360         Object = 524288,
2361         Union = 1048576,
2362         Intersection = 2097152,
2363         Index = 4194304,
2364         IndexedAccess = 8388608,
2365         Conditional = 16777216,
2366         Substitution = 33554432,
2367         NonPrimitive = 67108864,
2368         Literal = 2944,
2369         Unit = 109440,
2370         StringOrNumberLiteral = 384,
2371         PossiblyFalsy = 117724,
2372         StringLike = 132,
2373         NumberLike = 296,
2374         BigIntLike = 2112,
2375         BooleanLike = 528,
2376         EnumLike = 1056,
2377         ESSymbolLike = 12288,
2378         VoidLike = 49152,
2379         UnionOrIntersection = 3145728,
2380         StructuredType = 3670016,
2381         TypeVariable = 8650752,
2382         InstantiableNonPrimitive = 58982400,
2383         InstantiablePrimitive = 4194304,
2384         Instantiable = 63176704,
2385         StructuredOrInstantiable = 66846720,
2386         Narrowable = 133970943,
2387         NotUnionOrUnit = 67637251,
2388     }
2389     export type DestructuringPattern = BindingPattern | ObjectLiteralExpression | ArrayLiteralExpression;
2390     export interface Type {
2391         flags: TypeFlags;
2392         symbol: Symbol;
2393         pattern?: DestructuringPattern;
2394         aliasSymbol?: Symbol;
2395         aliasTypeArguments?: readonly Type[];
2396     }
2397     export interface LiteralType extends Type {
2398         value: string | number | PseudoBigInt;
2399         freshType: LiteralType;
2400         regularType: LiteralType;
2401     }
2402     export interface UniqueESSymbolType extends Type {
2403         symbol: Symbol;
2404         escapedName: __String;
2405     }
2406     export interface StringLiteralType extends LiteralType {
2407         value: string;
2408     }
2409     export interface NumberLiteralType extends LiteralType {
2410         value: number;
2411     }
2412     export interface BigIntLiteralType extends LiteralType {
2413         value: PseudoBigInt;
2414     }
2415     export interface EnumType extends Type {
2416     }
2417     export enum ObjectFlags {
2418         Class = 1,
2419         Interface = 2,
2420         Reference = 4,
2421         Tuple = 8,
2422         Anonymous = 16,
2423         Mapped = 32,
2424         Instantiated = 64,
2425         ObjectLiteral = 128,
2426         EvolvingArray = 256,
2427         ObjectLiteralPatternWithComputedProperties = 512,
2428         ContainsSpread = 1024,
2429         ReverseMapped = 2048,
2430         JsxAttributes = 4096,
2431         MarkerType = 8192,
2432         JSLiteral = 16384,
2433         FreshLiteral = 32768,
2434         ArrayLiteral = 65536,
2435         ObjectRestType = 131072,
2436         ClassOrInterface = 3,
2437     }
2438     export interface ObjectType extends Type {
2439         objectFlags: ObjectFlags;
2440     }
2441     /** Class and interface types (ObjectFlags.Class and ObjectFlags.Interface). */
2442     export interface InterfaceType extends ObjectType {
2443         typeParameters: TypeParameter[] | undefined;
2444         outerTypeParameters: TypeParameter[] | undefined;
2445         localTypeParameters: TypeParameter[] | undefined;
2446         thisType: TypeParameter | undefined;
2447     }
2448     export type BaseType = ObjectType | IntersectionType | TypeVariable;
2449     export interface InterfaceTypeWithDeclaredMembers extends InterfaceType {
2450         declaredProperties: Symbol[];
2451         declaredCallSignatures: Signature[];
2452         declaredConstructSignatures: Signature[];
2453         declaredStringIndexInfo?: IndexInfo;
2454         declaredNumberIndexInfo?: IndexInfo;
2455     }
2456     /**
2457      * Type references (ObjectFlags.Reference). When a class or interface has type parameters or
2458      * a "this" type, references to the class or interface are made using type references. The
2459      * typeArguments property specifies the types to substitute for the type parameters of the
2460      * class or interface and optionally includes an extra element that specifies the type to
2461      * substitute for "this" in the resulting instantiation. When no extra argument is present,
2462      * the type reference itself is substituted for "this". The typeArguments property is undefined
2463      * if the class or interface has no type parameters and the reference isn't specifying an
2464      * explicit "this" argument.
2465      */
2466     export interface TypeReference extends ObjectType {
2467         target: GenericType;
2468         node?: TypeReferenceNode | ArrayTypeNode | TupleTypeNode;
2469     }
2470     export interface DeferredTypeReference extends TypeReference {
2471     }
2472     export interface GenericType extends InterfaceType, TypeReference {
2473     }
2474     export interface TupleType extends GenericType {
2475         minLength: number;
2476         hasRestElement: boolean;
2477         readonly: boolean;
2478         associatedNames?: __String[];
2479     }
2480     export interface TupleTypeReference extends TypeReference {
2481         target: TupleType;
2482     }
2483     export interface UnionOrIntersectionType extends Type {
2484         types: Type[];
2485     }
2486     export interface UnionType extends UnionOrIntersectionType {
2487     }
2488     export interface IntersectionType extends UnionOrIntersectionType {
2489     }
2490     export type StructuredType = ObjectType | UnionType | IntersectionType;
2491     export interface EvolvingArrayType extends ObjectType {
2492         elementType: Type;
2493         finalArrayType?: Type;
2494     }
2495     export interface InstantiableType extends Type {
2496     }
2497     export interface TypeParameter extends InstantiableType {
2498     }
2499     export interface IndexedAccessType extends InstantiableType {
2500         objectType: Type;
2501         indexType: Type;
2502         constraint?: Type;
2503         simplifiedForReading?: Type;
2504         simplifiedForWriting?: Type;
2505     }
2506     export type TypeVariable = TypeParameter | IndexedAccessType;
2507     export interface IndexType extends InstantiableType {
2508         type: InstantiableType | UnionOrIntersectionType;
2509     }
2510     export interface ConditionalRoot {
2511         node: ConditionalTypeNode;
2512         checkType: Type;
2513         extendsType: Type;
2514         trueType: Type;
2515         falseType: Type;
2516         isDistributive: boolean;
2517         inferTypeParameters?: TypeParameter[];
2518         outerTypeParameters?: TypeParameter[];
2519         instantiations?: Map<Type>;
2520         aliasSymbol?: Symbol;
2521         aliasTypeArguments?: Type[];
2522     }
2523     export interface ConditionalType extends InstantiableType {
2524         root: ConditionalRoot;
2525         checkType: Type;
2526         extendsType: Type;
2527         resolvedTrueType: Type;
2528         resolvedFalseType: Type;
2529     }
2530     export interface SubstitutionType extends InstantiableType {
2531         baseType: Type;
2532         substitute: Type;
2533     }
2534     export enum SignatureKind {
2535         Call = 0,
2536         Construct = 1
2537     }
2538     export interface Signature {
2539         declaration?: SignatureDeclaration | JSDocSignature;
2540         typeParameters?: readonly TypeParameter[];
2541         parameters: readonly Symbol[];
2542     }
2543     export enum IndexKind {
2544         String = 0,
2545         Number = 1
2546     }
2547     export interface IndexInfo {
2548         type: Type;
2549         isReadonly: boolean;
2550         declaration?: IndexSignatureDeclaration;
2551     }
2552     export enum InferencePriority {
2553         NakedTypeVariable = 1,
2554         HomomorphicMappedType = 2,
2555         PartialHomomorphicMappedType = 4,
2556         MappedTypeConstraint = 8,
2557         ContravariantConditional = 16,
2558         ReturnType = 32,
2559         LiteralKeyof = 64,
2560         NoConstraints = 128,
2561         AlwaysStrict = 256,
2562         MaxValue = 512,
2563         PriorityImpliesCombination = 104,
2564         Circularity = -1
2565     }
2566     /** @deprecated Use FileExtensionInfo instead. */
2567     export type JsFileExtensionInfo = FileExtensionInfo;
2568     export interface FileExtensionInfo {
2569         extension: string;
2570         isMixedContent: boolean;
2571         scriptKind?: ScriptKind;
2572     }
2573     export interface DiagnosticMessage {
2574         key: string;
2575         category: DiagnosticCategory;
2576         code: number;
2577         message: string;
2578         reportsUnnecessary?: {};
2579     }
2580     /**
2581      * A linked list of formatted diagnostic messages to be used as part of a multiline message.
2582      * It is built from the bottom up, leaving the head to be the "main" diagnostic.
2583      * While it seems that DiagnosticMessageChain is structurally similar to DiagnosticMessage,
2584      * the difference is that messages are all preformatted in DMC.
2585      */
2586     export interface DiagnosticMessageChain {
2587         messageText: string;
2588         category: DiagnosticCategory;
2589         code: number;
2590         next?: DiagnosticMessageChain[];
2591     }
2592     export interface Diagnostic extends DiagnosticRelatedInformation {
2593         /** May store more in future. For now, this will simply be `true` to indicate when a diagnostic is an unused-identifier diagnostic. */
2594         reportsUnnecessary?: {};
2595         source?: string;
2596         relatedInformation?: DiagnosticRelatedInformation[];
2597     }
2598     export interface DiagnosticRelatedInformation {
2599         category: DiagnosticCategory;
2600         code: number;
2601         file: SourceFile | undefined;
2602         start: number | undefined;
2603         length: number | undefined;
2604         messageText: string | DiagnosticMessageChain;
2605     }
2606     export interface DiagnosticWithLocation extends Diagnostic {
2607         file: SourceFile;
2608         start: number;
2609         length: number;
2610     }
2611     export enum DiagnosticCategory {
2612         Warning = 0,
2613         Error = 1,
2614         Suggestion = 2,
2615         Message = 3
2616     }
2617     export enum ModuleResolutionKind {
2618         Classic = 1,
2619         NodeJs = 2
2620     }
2621     export interface PluginImport {
2622         name: string;
2623     }
2624     export interface ProjectReference {
2625         /** A normalized path on disk */
2626         path: string;
2627         /** The path as the user originally wrote it */
2628         originalPath?: string;
2629         /** True if the output of this reference should be prepended to the output of this project. Only valid for --outFile compilations */
2630         prepend?: boolean;
2631         /** True if it is intended that this reference form a circularity */
2632         circular?: boolean;
2633     }
2634     export enum WatchFileKind {
2635         FixedPollingInterval = 0,
2636         PriorityPollingInterval = 1,
2637         DynamicPriorityPolling = 2,
2638         UseFsEvents = 3,
2639         UseFsEventsOnParentDirectory = 4
2640     }
2641     export enum WatchDirectoryKind {
2642         UseFsEvents = 0,
2643         FixedPollingInterval = 1,
2644         DynamicPriorityPolling = 2
2645     }
2646     export enum PollingWatchKind {
2647         FixedInterval = 0,
2648         PriorityInterval = 1,
2649         DynamicPriority = 2
2650     }
2651     export type CompilerOptionsValue = string | number | boolean | (string | number)[] | string[] | MapLike<string[]> | PluginImport[] | ProjectReference[] | null | undefined;
2652     export interface CompilerOptions {
2653         allowJs?: boolean;
2654         allowSyntheticDefaultImports?: boolean;
2655         allowUmdGlobalAccess?: boolean;
2656         allowUnreachableCode?: boolean;
2657         allowUnusedLabels?: boolean;
2658         alwaysStrict?: boolean;
2659         baseUrl?: string;
2660         charset?: string;
2661         checkJs?: boolean;
2662         declaration?: boolean;
2663         declarationMap?: boolean;
2664         emitDeclarationOnly?: boolean;
2665         declarationDir?: string;
2666         disableSizeLimit?: boolean;
2667         disableSourceOfProjectReferenceRedirect?: boolean;
2668         disableSolutionSearching?: boolean;
2669         downlevelIteration?: boolean;
2670         emitBOM?: boolean;
2671         emitDecoratorMetadata?: boolean;
2672         experimentalDecorators?: boolean;
2673         forceConsistentCasingInFileNames?: boolean;
2674         importHelpers?: boolean;
2675         importsNotUsedAsValues?: ImportsNotUsedAsValues;
2676         inlineSourceMap?: boolean;
2677         inlineSources?: boolean;
2678         isolatedModules?: boolean;
2679         jsx?: JsxEmit;
2680         keyofStringsOnly?: boolean;
2681         lib?: string[];
2682         locale?: string;
2683         mapRoot?: string;
2684         maxNodeModuleJsDepth?: number;
2685         module?: ModuleKind;
2686         moduleResolution?: ModuleResolutionKind;
2687         newLine?: NewLineKind;
2688         noEmit?: boolean;
2689         noEmitHelpers?: boolean;
2690         noEmitOnError?: boolean;
2691         noErrorTruncation?: boolean;
2692         noFallthroughCasesInSwitch?: boolean;
2693         noImplicitAny?: boolean;
2694         noImplicitReturns?: boolean;
2695         noImplicitThis?: boolean;
2696         noStrictGenericChecks?: boolean;
2697         noUnusedLocals?: boolean;
2698         noUnusedParameters?: boolean;
2699         noImplicitUseStrict?: boolean;
2700         assumeChangesOnlyAffectDirectDependencies?: boolean;
2701         noLib?: boolean;
2702         noResolve?: boolean;
2703         out?: string;
2704         outDir?: string;
2705         outFile?: string;
2706         paths?: MapLike<string[]>;
2707         preserveConstEnums?: boolean;
2708         preserveSymlinks?: boolean;
2709         project?: string;
2710         reactNamespace?: string;
2711         jsxFactory?: string;
2712         composite?: boolean;
2713         incremental?: boolean;
2714         tsBuildInfoFile?: string;
2715         removeComments?: boolean;
2716         rootDir?: string;
2717         rootDirs?: string[];
2718         skipLibCheck?: boolean;
2719         skipDefaultLibCheck?: boolean;
2720         sourceMap?: boolean;
2721         sourceRoot?: string;
2722         strict?: boolean;
2723         strictFunctionTypes?: boolean;
2724         strictBindCallApply?: boolean;
2725         strictNullChecks?: boolean;
2726         strictPropertyInitialization?: boolean;
2727         stripInternal?: boolean;
2728         suppressExcessPropertyErrors?: boolean;
2729         suppressImplicitAnyIndexErrors?: boolean;
2730         target?: ScriptTarget;
2731         traceResolution?: boolean;
2732         resolveJsonModule?: boolean;
2733         types?: string[];
2734         /** Paths used to compute primary types search locations */
2735         typeRoots?: string[];
2736         esModuleInterop?: boolean;
2737         useDefineForClassFields?: boolean;
2738         [option: string]: CompilerOptionsValue | TsConfigSourceFile | undefined;
2739     }
2740     export interface WatchOptions {
2741         watchFile?: WatchFileKind;
2742         watchDirectory?: WatchDirectoryKind;
2743         fallbackPolling?: PollingWatchKind;
2744         synchronousWatchDirectory?: boolean;
2745         [option: string]: CompilerOptionsValue | undefined;
2746     }
2747     export interface TypeAcquisition {
2748         /**
2749          * @deprecated typingOptions.enableAutoDiscovery
2750          * Use typeAcquisition.enable instead.
2751          */
2752         enableAutoDiscovery?: boolean;
2753         enable?: boolean;
2754         include?: string[];
2755         exclude?: string[];
2756         [option: string]: string[] | boolean | undefined;
2757     }
2758     export enum ModuleKind {
2759         None = 0,
2760         CommonJS = 1,
2761         AMD = 2,
2762         UMD = 3,
2763         System = 4,
2764         ES2015 = 5,
2765         ES2020 = 6,
2766         ESNext = 99
2767     }
2768     export enum JsxEmit {
2769         None = 0,
2770         Preserve = 1,
2771         React = 2,
2772         ReactNative = 3
2773     }
2774     export enum ImportsNotUsedAsValues {
2775         Remove = 0,
2776         Preserve = 1,
2777         Error = 2
2778     }
2779     export enum NewLineKind {
2780         CarriageReturnLineFeed = 0,
2781         LineFeed = 1
2782     }
2783     export interface LineAndCharacter {
2784         /** 0-based. */
2785         line: number;
2786         character: number;
2787     }
2788     export enum ScriptKind {
2789         Unknown = 0,
2790         JS = 1,
2791         JSX = 2,
2792         TS = 3,
2793         TSX = 4,
2794         External = 5,
2795         JSON = 6,
2796         /**
2797          * Used on extensions that doesn't define the ScriptKind but the content defines it.
2798          * Deferred extensions are going to be included in all project contexts.
2799          */
2800         Deferred = 7
2801     }
2802     export enum ScriptTarget {
2803         ES3 = 0,
2804         ES5 = 1,
2805         ES2015 = 2,
2806         ES2016 = 3,
2807         ES2017 = 4,
2808         ES2018 = 5,
2809         ES2019 = 6,
2810         ES2020 = 7,
2811         ESNext = 99,
2812         JSON = 100,
2813         Latest = 99
2814     }
2815     export enum LanguageVariant {
2816         Standard = 0,
2817         JSX = 1
2818     }
2819     /** Either a parsed command line or a parsed tsconfig.json */
2820     export interface ParsedCommandLine {
2821         options: CompilerOptions;
2822         typeAcquisition?: TypeAcquisition;
2823         fileNames: string[];
2824         projectReferences?: readonly ProjectReference[];
2825         watchOptions?: WatchOptions;
2826         raw?: any;
2827         errors: Diagnostic[];
2828         wildcardDirectories?: MapLike<WatchDirectoryFlags>;
2829         compileOnSave?: boolean;
2830     }
2831     export enum WatchDirectoryFlags {
2832         None = 0,
2833         Recursive = 1
2834     }
2835     export interface ExpandResult {
2836         fileNames: string[];
2837         wildcardDirectories: MapLike<WatchDirectoryFlags>;
2838     }
2839     export interface CreateProgramOptions {
2840         rootNames: readonly string[];
2841         options: CompilerOptions;
2842         projectReferences?: readonly ProjectReference[];
2843         host?: CompilerHost;
2844         oldProgram?: Program;
2845         configFileParsingDiagnostics?: readonly Diagnostic[];
2846     }
2847     export interface ModuleResolutionHost {
2848         fileExists(fileName: string): boolean;
2849         readFile(fileName: string): string | undefined;
2850         trace?(s: string): void;
2851         directoryExists?(directoryName: string): boolean;
2852         /**
2853          * Resolve a symbolic link.
2854          * @see https://nodejs.org/api/fs.html#fs_fs_realpathsync_path_options
2855          */
2856         realpath?(path: string): string;
2857         getCurrentDirectory?(): string;
2858         getDirectories?(path: string): string[];
2859     }
2860     /**
2861      * Represents the result of module resolution.
2862      * Module resolution will pick up tsx/jsx/js files even if '--jsx' and '--allowJs' are turned off.
2863      * The Program will then filter results based on these flags.
2864      *
2865      * Prefer to return a `ResolvedModuleFull` so that the file type does not have to be inferred.
2866      */
2867     export interface ResolvedModule {
2868         /** Path of the file the module was resolved to. */
2869         resolvedFileName: string;
2870         /** True if `resolvedFileName` comes from `node_modules`. */
2871         isExternalLibraryImport?: boolean;
2872     }
2873     /**
2874      * ResolvedModule with an explicitly provided `extension` property.
2875      * Prefer this over `ResolvedModule`.
2876      * If changing this, remember to change `moduleResolutionIsEqualTo`.
2877      */
2878     export interface ResolvedModuleFull extends ResolvedModule {
2879         /**
2880          * Extension of resolvedFileName. This must match what's at the end of resolvedFileName.
2881          * This is optional for backwards-compatibility, but will be added if not provided.
2882          */
2883         extension: Extension;
2884         packageId?: PackageId;
2885     }
2886     /**
2887      * Unique identifier with a package name and version.
2888      * If changing this, remember to change `packageIdIsEqual`.
2889      */
2890     export interface PackageId {
2891         /**
2892          * Name of the package.
2893          * Should not include `@types`.
2894          * If accessing a non-index file, this should include its name e.g. "foo/bar".
2895          */
2896         name: string;
2897         /**
2898          * Name of a submodule within this package.
2899          * May be "".
2900          */
2901         subModuleName: string;
2902         /** Version of the package, e.g. "1.2.3" */
2903         version: string;
2904     }
2905     export enum Extension {
2906         Ts = ".ts",
2907         Tsx = ".tsx",
2908         Dts = ".d.ts",
2909         Js = ".js",
2910         Jsx = ".jsx",
2911         Json = ".json",
2912         TsBuildInfo = ".tsbuildinfo"
2913     }
2914     export interface ResolvedModuleWithFailedLookupLocations {
2915         readonly resolvedModule: ResolvedModuleFull | undefined;
2916     }
2917     export interface ResolvedTypeReferenceDirective {
2918         primary: boolean;
2919         resolvedFileName: string | undefined;
2920         packageId?: PackageId;
2921         /** True if `resolvedFileName` comes from `node_modules`. */
2922         isExternalLibraryImport?: boolean;
2923     }
2924     export interface ResolvedTypeReferenceDirectiveWithFailedLookupLocations {
2925         readonly resolvedTypeReferenceDirective: ResolvedTypeReferenceDirective | undefined;
2926         readonly failedLookupLocations: string[];
2927     }
2928     export interface CompilerHost extends ModuleResolutionHost {
2929         getSourceFile(fileName: string, languageVersion: ScriptTarget, onError?: (message: string) => void, shouldCreateNewSourceFile?: boolean): SourceFile | undefined;
2930         getSourceFileByPath?(fileName: string, path: Path, languageVersion: ScriptTarget, onError?: (message: string) => void, shouldCreateNewSourceFile?: boolean): SourceFile | undefined;
2931         getCancellationToken?(): CancellationToken;
2932         getDefaultLibFileName(options: CompilerOptions): string;
2933         getDefaultLibLocation?(): string;
2934         writeFile: WriteFileCallback;
2935         getCurrentDirectory(): string;
2936         getCanonicalFileName(fileName: string): string;
2937         useCaseSensitiveFileNames(): boolean;
2938         getNewLine(): string;
2939         readDirectory?(rootDir: string, extensions: readonly string[], excludes: readonly string[] | undefined, includes: readonly string[], depth?: number): string[];
2940         resolveModuleNames?(moduleNames: string[], containingFile: string, reusedNames: string[] | undefined, redirectedReference: ResolvedProjectReference | undefined, options: CompilerOptions): (ResolvedModule | undefined)[];
2941         /**
2942          * This method is a companion for 'resolveModuleNames' and is used to resolve 'types' references to actual type declaration files
2943          */
2944         resolveTypeReferenceDirectives?(typeReferenceDirectiveNames: string[], containingFile: string, redirectedReference: ResolvedProjectReference | undefined, options: CompilerOptions): (ResolvedTypeReferenceDirective | undefined)[];
2945         getEnvironmentVariable?(name: string): string | undefined;
2946         createHash?(data: string): string;
2947         getParsedCommandLine?(fileName: string): ParsedCommandLine | undefined;
2948     }
2949     export interface SourceMapRange extends TextRange {
2950         source?: SourceMapSource;
2951     }
2952     export interface SourceMapSource {
2953         fileName: string;
2954         text: string;
2955         skipTrivia?: (pos: number) => number;
2956     }
2957     export enum EmitFlags {
2958         None = 0,
2959         SingleLine = 1,
2960         AdviseOnEmitNode = 2,
2961         NoSubstitution = 4,
2962         CapturesThis = 8,
2963         NoLeadingSourceMap = 16,
2964         NoTrailingSourceMap = 32,
2965         NoSourceMap = 48,
2966         NoNestedSourceMaps = 64,
2967         NoTokenLeadingSourceMaps = 128,
2968         NoTokenTrailingSourceMaps = 256,
2969         NoTokenSourceMaps = 384,
2970         NoLeadingComments = 512,
2971         NoTrailingComments = 1024,
2972         NoComments = 1536,
2973         NoNestedComments = 2048,
2974         HelperName = 4096,
2975         ExportName = 8192,
2976         LocalName = 16384,
2977         InternalName = 32768,
2978         Indented = 65536,
2979         NoIndentation = 131072,
2980         AsyncFunctionBody = 262144,
2981         ReuseTempVariableScope = 524288,
2982         CustomPrologue = 1048576,
2983         NoHoisting = 2097152,
2984         HasEndOfDeclarationMarker = 4194304,
2985         Iterator = 8388608,
2986         NoAsciiEscaping = 16777216,
2987     }
2988     export interface EmitHelper {
2989         readonly name: string;
2990         readonly scoped: boolean;
2991         readonly text: string | ((node: EmitHelperUniqueNameCallback) => string);
2992         readonly priority?: number;
2993         readonly dependencies?: EmitHelper[];
2994     }
2995     export interface UnscopedEmitHelper extends EmitHelper {
2996         readonly scoped: false;
2997         readonly text: string;
2998     }
2999     export type EmitHelperUniqueNameCallback = (name: string) => string;
3000     export enum EmitHint {
3001         SourceFile = 0,
3002         Expression = 1,
3003         IdentifierName = 2,
3004         MappedTypeParameter = 3,
3005         Unspecified = 4,
3006         EmbeddedStatement = 5,
3007         JsxAttributeValue = 6
3008     }
3009     export interface TransformationContext {
3010         /** Gets the compiler options supplied to the transformer. */
3011         getCompilerOptions(): CompilerOptions;
3012         /** Starts a new lexical environment. */
3013         startLexicalEnvironment(): void;
3014         /** Suspends the current lexical environment, usually after visiting a parameter list. */
3015         suspendLexicalEnvironment(): void;
3016         /** Resumes a suspended lexical environment, usually before visiting a function body. */
3017         resumeLexicalEnvironment(): void;
3018         /** Ends a lexical environment, returning any declarations. */
3019         endLexicalEnvironment(): Statement[] | undefined;
3020         /** Hoists a function declaration to the containing scope. */
3021         hoistFunctionDeclaration(node: FunctionDeclaration): void;
3022         /** Hoists a variable declaration to the containing scope. */
3023         hoistVariableDeclaration(node: Identifier): void;
3024         /** Records a request for a non-scoped emit helper in the current context. */
3025         requestEmitHelper(helper: EmitHelper): void;
3026         /** Gets and resets the requested non-scoped emit helpers. */
3027         readEmitHelpers(): EmitHelper[] | undefined;
3028         /** Enables expression substitutions in the pretty printer for the provided SyntaxKind. */
3029         enableSubstitution(kind: SyntaxKind): void;
3030         /** Determines whether expression substitutions are enabled for the provided node. */
3031         isSubstitutionEnabled(node: Node): boolean;
3032         /**
3033          * Hook used by transformers to substitute expressions just before they
3034          * are emitted by the pretty printer.
3035          *
3036          * NOTE: Transformation hooks should only be modified during `Transformer` initialization,
3037          * before returning the `NodeTransformer` callback.
3038          */
3039         onSubstituteNode: (hint: EmitHint, node: Node) => Node;
3040         /**
3041          * Enables before/after emit notifications in the pretty printer for the provided
3042          * SyntaxKind.
3043          */
3044         enableEmitNotification(kind: SyntaxKind): void;
3045         /**
3046          * Determines whether before/after emit notifications should be raised in the pretty
3047          * printer when it emits a node.
3048          */
3049         isEmitNotificationEnabled(node: Node): boolean;
3050         /**
3051          * Hook used to allow transformers to capture state before or after
3052          * the printer emits a node.
3053          *
3054          * NOTE: Transformation hooks should only be modified during `Transformer` initialization,
3055          * before returning the `NodeTransformer` callback.
3056          */
3057         onEmitNode: (hint: EmitHint, node: Node, emitCallback: (hint: EmitHint, node: Node) => void) => void;
3058     }
3059     export interface TransformationResult<T extends Node> {
3060         /** Gets the transformed source files. */
3061         transformed: T[];
3062         /** Gets diagnostics for the transformation. */
3063         diagnostics?: DiagnosticWithLocation[];
3064         /**
3065          * Gets a substitute for a node, if one is available; otherwise, returns the original node.
3066          *
3067          * @param hint A hint as to the intended usage of the node.
3068          * @param node The node to substitute.
3069          */
3070         substituteNode(hint: EmitHint, node: Node): Node;
3071         /**
3072          * Emits a node with possible notification.
3073          *
3074          * @param hint A hint as to the intended usage of the node.
3075          * @param node The node to emit.
3076          * @param emitCallback A callback used to emit the node.
3077          */
3078         emitNodeWithNotification(hint: EmitHint, node: Node, emitCallback: (hint: EmitHint, node: Node) => void): void;
3079         /**
3080          * Indicates if a given node needs an emit notification
3081          *
3082          * @param node The node to emit.
3083          */
3084         isEmitNotificationEnabled?(node: Node): boolean;
3085         /**
3086          * Clean up EmitNode entries on any parse-tree nodes.
3087          */
3088         dispose(): void;
3089     }
3090     /**
3091      * A function that is used to initialize and return a `Transformer` callback, which in turn
3092      * will be used to transform one or more nodes.
3093      */
3094     export type TransformerFactory<T extends Node> = (context: TransformationContext) => Transformer<T>;
3095     /**
3096      * A function that transforms a node.
3097      */
3098     export type Transformer<T extends Node> = (node: T) => T;
3099     /**
3100      * A function that accepts and possibly transforms a node.
3101      */
3102     export type Visitor = (node: Node) => VisitResult<Node>;
3103     export type VisitResult<T extends Node> = T | T[] | undefined;
3104     export interface Printer {
3105         /**
3106          * Print a node and its subtree as-is, without any emit transformations.
3107          * @param hint A value indicating the purpose of a node. This is primarily used to
3108          * distinguish between an `Identifier` used in an expression position, versus an
3109          * `Identifier` used as an `IdentifierName` as part of a declaration. For most nodes you
3110          * should just pass `Unspecified`.
3111          * @param node The node to print. The node and its subtree are printed as-is, without any
3112          * emit transformations.
3113          * @param sourceFile A source file that provides context for the node. The source text of
3114          * the file is used to emit the original source content for literals and identifiers, while
3115          * the identifiers of the source file are used when generating unique names to avoid
3116          * collisions.
3117          */
3118         printNode(hint: EmitHint, node: Node, sourceFile: SourceFile): string;
3119         /**
3120          * Prints a list of nodes using the given format flags
3121          */
3122         printList<T extends Node>(format: ListFormat, list: NodeArray<T>, sourceFile: SourceFile): string;
3123         /**
3124          * Prints a source file as-is, without any emit transformations.
3125          */
3126         printFile(sourceFile: SourceFile): string;
3127         /**
3128          * Prints a bundle of source files as-is, without any emit transformations.
3129          */
3130         printBundle(bundle: Bundle): string;
3131     }
3132     export interface PrintHandlers {
3133         /**
3134          * A hook used by the Printer when generating unique names to avoid collisions with
3135          * globally defined names that exist outside of the current source file.
3136          */
3137         hasGlobalName?(name: string): boolean;
3138         /**
3139          * A hook used by the Printer to provide notifications prior to emitting a node. A
3140          * compatible implementation **must** invoke `emitCallback` with the provided `hint` and
3141          * `node` values.
3142          * @param hint A hint indicating the intended purpose of the node.
3143          * @param node The node to emit.
3144          * @param emitCallback A callback that, when invoked, will emit the node.
3145          * @example
3146          * ```ts
3147          * var printer = createPrinter(printerOptions, {
3148          *   onEmitNode(hint, node, emitCallback) {
3149          *     // set up or track state prior to emitting the node...
3150          *     emitCallback(hint, node);
3151          *     // restore state after emitting the node...
3152          *   }
3153          * });
3154          * ```
3155          */
3156         onEmitNode?(hint: EmitHint, node: Node | undefined, emitCallback: (hint: EmitHint, node: Node | undefined) => void): void;
3157         /**
3158          * A hook used to check if an emit notification is required for a node.
3159          * @param node The node to emit.
3160          */
3161         isEmitNotificationEnabled?(node: Node | undefined): boolean;
3162         /**
3163          * A hook used by the Printer to perform just-in-time substitution of a node. This is
3164          * primarily used by node transformations that need to substitute one node for another,
3165          * such as replacing `myExportedVar` with `exports.myExportedVar`.
3166          * @param hint A hint indicating the intended purpose of the node.
3167          * @param node The node to emit.
3168          * @example
3169          * ```ts
3170          * var printer = createPrinter(printerOptions, {
3171          *   substituteNode(hint, node) {
3172          *     // perform substitution if necessary...
3173          *     return node;
3174          *   }
3175          * });
3176          * ```
3177          */
3178         substituteNode?(hint: EmitHint, node: Node): Node;
3179     }
3180     export interface PrinterOptions {
3181         removeComments?: boolean;
3182         newLine?: NewLineKind;
3183         omitTrailingSemicolon?: boolean;
3184         noEmitHelpers?: boolean;
3185     }
3186     export interface GetEffectiveTypeRootsHost {
3187         directoryExists?(directoryName: string): boolean;
3188         getCurrentDirectory?(): string;
3189     }
3190     export interface TextSpan {
3191         start: number;
3192         length: number;
3193     }
3194     export interface TextChangeRange {
3195         span: TextSpan;
3196         newLength: number;
3197     }
3198     export interface SyntaxList extends Node {
3199         _children: Node[];
3200     }
3201     export enum ListFormat {
3202         None = 0,
3203         SingleLine = 0,
3204         MultiLine = 1,
3205         PreserveLines = 2,
3206         LinesMask = 3,
3207         NotDelimited = 0,
3208         BarDelimited = 4,
3209         AmpersandDelimited = 8,
3210         CommaDelimited = 16,
3211         AsteriskDelimited = 32,
3212         DelimitersMask = 60,
3213         AllowTrailingComma = 64,
3214         Indented = 128,
3215         SpaceBetweenBraces = 256,
3216         SpaceBetweenSiblings = 512,
3217         Braces = 1024,
3218         Parenthesis = 2048,
3219         AngleBrackets = 4096,
3220         SquareBrackets = 8192,
3221         BracketsMask = 15360,
3222         OptionalIfUndefined = 16384,
3223         OptionalIfEmpty = 32768,
3224         Optional = 49152,
3225         PreferNewLine = 65536,
3226         NoTrailingNewLine = 131072,
3227         NoInterveningComments = 262144,
3228         NoSpaceIfEmpty = 524288,
3229         SingleElement = 1048576,
3230         SpaceAfterList = 2097152,
3231         Modifiers = 262656,
3232         HeritageClauses = 512,
3233         SingleLineTypeLiteralMembers = 768,
3234         MultiLineTypeLiteralMembers = 32897,
3235         TupleTypeElements = 528,
3236         UnionTypeConstituents = 516,
3237         IntersectionTypeConstituents = 520,
3238         ObjectBindingPatternElements = 525136,
3239         ArrayBindingPatternElements = 524880,
3240         ObjectLiteralExpressionProperties = 526226,
3241         ArrayLiteralExpressionElements = 8914,
3242         CommaListElements = 528,
3243         CallExpressionArguments = 2576,
3244         NewExpressionArguments = 18960,
3245         TemplateExpressionSpans = 262144,
3246         SingleLineBlockStatements = 768,
3247         MultiLineBlockStatements = 129,
3248         VariableDeclarationList = 528,
3249         SingleLineFunctionBodyStatements = 768,
3250         MultiLineFunctionBodyStatements = 1,
3251         ClassHeritageClauses = 0,
3252         ClassMembers = 129,
3253         InterfaceMembers = 129,
3254         EnumMembers = 145,
3255         CaseBlockClauses = 129,
3256         NamedImportsOrExportsElements = 525136,
3257         JsxElementOrFragmentChildren = 262144,
3258         JsxElementAttributes = 262656,
3259         CaseOrDefaultClauseStatements = 163969,
3260         HeritageClauseTypes = 528,
3261         SourceFileStatements = 131073,
3262         Decorators = 2146305,
3263         TypeArguments = 53776,
3264         TypeParameters = 53776,
3265         Parameters = 2576,
3266         IndexSignatureParameters = 8848,
3267         JSDocComment = 33
3268     }
3269     export interface UserPreferences {
3270         readonly disableSuggestions?: boolean;
3271         readonly quotePreference?: "auto" | "double" | "single";
3272         readonly includeCompletionsForModuleExports?: boolean;
3273         readonly includeAutomaticOptionalChainCompletions?: boolean;
3274         readonly includeCompletionsWithInsertText?: boolean;
3275         readonly importModuleSpecifierPreference?: "auto" | "relative" | "non-relative";
3276         /** Determines whether we import `foo/index.ts` as "foo", "foo/index", or "foo/index.js" */
3277         readonly importModuleSpecifierEnding?: "auto" | "minimal" | "index" | "js";
3278         readonly allowTextChangesInNewFiles?: boolean;
3279         readonly providePrefixAndSuffixTextForRename?: boolean;
3280     }
3281     /** Represents a bigint literal value without requiring bigint support */
3282     export interface PseudoBigInt {
3283         negative: boolean;
3284         base10Value: string;
3285     }
3286     export {};
3287 }
3288 declare function setTimeout(handler: (...args: any[]) => void, timeout: number): any;
3289 declare function clearTimeout(handle: any): void;
3290 declare namespace ts {
3291     export enum FileWatcherEventKind {
3292         Created = 0,
3293         Changed = 1,
3294         Deleted = 2
3295     }
3296     export type FileWatcherCallback = (fileName: string, eventKind: FileWatcherEventKind) => void;
3297     export type DirectoryWatcherCallback = (fileName: string) => void;
3298     export interface System {
3299         args: string[];
3300         newLine: string;
3301         useCaseSensitiveFileNames: boolean;
3302         write(s: string): void;
3303         writeOutputIsTTY?(): boolean;
3304         readFile(path: string, encoding?: string): string | undefined;
3305         getFileSize?(path: string): number;
3306         writeFile(path: string, data: string, writeByteOrderMark?: boolean): void;
3307         /**
3308          * @pollingInterval - this parameter is used in polling-based watchers and ignored in watchers that
3309          * use native OS file watching
3310          */
3311         watchFile?(path: string, callback: FileWatcherCallback, pollingInterval?: number, options?: WatchOptions): FileWatcher;
3312         watchDirectory?(path: string, callback: DirectoryWatcherCallback, recursive?: boolean, options?: WatchOptions): FileWatcher;
3313         resolvePath(path: string): string;
3314         fileExists(path: string): boolean;
3315         directoryExists(path: string): boolean;
3316         createDirectory(path: string): void;
3317         getExecutingFilePath(): string;
3318         getCurrentDirectory(): string;
3319         getDirectories(path: string): string[];
3320         readDirectory(path: string, extensions?: readonly string[], exclude?: readonly string[], include?: readonly string[], depth?: number): string[];
3321         getModifiedTime?(path: string): Date | undefined;
3322         setModifiedTime?(path: string, time: Date): void;
3323         deleteFile?(path: string): void;
3324         /**
3325          * A good implementation is node.js' `crypto.createHash`. (https://nodejs.org/api/crypto.html#crypto_crypto_createhash_algorithm)
3326          */
3327         createHash?(data: string): string;
3328         /** This must be cryptographically secure. Only implement this method using `crypto.createHash("sha256")`. */
3329         createSHA256Hash?(data: string): string;
3330         getMemoryUsage?(): number;
3331         exit(exitCode?: number): void;
3332         realpath?(path: string): string;
3333         setTimeout?(callback: (...args: any[]) => void, ms: number, ...args: any[]): any;
3334         clearTimeout?(timeoutId: any): void;
3335         clearScreen?(): void;
3336         base64decode?(input: string): string;
3337         base64encode?(input: string): string;
3338     }
3339     export interface FileWatcher {
3340         close(): void;
3341     }
3342     export function getNodeMajorVersion(): number | undefined;
3343     export let sys: System;
3344     export {};
3345 }
3346 declare namespace ts {
3347     type ErrorCallback = (message: DiagnosticMessage, length: number) => void;
3348     interface Scanner {
3349         getStartPos(): number;
3350         getToken(): SyntaxKind;
3351         getTextPos(): number;
3352         getTokenPos(): number;
3353         getTokenText(): string;
3354         getTokenValue(): string;
3355         hasUnicodeEscape(): boolean;
3356         hasExtendedUnicodeEscape(): boolean;
3357         hasPrecedingLineBreak(): boolean;
3358         isIdentifier(): boolean;
3359         isReservedWord(): boolean;
3360         isUnterminated(): boolean;
3361         reScanGreaterToken(): SyntaxKind;
3362         reScanSlashToken(): SyntaxKind;
3363         reScanTemplateToken(isTaggedTemplate: boolean): SyntaxKind;
3364         reScanTemplateHeadOrNoSubstitutionTemplate(): SyntaxKind;
3365         scanJsxIdentifier(): SyntaxKind;
3366         scanJsxAttributeValue(): SyntaxKind;
3367         reScanJsxAttributeValue(): SyntaxKind;
3368         reScanJsxToken(): JsxTokenSyntaxKind;
3369         reScanLessThanToken(): SyntaxKind;
3370         reScanQuestionToken(): SyntaxKind;
3371         scanJsxToken(): JsxTokenSyntaxKind;
3372         scanJsDocToken(): JSDocSyntaxKind;
3373         scan(): SyntaxKind;
3374         getText(): string;
3375         setText(text: string | undefined, start?: number, length?: number): void;
3376         setOnError(onError: ErrorCallback | undefined): void;
3377         setScriptTarget(scriptTarget: ScriptTarget): void;
3378         setLanguageVariant(variant: LanguageVariant): void;
3379         setTextPos(textPos: number): void;
3380         lookAhead<T>(callback: () => T): T;
3381         scanRange<T>(start: number, length: number, callback: () => T): T;
3382         tryScan<T>(callback: () => T): T;
3383     }
3384     function tokenToString(t: SyntaxKind): string | undefined;
3385     function getPositionOfLineAndCharacter(sourceFile: SourceFileLike, line: number, character: number): number;
3386     function getLineAndCharacterOfPosition(sourceFile: SourceFileLike, position: number): LineAndCharacter;
3387     function isWhiteSpaceLike(ch: number): boolean;
3388     /** Does not include line breaks. For that, see isWhiteSpaceLike. */
3389     function isWhiteSpaceSingleLine(ch: number): boolean;
3390     function isLineBreak(ch: number): boolean;
3391     function couldStartTrivia(text: string, pos: number): boolean;
3392     function forEachLeadingCommentRange<U>(text: string, pos: number, cb: (pos: number, end: number, kind: CommentKind, hasTrailingNewLine: boolean) => U): U | undefined;
3393     function forEachLeadingCommentRange<T, U>(text: string, pos: number, cb: (pos: number, end: number, kind: CommentKind, hasTrailingNewLine: boolean, state: T) => U, state: T): U | undefined;
3394     function forEachTrailingCommentRange<U>(text: string, pos: number, cb: (pos: number, end: number, kind: CommentKind, hasTrailingNewLine: boolean) => U): U | undefined;
3395     function forEachTrailingCommentRange<T, U>(text: string, pos: number, cb: (pos: number, end: number, kind: CommentKind, hasTrailingNewLine: boolean, state: T) => U, state: T): U | undefined;
3396     function reduceEachLeadingCommentRange<T, U>(text: string, pos: number, cb: (pos: number, end: number, kind: CommentKind, hasTrailingNewLine: boolean, state: T, memo: U) => U, state: T, initial: U): U | undefined;
3397     function reduceEachTrailingCommentRange<T, U>(text: string, pos: number, cb: (pos: number, end: number, kind: CommentKind, hasTrailingNewLine: boolean, state: T, memo: U) => U, state: T, initial: U): U | undefined;
3398     function getLeadingCommentRanges(text: string, pos: number): CommentRange[] | undefined;
3399     function getTrailingCommentRanges(text: string, pos: number): CommentRange[] | undefined;
3400     /** Optionally, get the shebang */
3401     function getShebang(text: string): string | undefined;
3402     function isIdentifierStart(ch: number, languageVersion: ScriptTarget | undefined): boolean;
3403     function isIdentifierPart(ch: number, languageVersion: ScriptTarget | undefined, identifierVariant?: LanguageVariant): boolean;
3404     function createScanner(languageVersion: ScriptTarget, skipTrivia: boolean, languageVariant?: LanguageVariant, textInitial?: string, onError?: ErrorCallback, start?: number, length?: number): Scanner;
3405 }
3406 declare namespace ts {
3407     function isExternalModuleNameRelative(moduleName: string): boolean;
3408     function sortAndDeduplicateDiagnostics<T extends Diagnostic>(diagnostics: readonly T[]): SortedReadonlyArray<T>;
3409     function getDefaultLibFileName(options: CompilerOptions): string;
3410     function textSpanEnd(span: TextSpan): number;
3411     function textSpanIsEmpty(span: TextSpan): boolean;
3412     function textSpanContainsPosition(span: TextSpan, position: number): boolean;
3413     function textSpanContainsTextSpan(span: TextSpan, other: TextSpan): boolean;
3414     function textSpanOverlapsWith(span: TextSpan, other: TextSpan): boolean;
3415     function textSpanOverlap(span1: TextSpan, span2: TextSpan): TextSpan | undefined;
3416     function textSpanIntersectsWithTextSpan(span: TextSpan, other: TextSpan): boolean;
3417     function textSpanIntersectsWith(span: TextSpan, start: number, length: number): boolean;
3418     function decodedTextSpanIntersectsWith(start1: number, length1: number, start2: number, length2: number): boolean;
3419     function textSpanIntersectsWithPosition(span: TextSpan, position: number): boolean;
3420     function textSpanIntersection(span1: TextSpan, span2: TextSpan): TextSpan | undefined;
3421     function createTextSpan(start: number, length: number): TextSpan;
3422     function createTextSpanFromBounds(start: number, end: number): TextSpan;
3423     function textChangeRangeNewSpan(range: TextChangeRange): TextSpan;
3424     function textChangeRangeIsUnchanged(range: TextChangeRange): boolean;
3425     function createTextChangeRange(span: TextSpan, newLength: number): TextChangeRange;
3426     let unchangedTextChangeRange: TextChangeRange;
3427     /**
3428      * Called to merge all the changes that occurred across several versions of a script snapshot
3429      * into a single change.  i.e. if a user keeps making successive edits to a script we will
3430      * have a text change from V1 to V2, V2 to V3, ..., Vn.
3431      *
3432      * This function will then merge those changes into a single change range valid between V1 and
3433      * Vn.
3434      */
3435     function collapseTextChangeRangesAcrossMultipleVersions(changes: readonly TextChangeRange[]): TextChangeRange;
3436     function getTypeParameterOwner(d: Declaration): Declaration | undefined;
3437     type ParameterPropertyDeclaration = ParameterDeclaration & {
3438         parent: ConstructorDeclaration;
3439         name: Identifier;
3440     };
3441     function isParameterPropertyDeclaration(node: Node, parent: Node): node is ParameterPropertyDeclaration;
3442     function isEmptyBindingPattern(node: BindingName): node is BindingPattern;
3443     function isEmptyBindingElement(node: BindingElement): boolean;
3444     function walkUpBindingElementsAndPatterns(binding: BindingElement): VariableDeclaration | ParameterDeclaration;
3445     function getCombinedModifierFlags(node: Declaration): ModifierFlags;
3446     function getCombinedNodeFlags(node: Node): NodeFlags;
3447     /**
3448      * Checks to see if the locale is in the appropriate format,
3449      * and if it is, attempts to set the appropriate language.
3450      */
3451     function validateLocaleAndSetLanguage(locale: string, sys: {
3452         getExecutingFilePath(): string;
3453         resolvePath(path: string): string;
3454         fileExists(fileName: string): boolean;
3455         readFile(fileName: string): string | undefined;
3456     }, errors?: Push<Diagnostic>): void;
3457     function getOriginalNode(node: Node): Node;
3458     function getOriginalNode<T extends Node>(node: Node, nodeTest: (node: Node) => node is T): T;
3459     function getOriginalNode(node: Node | undefined): Node | undefined;
3460     function getOriginalNode<T extends Node>(node: Node | undefined, nodeTest: (node: Node | undefined) => node is T): T | undefined;
3461     /**
3462      * Gets a value indicating whether a node originated in the parse tree.
3463      *
3464      * @param node The node to test.
3465      */
3466     function isParseTreeNode(node: Node): boolean;
3467     /**
3468      * Gets the original parse tree node for a node.
3469      *
3470      * @param node The original node.
3471      * @returns The original parse tree node if found; otherwise, undefined.
3472      */
3473     function getParseTreeNode(node: Node): Node;
3474     /**
3475      * Gets the original parse tree node for a node.
3476      *
3477      * @param node The original node.
3478      * @param nodeTest A callback used to ensure the correct type of parse tree node is returned.
3479      * @returns The original parse tree node if found; otherwise, undefined.
3480      */
3481     function getParseTreeNode<T extends Node>(node: Node | undefined, nodeTest?: (node: Node) => node is T): T | undefined;
3482     /** Add an extra underscore to identifiers that start with two underscores to avoid issues with magic names like '__proto__' */
3483     function escapeLeadingUnderscores(identifier: string): __String;
3484     /**
3485      * Remove extra underscore from escaped identifier text content.
3486      *
3487      * @param identifier The escaped identifier text.
3488      * @returns The unescaped identifier text.
3489      */
3490     function unescapeLeadingUnderscores(identifier: __String): string;
3491     function idText(identifierOrPrivateName: Identifier | PrivateIdentifier): string;
3492     function symbolName(symbol: Symbol): string;
3493     function getNameOfJSDocTypedef(declaration: JSDocTypedefTag): Identifier | PrivateIdentifier | undefined;
3494     function getNameOfDeclaration(declaration: Declaration | Expression): DeclarationName | undefined;
3495     /**
3496      * Gets the JSDoc parameter tags for the node if present.
3497      *
3498      * @remarks Returns any JSDoc param tag whose name matches the provided
3499      * parameter, whether a param tag on a containing function
3500      * expression, or a param tag on a variable declaration whose
3501      * initializer is the containing function. The tags closest to the
3502      * node are returned first, so in the previous example, the param
3503      * tag on the containing function expression would be first.
3504      *
3505      * For binding patterns, parameter tags are matched by position.
3506      */
3507     function getJSDocParameterTags(param: ParameterDeclaration): readonly JSDocParameterTag[];
3508     /**
3509      * Gets the JSDoc type parameter tags for the node if present.
3510      *
3511      * @remarks Returns any JSDoc template tag whose names match the provided
3512      * parameter, whether a template tag on a containing function
3513      * expression, or a template tag on a variable declaration whose
3514      * initializer is the containing function. The tags closest to the
3515      * node are returned first, so in the previous example, the template
3516      * tag on the containing function expression would be first.
3517      */
3518     function getJSDocTypeParameterTags(param: TypeParameterDeclaration): readonly JSDocTemplateTag[];
3519     /**
3520      * Return true if the node has JSDoc parameter tags.
3521      *
3522      * @remarks Includes parameter tags that are not directly on the node,
3523      * for example on a variable declaration whose initializer is a function expression.
3524      */
3525     function hasJSDocParameterTags(node: FunctionLikeDeclaration | SignatureDeclaration): boolean;
3526     /** Gets the JSDoc augments tag for the node if present */
3527     function getJSDocAugmentsTag(node: Node): JSDocAugmentsTag | undefined;
3528     /** Gets the JSDoc implements tags for the node if present */
3529     function getJSDocImplementsTags(node: Node): readonly JSDocImplementsTag[];
3530     /** Gets the JSDoc class tag for the node if present */
3531     function getJSDocClassTag(node: Node): JSDocClassTag | undefined;
3532     /** Gets the JSDoc public tag for the node if present */
3533     function getJSDocPublicTag(node: Node): JSDocPublicTag | undefined;
3534     /** Gets the JSDoc private tag for the node if present */
3535     function getJSDocPrivateTag(node: Node): JSDocPrivateTag | undefined;
3536     /** Gets the JSDoc protected tag for the node if present */
3537     function getJSDocProtectedTag(node: Node): JSDocProtectedTag | undefined;
3538     /** Gets the JSDoc protected tag for the node if present */
3539     function getJSDocReadonlyTag(node: Node): JSDocReadonlyTag | undefined;
3540     /** Gets the JSDoc enum tag for the node if present */
3541     function getJSDocEnumTag(node: Node): JSDocEnumTag | undefined;
3542     /** Gets the JSDoc this tag for the node if present */
3543     function getJSDocThisTag(node: Node): JSDocThisTag | undefined;
3544     /** Gets the JSDoc return tag for the node if present */
3545     function getJSDocReturnTag(node: Node): JSDocReturnTag | undefined;
3546     /** Gets the JSDoc template tag for the node if present */
3547     function getJSDocTemplateTag(node: Node): JSDocTemplateTag | undefined;
3548     /** Gets the JSDoc type tag for the node if present and valid */
3549     function getJSDocTypeTag(node: Node): JSDocTypeTag | undefined;
3550     /**
3551      * Gets the type node for the node if provided via JSDoc.
3552      *
3553      * @remarks The search includes any JSDoc param tag that relates
3554      * to the provided parameter, for example a type tag on the
3555      * parameter itself, or a param tag on a containing function
3556      * expression, or a param tag on a variable declaration whose
3557      * initializer is the containing function. The tags closest to the
3558      * node are examined first, so in the previous example, the type
3559      * tag directly on the node would be returned.
3560      */
3561     function getJSDocType(node: Node): TypeNode | undefined;
3562     /**
3563      * Gets the return type node for the node if provided via JSDoc return tag or type tag.
3564      *
3565      * @remarks `getJSDocReturnTag` just gets the whole JSDoc tag. This function
3566      * gets the type from inside the braces, after the fat arrow, etc.
3567      */
3568     function getJSDocReturnType(node: Node): TypeNode | undefined;
3569     /** Get all JSDoc tags related to a node, including those on parent nodes. */
3570     function getJSDocTags(node: Node): readonly JSDocTag[];
3571     /** Gets all JSDoc tags that match a specified predicate */
3572     function getAllJSDocTags<T extends JSDocTag>(node: Node, predicate: (tag: JSDocTag) => tag is T): readonly T[];
3573     /** Gets all JSDoc tags of a specified kind */
3574     function getAllJSDocTagsOfKind(node: Node, kind: SyntaxKind): readonly JSDocTag[];
3575     /**
3576      * Gets the effective type parameters. If the node was parsed in a
3577      * JavaScript file, gets the type parameters from the `@template` tag from JSDoc.
3578      */
3579     function getEffectiveTypeParameterDeclarations(node: DeclarationWithTypeParameters): readonly TypeParameterDeclaration[];
3580     function getEffectiveConstraintOfTypeParameter(node: TypeParameterDeclaration): TypeNode | undefined;
3581     function isNumericLiteral(node: Node): node is NumericLiteral;
3582     function isBigIntLiteral(node: Node): node is BigIntLiteral;
3583     function isStringLiteral(node: Node): node is StringLiteral;
3584     function isJsxText(node: Node): node is JsxText;
3585     function isRegularExpressionLiteral(node: Node): node is RegularExpressionLiteral;
3586     function isNoSubstitutionTemplateLiteral(node: Node): node is NoSubstitutionTemplateLiteral;
3587     function isTemplateHead(node: Node): node is TemplateHead;
3588     function isTemplateMiddle(node: Node): node is TemplateMiddle;
3589     function isTemplateTail(node: Node): node is TemplateTail;
3590     function isIdentifier(node: Node): node is Identifier;
3591     function isQualifiedName(node: Node): node is QualifiedName;
3592     function isComputedPropertyName(node: Node): node is ComputedPropertyName;
3593     function isPrivateIdentifier(node: Node): node is PrivateIdentifier;
3594     function isIdentifierOrPrivateIdentifier(node: Node): node is Identifier | PrivateIdentifier;
3595     function isTypeParameterDeclaration(node: Node): node is TypeParameterDeclaration;
3596     function isParameter(node: Node): node is ParameterDeclaration;
3597     function isDecorator(node: Node): node is Decorator;
3598     function isPropertySignature(node: Node): node is PropertySignature;
3599     function isPropertyDeclaration(node: Node): node is PropertyDeclaration;
3600     function isMethodSignature(node: Node): node is MethodSignature;
3601     function isMethodDeclaration(node: Node): node is MethodDeclaration;
3602     function isConstructorDeclaration(node: Node): node is ConstructorDeclaration;
3603     function isGetAccessorDeclaration(node: Node): node is GetAccessorDeclaration;
3604     function isSetAccessorDeclaration(node: Node): node is SetAccessorDeclaration;
3605     function isCallSignatureDeclaration(node: Node): node is CallSignatureDeclaration;
3606     function isConstructSignatureDeclaration(node: Node): node is ConstructSignatureDeclaration;
3607     function isIndexSignatureDeclaration(node: Node): node is IndexSignatureDeclaration;
3608     function isTypePredicateNode(node: Node): node is TypePredicateNode;
3609     function isTypeReferenceNode(node: Node): node is TypeReferenceNode;
3610     function isFunctionTypeNode(node: Node): node is FunctionTypeNode;
3611     function isConstructorTypeNode(node: Node): node is ConstructorTypeNode;
3612     function isTypeQueryNode(node: Node): node is TypeQueryNode;
3613     function isTypeLiteralNode(node: Node): node is TypeLiteralNode;
3614     function isArrayTypeNode(node: Node): node is ArrayTypeNode;
3615     function isTupleTypeNode(node: Node): node is TupleTypeNode;
3616     function isUnionTypeNode(node: Node): node is UnionTypeNode;
3617     function isIntersectionTypeNode(node: Node): node is IntersectionTypeNode;
3618     function isConditionalTypeNode(node: Node): node is ConditionalTypeNode;
3619     function isInferTypeNode(node: Node): node is InferTypeNode;
3620     function isParenthesizedTypeNode(node: Node): node is ParenthesizedTypeNode;
3621     function isThisTypeNode(node: Node): node is ThisTypeNode;
3622     function isTypeOperatorNode(node: Node): node is TypeOperatorNode;
3623     function isIndexedAccessTypeNode(node: Node): node is IndexedAccessTypeNode;
3624     function isMappedTypeNode(node: Node): node is MappedTypeNode;
3625     function isLiteralTypeNode(node: Node): node is LiteralTypeNode;
3626     function isImportTypeNode(node: Node): node is ImportTypeNode;
3627     function isObjectBindingPattern(node: Node): node is ObjectBindingPattern;
3628     function isArrayBindingPattern(node: Node): node is ArrayBindingPattern;
3629     function isBindingElement(node: Node): node is BindingElement;
3630     function isArrayLiteralExpression(node: Node): node is ArrayLiteralExpression;
3631     function isObjectLiteralExpression(node: Node): node is ObjectLiteralExpression;
3632     function isPropertyAccessExpression(node: Node): node is PropertyAccessExpression;
3633     function isPropertyAccessChain(node: Node): node is PropertyAccessChain;
3634     function isElementAccessExpression(node: Node): node is ElementAccessExpression;
3635     function isElementAccessChain(node: Node): node is ElementAccessChain;
3636     function isCallExpression(node: Node): node is CallExpression;
3637     function isCallChain(node: Node): node is CallChain;
3638     function isOptionalChain(node: Node): node is PropertyAccessChain | ElementAccessChain | CallChain | NonNullChain;
3639     function isNullishCoalesce(node: Node): boolean;
3640     function isNewExpression(node: Node): node is NewExpression;
3641     function isTaggedTemplateExpression(node: Node): node is TaggedTemplateExpression;
3642     function isTypeAssertion(node: Node): node is TypeAssertion;
3643     function isConstTypeReference(node: Node): boolean;
3644     function isParenthesizedExpression(node: Node): node is ParenthesizedExpression;
3645     function skipPartiallyEmittedExpressions(node: Expression): Expression;
3646     function skipPartiallyEmittedExpressions(node: Node): Node;
3647     function isFunctionExpression(node: Node): node is FunctionExpression;
3648     function isArrowFunction(node: Node): node is ArrowFunction;
3649     function isDeleteExpression(node: Node): node is DeleteExpression;
3650     function isTypeOfExpression(node: Node): node is TypeOfExpression;
3651     function isVoidExpression(node: Node): node is VoidExpression;
3652     function isAwaitExpression(node: Node): node is AwaitExpression;
3653     function isPrefixUnaryExpression(node: Node): node is PrefixUnaryExpression;
3654     function isPostfixUnaryExpression(node: Node): node is PostfixUnaryExpression;
3655     function isBinaryExpression(node: Node): node is BinaryExpression;
3656     function isConditionalExpression(node: Node): node is ConditionalExpression;
3657     function isTemplateExpression(node: Node): node is TemplateExpression;
3658     function isYieldExpression(node: Node): node is YieldExpression;
3659     function isSpreadElement(node: Node): node is SpreadElement;
3660     function isClassExpression(node: Node): node is ClassExpression;
3661     function isOmittedExpression(node: Node): node is OmittedExpression;
3662     function isExpressionWithTypeArguments(node: Node): node is ExpressionWithTypeArguments;
3663     function isAsExpression(node: Node): node is AsExpression;
3664     function isNonNullExpression(node: Node): node is NonNullExpression;
3665     function isNonNullChain(node: Node): node is NonNullChain;
3666     function isMetaProperty(node: Node): node is MetaProperty;
3667     function isTemplateSpan(node: Node): node is TemplateSpan;
3668     function isSemicolonClassElement(node: Node): node is SemicolonClassElement;
3669     function isBlock(node: Node): node is Block;
3670     function isVariableStatement(node: Node): node is VariableStatement;
3671     function isEmptyStatement(node: Node): node is EmptyStatement;
3672     function isExpressionStatement(node: Node): node is ExpressionStatement;
3673     function isIfStatement(node: Node): node is IfStatement;
3674     function isDoStatement(node: Node): node is DoStatement;
3675     function isWhileStatement(node: Node): node is WhileStatement;
3676     function isForStatement(node: Node): node is ForStatement;
3677     function isForInStatement(node: Node): node is ForInStatement;
3678     function isForOfStatement(node: Node): node is ForOfStatement;
3679     function isContinueStatement(node: Node): node is ContinueStatement;
3680     function isBreakStatement(node: Node): node is BreakStatement;
3681     function isBreakOrContinueStatement(node: Node): node is BreakOrContinueStatement;
3682     function isReturnStatement(node: Node): node is ReturnStatement;
3683     function isWithStatement(node: Node): node is WithStatement;
3684     function isSwitchStatement(node: Node): node is SwitchStatement;
3685     function isLabeledStatement(node: Node): node is LabeledStatement;
3686     function isThrowStatement(node: Node): node is ThrowStatement;
3687     function isTryStatement(node: Node): node is TryStatement;
3688     function isDebuggerStatement(node: Node): node is DebuggerStatement;
3689     function isVariableDeclaration(node: Node): node is VariableDeclaration;
3690     function isVariableDeclarationList(node: Node): node is VariableDeclarationList;
3691     function isFunctionDeclaration(node: Node): node is FunctionDeclaration;
3692     function isClassDeclaration(node: Node): node is ClassDeclaration;
3693     function isInterfaceDeclaration(node: Node): node is InterfaceDeclaration;
3694     function isTypeAliasDeclaration(node: Node): node is TypeAliasDeclaration;
3695     function isEnumDeclaration(node: Node): node is EnumDeclaration;
3696     function isModuleDeclaration(node: Node): node is ModuleDeclaration;
3697     function isModuleBlock(node: Node): node is ModuleBlock;
3698     function isCaseBlock(node: Node): node is CaseBlock;
3699     function isNamespaceExportDeclaration(node: Node): node is NamespaceExportDeclaration;
3700     function isImportEqualsDeclaration(node: Node): node is ImportEqualsDeclaration;
3701     function isImportDeclaration(node: Node): node is ImportDeclaration;
3702     function isImportClause(node: Node): node is ImportClause;
3703     function isNamespaceImport(node: Node): node is NamespaceImport;
3704     function isNamespaceExport(node: Node): node is NamespaceExport;
3705     function isNamedExportBindings(node: Node): node is NamedExportBindings;
3706     function isNamedImports(node: Node): node is NamedImports;
3707     function isImportSpecifier(node: Node): node is ImportSpecifier;
3708     function isExportAssignment(node: Node): node is ExportAssignment;
3709     function isExportDeclaration(node: Node): node is ExportDeclaration;
3710     function isNamedExports(node: Node): node is NamedExports;
3711     function isExportSpecifier(node: Node): node is ExportSpecifier;
3712     function isMissingDeclaration(node: Node): node is MissingDeclaration;
3713     function isExternalModuleReference(node: Node): node is ExternalModuleReference;
3714     function isJsxElement(node: Node): node is JsxElement;
3715     function isJsxSelfClosingElement(node: Node): node is JsxSelfClosingElement;
3716     function isJsxOpeningElement(node: Node): node is JsxOpeningElement;
3717     function isJsxClosingElement(node: Node): node is JsxClosingElement;
3718     function isJsxFragment(node: Node): node is JsxFragment;
3719     function isJsxOpeningFragment(node: Node): node is JsxOpeningFragment;
3720     function isJsxClosingFragment(node: Node): node is JsxClosingFragment;
3721     function isJsxAttribute(node: Node): node is JsxAttribute;
3722     function isJsxAttributes(node: Node): node is JsxAttributes;
3723     function isJsxSpreadAttribute(node: Node): node is JsxSpreadAttribute;
3724     function isJsxExpression(node: Node): node is JsxExpression;
3725     function isCaseClause(node: Node): node is CaseClause;
3726     function isDefaultClause(node: Node): node is DefaultClause;
3727     function isHeritageClause(node: Node): node is HeritageClause;
3728     function isCatchClause(node: Node): node is CatchClause;
3729     function isPropertyAssignment(node: Node): node is PropertyAssignment;
3730     function isShorthandPropertyAssignment(node: Node): node is ShorthandPropertyAssignment;
3731     function isSpreadAssignment(node: Node): node is SpreadAssignment;
3732     function isEnumMember(node: Node): node is EnumMember;
3733     function isSourceFile(node: Node): node is SourceFile;
3734     function isBundle(node: Node): node is Bundle;
3735     function isUnparsedSource(node: Node): node is UnparsedSource;
3736     function isUnparsedPrepend(node: Node): node is UnparsedPrepend;
3737     function isUnparsedTextLike(node: Node): node is UnparsedTextLike;
3738     function isUnparsedNode(node: Node): node is UnparsedNode;
3739     function isJSDocTypeExpression(node: Node): node is JSDocTypeExpression;
3740     function isJSDocAllType(node: Node): node is JSDocAllType;
3741     function isJSDocUnknownType(node: Node): node is JSDocUnknownType;
3742     function isJSDocNullableType(node: Node): node is JSDocNullableType;
3743     function isJSDocNonNullableType(node: Node): node is JSDocNonNullableType;
3744     function isJSDocOptionalType(node: Node): node is JSDocOptionalType;
3745     function isJSDocFunctionType(node: Node): node is JSDocFunctionType;
3746     function isJSDocVariadicType(node: Node): node is JSDocVariadicType;
3747     function isJSDoc(node: Node): node is JSDoc;
3748     function isJSDocAuthorTag(node: Node): node is JSDocAuthorTag;
3749     function isJSDocAugmentsTag(node: Node): node is JSDocAugmentsTag;
3750     function isJSDocImplementsTag(node: Node): node is JSDocImplementsTag;
3751     function isJSDocClassTag(node: Node): node is JSDocClassTag;
3752     function isJSDocPublicTag(node: Node): node is JSDocPublicTag;
3753     function isJSDocPrivateTag(node: Node): node is JSDocPrivateTag;
3754     function isJSDocProtectedTag(node: Node): node is JSDocProtectedTag;
3755     function isJSDocReadonlyTag(node: Node): node is JSDocReadonlyTag;
3756     function isJSDocEnumTag(node: Node): node is JSDocEnumTag;
3757     function isJSDocThisTag(node: Node): node is JSDocThisTag;
3758     function isJSDocParameterTag(node: Node): node is JSDocParameterTag;
3759     function isJSDocReturnTag(node: Node): node is JSDocReturnTag;
3760     function isJSDocTypeTag(node: Node): node is JSDocTypeTag;
3761     function isJSDocTemplateTag(node: Node): node is JSDocTemplateTag;
3762     function isJSDocTypedefTag(node: Node): node is JSDocTypedefTag;
3763     function isJSDocPropertyTag(node: Node): node is JSDocPropertyTag;
3764     function isJSDocPropertyLikeTag(node: Node): node is JSDocPropertyLikeTag;
3765     function isJSDocTypeLiteral(node: Node): node is JSDocTypeLiteral;
3766     function isJSDocCallbackTag(node: Node): node is JSDocCallbackTag;
3767     function isJSDocSignature(node: Node): node is JSDocSignature;
3768     /**
3769      * True if node is of some token syntax kind.
3770      * For example, this is true for an IfKeyword but not for an IfStatement.
3771      * Literals are considered tokens, except TemplateLiteral, but does include TemplateHead/Middle/Tail.
3772      */
3773     function isToken(n: Node): boolean;
3774     function isLiteralExpression(node: Node): node is LiteralExpression;
3775     type TemplateLiteralToken = NoSubstitutionTemplateLiteral | TemplateHead | TemplateMiddle | TemplateTail;
3776     function isTemplateLiteralToken(node: Node): node is TemplateLiteralToken;
3777     function isTemplateMiddleOrTemplateTail(node: Node): node is TemplateMiddle | TemplateTail;
3778     function isImportOrExportSpecifier(node: Node): node is ImportSpecifier | ExportSpecifier;
3779     function isTypeOnlyImportOrExportDeclaration(node: Node): node is TypeOnlyCompatibleAliasDeclaration;
3780     function isStringTextContainingNode(node: Node): node is StringLiteral | TemplateLiteralToken;
3781     function isModifier(node: Node): node is Modifier;
3782     function isEntityName(node: Node): node is EntityName;
3783     function isPropertyName(node: Node): node is PropertyName;
3784     function isBindingName(node: Node): node is BindingName;
3785     function isFunctionLike(node: Node): node is SignatureDeclaration;
3786     function isClassElement(node: Node): node is ClassElement;
3787     function isClassLike(node: Node): node is ClassLikeDeclaration;
3788     function isAccessor(node: Node): node is AccessorDeclaration;
3789     function isTypeElement(node: Node): node is TypeElement;
3790     function isClassOrTypeElement(node: Node): node is ClassElement | TypeElement;
3791     function isObjectLiteralElementLike(node: Node): node is ObjectLiteralElementLike;
3792     /**
3793      * Node test that determines whether a node is a valid type node.
3794      * This differs from the `isPartOfTypeNode` function which determines whether a node is *part*
3795      * of a TypeNode.
3796      */
3797     function isTypeNode(node: Node): node is TypeNode;
3798     function isFunctionOrConstructorTypeNode(node: Node): node is FunctionTypeNode | ConstructorTypeNode;
3799     function isPropertyAccessOrQualifiedName(node: Node): node is PropertyAccessExpression | QualifiedName;
3800     function isCallLikeExpression(node: Node): node is CallLikeExpression;
3801     function isCallOrNewExpression(node: Node): node is CallExpression | NewExpression;
3802     function isTemplateLiteral(node: Node): node is TemplateLiteral;
3803     function isAssertionExpression(node: Node): node is AssertionExpression;
3804     function isIterationStatement(node: Node, lookInLabeledStatements: false): node is IterationStatement;
3805     function isIterationStatement(node: Node, lookInLabeledStatements: boolean): node is IterationStatement | LabeledStatement;
3806     function isJsxOpeningLikeElement(node: Node): node is JsxOpeningLikeElement;
3807     function isCaseOrDefaultClause(node: Node): node is CaseOrDefaultClause;
3808     /** True if node is of a kind that may contain comment text. */
3809     function isJSDocCommentContainingNode(node: Node): boolean;
3810     function isSetAccessor(node: Node): node is SetAccessorDeclaration;
3811     function isGetAccessor(node: Node): node is GetAccessorDeclaration;
3812     /** True if has initializer node attached to it. */
3813     function hasOnlyExpressionInitializer(node: Node): node is HasExpressionInitializer;
3814     function isObjectLiteralElement(node: Node): node is ObjectLiteralElement;
3815     function isStringLiteralLike(node: Node): node is StringLiteralLike;
3816 }
3817 declare namespace ts {
3818     export function createNode(kind: SyntaxKind, pos?: number, end?: number): Node;
3819     /**
3820      * Invokes a callback for each child of the given node. The 'cbNode' callback is invoked for all child nodes
3821      * stored in properties. If a 'cbNodes' callback is specified, it is invoked for embedded arrays; otherwise,
3822      * embedded arrays are flattened and the 'cbNode' callback is invoked for each element. If a callback returns
3823      * a truthy value, iteration stops and that value is returned. Otherwise, undefined is returned.
3824      *
3825      * @param node a given node to visit its children
3826      * @param cbNode a callback to be invoked for all child nodes
3827      * @param cbNodes a callback to be invoked for embedded array
3828      *
3829      * @remarks `forEachChild` must visit the children of a node in the order
3830      * that they appear in the source code. The language service depends on this property to locate nodes by position.
3831      */
3832     export function forEachChild<T>(node: Node, cbNode: (node: Node) => T | undefined, cbNodes?: (nodes: NodeArray<Node>) => T | undefined): T | undefined;
3833     export function createSourceFile(fileName: string, sourceText: string, languageVersion: ScriptTarget, setParentNodes?: boolean, scriptKind?: ScriptKind): SourceFile;
3834     export function parseIsolatedEntityName(text: string, languageVersion: ScriptTarget): EntityName | undefined;
3835     /**
3836      * Parse json text into SyntaxTree and return node and parse errors if any
3837      * @param fileName
3838      * @param sourceText
3839      */
3840     export function parseJsonText(fileName: string, sourceText: string): JsonSourceFile;
3841     export function isExternalModule(file: SourceFile): boolean;
3842     export function updateSourceFile(sourceFile: SourceFile, newText: string, textChangeRange: TextChangeRange, aggressiveChecks?: boolean): SourceFile;
3843     export {};
3844 }
3845 declare namespace ts {
3846     export function parseCommandLine(commandLine: readonly string[], readFile?: (path: string) => string | undefined): ParsedCommandLine;
3847     export type DiagnosticReporter = (diagnostic: Diagnostic) => void;
3848     /**
3849      * Reports config file diagnostics
3850      */
3851     export interface ConfigFileDiagnosticsReporter {
3852         /**
3853          * Reports unrecoverable error when parsing config file
3854          */
3855         onUnRecoverableConfigFileDiagnostic: DiagnosticReporter;
3856     }
3857     /**
3858      * Interface extending ParseConfigHost to support ParseConfigFile that reads config file and reports errors
3859      */
3860     export interface ParseConfigFileHost extends ParseConfigHost, ConfigFileDiagnosticsReporter {
3861         getCurrentDirectory(): string;
3862     }
3863     /**
3864      * Reads the config file, reports errors if any and exits if the config file cannot be found
3865      */
3866     export function getParsedCommandLineOfConfigFile(configFileName: string, optionsToExtend: CompilerOptions, host: ParseConfigFileHost, extendedConfigCache?: Map<ExtendedConfigCacheEntry>, watchOptionsToExtend?: WatchOptions, extraFileExtensions?: readonly FileExtensionInfo[]): ParsedCommandLine | undefined;
3867     /**
3868      * Read tsconfig.json file
3869      * @param fileName The path to the config file
3870      */
3871     export function readConfigFile(fileName: string, readFile: (path: string) => string | undefined): {
3872         config?: any;
3873         error?: Diagnostic;
3874     };
3875     /**
3876      * Parse the text of the tsconfig.json file
3877      * @param fileName The path to the config file
3878      * @param jsonText The text of the config file
3879      */
3880     export function parseConfigFileTextToJson(fileName: string, jsonText: string): {
3881         config?: any;
3882         error?: Diagnostic;
3883     };
3884     /**
3885      * Read tsconfig.json file
3886      * @param fileName The path to the config file
3887      */
3888     export function readJsonConfigFile(fileName: string, readFile: (path: string) => string | undefined): TsConfigSourceFile;
3889     /**
3890      * Convert the json syntax tree into the json value
3891      */
3892     export function convertToObject(sourceFile: JsonSourceFile, errors: Push<Diagnostic>): any;
3893     /**
3894      * Parse the contents of a config file (tsconfig.json).
3895      * @param json The contents of the config file to parse
3896      * @param host Instance of ParseConfigHost used to enumerate files in folder.
3897      * @param basePath A root directory to resolve relative path entries in the config
3898      *    file to. e.g. outDir
3899      */
3900     export function parseJsonConfigFileContent(json: any, host: ParseConfigHost, basePath: string, existingOptions?: CompilerOptions, configFileName?: string, resolutionStack?: Path[], extraFileExtensions?: readonly FileExtensionInfo[], extendedConfigCache?: Map<ExtendedConfigCacheEntry>, existingWatchOptions?: WatchOptions): ParsedCommandLine;
3901     /**
3902      * Parse the contents of a config file (tsconfig.json).
3903      * @param jsonNode The contents of the config file to parse
3904      * @param host Instance of ParseConfigHost used to enumerate files in folder.
3905      * @param basePath A root directory to resolve relative path entries in the config
3906      *    file to. e.g. outDir
3907      */
3908     export function parseJsonSourceFileConfigFileContent(sourceFile: TsConfigSourceFile, host: ParseConfigHost, basePath: string, existingOptions?: CompilerOptions, configFileName?: string, resolutionStack?: Path[], extraFileExtensions?: readonly FileExtensionInfo[], extendedConfigCache?: Map<ExtendedConfigCacheEntry>, existingWatchOptions?: WatchOptions): ParsedCommandLine;
3909     export interface ParsedTsconfig {
3910         raw: any;
3911         options?: CompilerOptions;
3912         watchOptions?: WatchOptions;
3913         typeAcquisition?: TypeAcquisition;
3914         /**
3915          * Note that the case of the config path has not yet been normalized, as no files have been imported into the project yet
3916          */
3917         extendedConfigPath?: string;
3918     }
3919     export interface ExtendedConfigCacheEntry {
3920         extendedResult: TsConfigSourceFile;
3921         extendedConfig: ParsedTsconfig | undefined;
3922     }
3923     export function convertCompilerOptionsFromJson(jsonOptions: any, basePath: string, configFileName?: string): {
3924         options: CompilerOptions;
3925         errors: Diagnostic[];
3926     };
3927     export function convertTypeAcquisitionFromJson(jsonOptions: any, basePath: string, configFileName?: string): {
3928         options: TypeAcquisition;
3929         errors: Diagnostic[];
3930     };
3931     export {};
3932 }
3933 declare namespace ts {
3934     function getEffectiveTypeRoots(options: CompilerOptions, host: GetEffectiveTypeRootsHost): string[] | undefined;
3935     /**
3936      * @param {string | undefined} containingFile - file that contains type reference directive, can be undefined if containing file is unknown.
3937      * This is possible in case if resolution is performed for directives specified via 'types' parameter. In this case initial path for secondary lookups
3938      * is assumed to be the same as root directory of the project.
3939      */
3940     function resolveTypeReferenceDirective(typeReferenceDirectiveName: string, containingFile: string | undefined, options: CompilerOptions, host: ModuleResolutionHost, redirectedReference?: ResolvedProjectReference): ResolvedTypeReferenceDirectiveWithFailedLookupLocations;
3941     /**
3942      * Given a set of options, returns the set of type directive names
3943      *   that should be included for this program automatically.
3944      * This list could either come from the config file,
3945      *   or from enumerating the types root + initial secondary types lookup location.
3946      * More type directives might appear in the program later as a result of loading actual source files;
3947      *   this list is only the set of defaults that are implicitly included.
3948      */
3949     function getAutomaticTypeDirectiveNames(options: CompilerOptions, host: ModuleResolutionHost): string[];
3950     /**
3951      * Cached module resolutions per containing directory.
3952      * This assumes that any module id will have the same resolution for sibling files located in the same folder.
3953      */
3954     interface ModuleResolutionCache extends NonRelativeModuleNameResolutionCache {
3955         getOrCreateCacheForDirectory(directoryName: string, redirectedReference?: ResolvedProjectReference): Map<ResolvedModuleWithFailedLookupLocations>;
3956     }
3957     /**
3958      * Stored map from non-relative module name to a table: directory -> result of module lookup in this directory
3959      * We support only non-relative module names because resolution of relative module names is usually more deterministic and thus less expensive.
3960      */
3961     interface NonRelativeModuleNameResolutionCache {
3962         getOrCreateCacheForModuleName(nonRelativeModuleName: string, redirectedReference?: ResolvedProjectReference): PerModuleNameCache;
3963     }
3964     interface PerModuleNameCache {
3965         get(directory: string): ResolvedModuleWithFailedLookupLocations | undefined;
3966         set(directory: string, result: ResolvedModuleWithFailedLookupLocations): void;
3967     }
3968     function createModuleResolutionCache(currentDirectory: string, getCanonicalFileName: (s: string) => string, options?: CompilerOptions): ModuleResolutionCache;
3969     function resolveModuleNameFromCache(moduleName: string, containingFile: string, cache: ModuleResolutionCache): ResolvedModuleWithFailedLookupLocations | undefined;
3970     function resolveModuleName(moduleName: string, containingFile: string, compilerOptions: CompilerOptions, host: ModuleResolutionHost, cache?: ModuleResolutionCache, redirectedReference?: ResolvedProjectReference): ResolvedModuleWithFailedLookupLocations;
3971     function nodeModuleNameResolver(moduleName: string, containingFile: string, compilerOptions: CompilerOptions, host: ModuleResolutionHost, cache?: ModuleResolutionCache, redirectedReference?: ResolvedProjectReference): ResolvedModuleWithFailedLookupLocations;
3972     function classicNameResolver(moduleName: string, containingFile: string, compilerOptions: CompilerOptions, host: ModuleResolutionHost, cache?: NonRelativeModuleNameResolutionCache, redirectedReference?: ResolvedProjectReference): ResolvedModuleWithFailedLookupLocations;
3973 }
3974 declare namespace ts {
3975     function createNodeArray<T extends Node>(elements?: readonly T[], hasTrailingComma?: boolean): NodeArray<T>;
3976     /** If a node is passed, creates a string literal whose source text is read from a source node during emit. */
3977     function createLiteral(value: string | StringLiteral | NoSubstitutionTemplateLiteral | NumericLiteral | Identifier): StringLiteral;
3978     function createLiteral(value: number | PseudoBigInt): NumericLiteral;
3979     function createLiteral(value: boolean): BooleanLiteral;
3980     function createLiteral(value: string | number | PseudoBigInt | boolean): PrimaryExpression;
3981     function createNumericLiteral(value: string, numericLiteralFlags?: TokenFlags): NumericLiteral;
3982     function createBigIntLiteral(value: string): BigIntLiteral;
3983     function createStringLiteral(text: string): StringLiteral;
3984     function createRegularExpressionLiteral(text: string): RegularExpressionLiteral;
3985     function createIdentifier(text: string): Identifier;
3986     function updateIdentifier(node: Identifier): Identifier;
3987     /** Create a unique temporary variable. */
3988     function createTempVariable(recordTempVariable: ((node: Identifier) => void) | undefined): Identifier;
3989     /** Create a unique temporary variable for use in a loop. */
3990     function createLoopVariable(): Identifier;
3991     /** Create a unique name based on the supplied text. */
3992     function createUniqueName(text: string): Identifier;
3993     /** Create a unique name based on the supplied text. */
3994     function createOptimisticUniqueName(text: string): Identifier;
3995     /** Create a unique name based on the supplied text. This does not consider names injected by the transformer. */
3996     function createFileLevelUniqueName(text: string): Identifier;
3997     /** Create a unique name generated for a node. */
3998     function getGeneratedNameForNode(node: Node | undefined): Identifier;
3999     function createPrivateIdentifier(text: string): PrivateIdentifier;
4000     function createToken<TKind extends SyntaxKind>(token: TKind): Token<TKind>;
4001     function createSuper(): SuperExpression;
4002     function createThis(): ThisExpression & Token<SyntaxKind.ThisKeyword>;
4003     function createNull(): NullLiteral & Token<SyntaxKind.NullKeyword>;
4004     function createTrue(): BooleanLiteral & Token<SyntaxKind.TrueKeyword>;
4005     function createFalse(): BooleanLiteral & Token<SyntaxKind.FalseKeyword>;
4006     function createModifier<T extends Modifier["kind"]>(kind: T): Token<T>;
4007     function createModifiersFromModifierFlags(flags: ModifierFlags): Modifier[];
4008     function createQualifiedName(left: EntityName, right: string | Identifier): QualifiedName;
4009     function updateQualifiedName(node: QualifiedName, left: EntityName, right: Identifier): QualifiedName;
4010     function createComputedPropertyName(expression: Expression): ComputedPropertyName;
4011     function updateComputedPropertyName(node: ComputedPropertyName, expression: Expression): ComputedPropertyName;
4012     function createTypeParameterDeclaration(name: string | Identifier, constraint?: TypeNode, defaultType?: TypeNode): TypeParameterDeclaration;
4013     function updateTypeParameterDeclaration(node: TypeParameterDeclaration, name: Identifier, constraint: TypeNode | undefined, defaultType: TypeNode | undefined): TypeParameterDeclaration;
4014     function createParameter(decorators: readonly Decorator[] | undefined, modifiers: readonly Modifier[] | undefined, dotDotDotToken: DotDotDotToken | undefined, name: string | BindingName, questionToken?: QuestionToken, type?: TypeNode, initializer?: Expression): ParameterDeclaration;
4015     function updateParameter(node: ParameterDeclaration, decorators: readonly Decorator[] | undefined, modifiers: readonly Modifier[] | undefined, dotDotDotToken: DotDotDotToken | undefined, name: string | BindingName, questionToken: QuestionToken | undefined, type: TypeNode | undefined, initializer: Expression | undefined): ParameterDeclaration;
4016     function createDecorator(expression: Expression): Decorator;
4017     function updateDecorator(node: Decorator, expression: Expression): Decorator;
4018     function createPropertySignature(modifiers: readonly Modifier[] | undefined, name: PropertyName | string, questionToken: QuestionToken | undefined, type: TypeNode | undefined, initializer: Expression | undefined): PropertySignature;
4019     function updatePropertySignature(node: PropertySignature, modifiers: readonly Modifier[] | undefined, name: PropertyName, questionToken: QuestionToken | undefined, type: TypeNode | undefined, initializer: Expression | undefined): PropertySignature;
4020     function createProperty(decorators: readonly Decorator[] | undefined, modifiers: readonly Modifier[] | undefined, name: string | PropertyName, questionOrExclamationToken: QuestionToken | ExclamationToken | undefined, type: TypeNode | undefined, initializer: Expression | undefined): PropertyDeclaration;
4021     function updateProperty(node: PropertyDeclaration, decorators: readonly Decorator[] | undefined, modifiers: readonly Modifier[] | undefined, name: string | PropertyName, questionOrExclamationToken: QuestionToken | ExclamationToken | undefined, type: TypeNode | undefined, initializer: Expression | undefined): PropertyDeclaration;
4022     function createMethodSignature(typeParameters: readonly TypeParameterDeclaration[] | undefined, parameters: readonly ParameterDeclaration[], type: TypeNode | undefined, name: string | PropertyName, questionToken: QuestionToken | undefined): MethodSignature;
4023     function updateMethodSignature(node: MethodSignature, typeParameters: NodeArray<TypeParameterDeclaration> | undefined, parameters: NodeArray<ParameterDeclaration>, type: TypeNode | undefined, name: PropertyName, questionToken: QuestionToken | undefined): MethodSignature;
4024     function createMethod(decorators: readonly Decorator[] | undefined, modifiers: readonly Modifier[] | undefined, asteriskToken: AsteriskToken | undefined, name: string | PropertyName, questionToken: QuestionToken | undefined, typeParameters: readonly TypeParameterDeclaration[] | undefined, parameters: readonly ParameterDeclaration[], type: TypeNode | undefined, body: Block | undefined): MethodDeclaration;
4025     function updateMethod(node: MethodDeclaration, decorators: readonly Decorator[] | undefined, modifiers: readonly Modifier[] | undefined, asteriskToken: AsteriskToken | undefined, name: PropertyName, questionToken: QuestionToken | undefined, typeParameters: readonly TypeParameterDeclaration[] | undefined, parameters: readonly ParameterDeclaration[], type: TypeNode | undefined, body: Block | undefined): MethodDeclaration;
4026     function createConstructor(decorators: readonly Decorator[] | undefined, modifiers: readonly Modifier[] | undefined, parameters: readonly ParameterDeclaration[], body: Block | undefined): ConstructorDeclaration;
4027     function updateConstructor(node: ConstructorDeclaration, decorators: readonly Decorator[] | undefined, modifiers: readonly Modifier[] | undefined, parameters: readonly ParameterDeclaration[], body: Block | undefined): ConstructorDeclaration;
4028     function createGetAccessor(decorators: readonly Decorator[] | undefined, modifiers: readonly Modifier[] | undefined, name: string | PropertyName, parameters: readonly ParameterDeclaration[], type: TypeNode | undefined, body: Block | undefined): GetAccessorDeclaration;
4029     function updateGetAccessor(node: GetAccessorDeclaration, decorators: readonly Decorator[] | undefined, modifiers: readonly Modifier[] | undefined, name: PropertyName, parameters: readonly ParameterDeclaration[], type: TypeNode | undefined, body: Block | undefined): GetAccessorDeclaration;
4030     function createSetAccessor(decorators: readonly Decorator[] | undefined, modifiers: readonly Modifier[] | undefined, name: string | PropertyName, parameters: readonly ParameterDeclaration[], body: Block | undefined): SetAccessorDeclaration;
4031     function updateSetAccessor(node: SetAccessorDeclaration, decorators: readonly Decorator[] | undefined, modifiers: readonly Modifier[] | undefined, name: PropertyName, parameters: readonly ParameterDeclaration[], body: Block | undefined): SetAccessorDeclaration;
4032     function createCallSignature(typeParameters: readonly TypeParameterDeclaration[] | undefined, parameters: readonly ParameterDeclaration[], type: TypeNode | undefined): CallSignatureDeclaration;
4033     function updateCallSignature(node: CallSignatureDeclaration, typeParameters: NodeArray<TypeParameterDeclaration> | undefined, parameters: NodeArray<ParameterDeclaration>, type: TypeNode | undefined): CallSignatureDeclaration;
4034     function createConstructSignature(typeParameters: readonly TypeParameterDeclaration[] | undefined, parameters: readonly ParameterDeclaration[], type: TypeNode | undefined): ConstructSignatureDeclaration;
4035     function updateConstructSignature(node: ConstructSignatureDeclaration, typeParameters: NodeArray<TypeParameterDeclaration> | undefined, parameters: NodeArray<ParameterDeclaration>, type: TypeNode | undefined): ConstructSignatureDeclaration;
4036     function createIndexSignature(decorators: readonly Decorator[] | undefined, modifiers: readonly Modifier[] | undefined, parameters: readonly ParameterDeclaration[], type: TypeNode): IndexSignatureDeclaration;
4037     function updateIndexSignature(node: IndexSignatureDeclaration, decorators: readonly Decorator[] | undefined, modifiers: readonly Modifier[] | undefined, parameters: readonly ParameterDeclaration[], type: TypeNode): IndexSignatureDeclaration;
4038     function createKeywordTypeNode(kind: KeywordTypeNode["kind"]): KeywordTypeNode;
4039     function createTypePredicateNode(parameterName: Identifier | ThisTypeNode | string, type: TypeNode): TypePredicateNode;
4040     function createTypePredicateNodeWithModifier(assertsModifier: AssertsToken | undefined, parameterName: Identifier | ThisTypeNode | string, type: TypeNode | undefined): TypePredicateNode;
4041     function updateTypePredicateNode(node: TypePredicateNode, parameterName: Identifier | ThisTypeNode, type: TypeNode): TypePredicateNode;
4042     function updateTypePredicateNodeWithModifier(node: TypePredicateNode, assertsModifier: AssertsToken | undefined, parameterName: Identifier | ThisTypeNode, type: TypeNode | undefined): TypePredicateNode;
4043     function createTypeReferenceNode(typeName: string | EntityName, typeArguments: readonly TypeNode[] | undefined): TypeReferenceNode;
4044     function updateTypeReferenceNode(node: TypeReferenceNode, typeName: EntityName, typeArguments: NodeArray<TypeNode> | undefined): TypeReferenceNode;
4045     function createFunctionTypeNode(typeParameters: readonly TypeParameterDeclaration[] | undefined, parameters: readonly ParameterDeclaration[], type: TypeNode | undefined): FunctionTypeNode;
4046     function updateFunctionTypeNode(node: FunctionTypeNode, typeParameters: NodeArray<TypeParameterDeclaration> | undefined, parameters: NodeArray<ParameterDeclaration>, type: TypeNode | undefined): FunctionTypeNode;
4047     function createConstructorTypeNode(typeParameters: readonly TypeParameterDeclaration[] | undefined, parameters: readonly ParameterDeclaration[], type: TypeNode | undefined): ConstructorTypeNode;
4048     function updateConstructorTypeNode(node: ConstructorTypeNode, typeParameters: NodeArray<TypeParameterDeclaration> | undefined, parameters: NodeArray<ParameterDeclaration>, type: TypeNode | undefined): ConstructorTypeNode;
4049     function createTypeQueryNode(exprName: EntityName): TypeQueryNode;
4050     function updateTypeQueryNode(node: TypeQueryNode, exprName: EntityName): TypeQueryNode;
4051     function createTypeLiteralNode(members: readonly TypeElement[] | undefined): TypeLiteralNode;
4052     function updateTypeLiteralNode(node: TypeLiteralNode, members: NodeArray<TypeElement>): TypeLiteralNode;
4053     function createArrayTypeNode(elementType: TypeNode): ArrayTypeNode;
4054     function updateArrayTypeNode(node: ArrayTypeNode, elementType: TypeNode): ArrayTypeNode;
4055     function createTupleTypeNode(elementTypes: readonly TypeNode[]): TupleTypeNode;
4056     function updateTupleTypeNode(node: TupleTypeNode, elementTypes: readonly TypeNode[]): TupleTypeNode;
4057     function createOptionalTypeNode(type: TypeNode): OptionalTypeNode;
4058     function updateOptionalTypeNode(node: OptionalTypeNode, type: TypeNode): OptionalTypeNode;
4059     function createRestTypeNode(type: TypeNode): RestTypeNode;
4060     function updateRestTypeNode(node: RestTypeNode, type: TypeNode): RestTypeNode;
4061     function createUnionTypeNode(types: readonly TypeNode[]): UnionTypeNode;
4062     function updateUnionTypeNode(node: UnionTypeNode, types: NodeArray<TypeNode>): UnionTypeNode;
4063     function createIntersectionTypeNode(types: readonly TypeNode[]): IntersectionTypeNode;
4064     function updateIntersectionTypeNode(node: IntersectionTypeNode, types: NodeArray<TypeNode>): IntersectionTypeNode;
4065     function createUnionOrIntersectionTypeNode(kind: SyntaxKind.UnionType | SyntaxKind.IntersectionType, types: readonly TypeNode[]): UnionOrIntersectionTypeNode;
4066     function createConditionalTypeNode(checkType: TypeNode, extendsType: TypeNode, trueType: TypeNode, falseType: TypeNode): ConditionalTypeNode;
4067     function updateConditionalTypeNode(node: ConditionalTypeNode, checkType: TypeNode, extendsType: TypeNode, trueType: TypeNode, falseType: TypeNode): ConditionalTypeNode;
4068     function createInferTypeNode(typeParameter: TypeParameterDeclaration): InferTypeNode;
4069     function updateInferTypeNode(node: InferTypeNode, typeParameter: TypeParameterDeclaration): InferTypeNode;
4070     function createImportTypeNode(argument: TypeNode, qualifier?: EntityName, typeArguments?: readonly TypeNode[], isTypeOf?: boolean): ImportTypeNode;
4071     function updateImportTypeNode(node: ImportTypeNode, argument: TypeNode, qualifier?: EntityName, typeArguments?: readonly TypeNode[], isTypeOf?: boolean): ImportTypeNode;
4072     function createParenthesizedType(type: TypeNode): ParenthesizedTypeNode;
4073     function updateParenthesizedType(node: ParenthesizedTypeNode, type: TypeNode): ParenthesizedTypeNode;
4074     function createThisTypeNode(): ThisTypeNode;
4075     function createTypeOperatorNode(type: TypeNode): TypeOperatorNode;
4076     function createTypeOperatorNode(operator: SyntaxKind.KeyOfKeyword | SyntaxKind.UniqueKeyword | SyntaxKind.ReadonlyKeyword, type: TypeNode): TypeOperatorNode;
4077     function updateTypeOperatorNode(node: TypeOperatorNode, type: TypeNode): TypeOperatorNode;
4078     function createIndexedAccessTypeNode(objectType: TypeNode, indexType: TypeNode): IndexedAccessTypeNode;
4079     function updateIndexedAccessTypeNode(node: IndexedAccessTypeNode, objectType: TypeNode, indexType: TypeNode): IndexedAccessTypeNode;
4080     function createMappedTypeNode(readonlyToken: ReadonlyToken | PlusToken | MinusToken | undefined, typeParameter: TypeParameterDeclaration, questionToken: QuestionToken | PlusToken | MinusToken | undefined, type: TypeNode | undefined): MappedTypeNode;
4081     function updateMappedTypeNode(node: MappedTypeNode, readonlyToken: ReadonlyToken | PlusToken | MinusToken | undefined, typeParameter: TypeParameterDeclaration, questionToken: QuestionToken | PlusToken | MinusToken | undefined, type: TypeNode | undefined): MappedTypeNode;
4082     function createLiteralTypeNode(literal: LiteralTypeNode["literal"]): LiteralTypeNode;
4083     function updateLiteralTypeNode(node: LiteralTypeNode, literal: LiteralTypeNode["literal"]): LiteralTypeNode;
4084     function createObjectBindingPattern(elements: readonly BindingElement[]): ObjectBindingPattern;
4085     function updateObjectBindingPattern(node: ObjectBindingPattern, elements: readonly BindingElement[]): ObjectBindingPattern;
4086     function createArrayBindingPattern(elements: readonly ArrayBindingElement[]): ArrayBindingPattern;
4087     function updateArrayBindingPattern(node: ArrayBindingPattern, elements: readonly ArrayBindingElement[]): ArrayBindingPattern;
4088     function createBindingElement(dotDotDotToken: DotDotDotToken | undefined, propertyName: string | PropertyName | undefined, name: string | BindingName, initializer?: Expression): BindingElement;
4089     function updateBindingElement(node: BindingElement, dotDotDotToken: DotDotDotToken | undefined, propertyName: PropertyName | undefined, name: BindingName, initializer: Expression | undefined): BindingElement;
4090     function createArrayLiteral(elements?: readonly Expression[], multiLine?: boolean): ArrayLiteralExpression;
4091     function updateArrayLiteral(node: ArrayLiteralExpression, elements: readonly Expression[]): ArrayLiteralExpression;
4092     function createObjectLiteral(properties?: readonly ObjectLiteralElementLike[], multiLine?: boolean): ObjectLiteralExpression;
4093     function updateObjectLiteral(node: ObjectLiteralExpression, properties: readonly ObjectLiteralElementLike[]): ObjectLiteralExpression;
4094     function createPropertyAccess(expression: Expression, name: string | Identifier | PrivateIdentifier): PropertyAccessExpression;
4095     function updatePropertyAccess(node: PropertyAccessExpression, expression: Expression, name: Identifier | PrivateIdentifier): PropertyAccessExpression;
4096     function createPropertyAccessChain(expression: Expression, questionDotToken: QuestionDotToken | undefined, name: string | Identifier): PropertyAccessChain;
4097     function updatePropertyAccessChain(node: PropertyAccessChain, expression: Expression, questionDotToken: QuestionDotToken | undefined, name: Identifier): PropertyAccessChain;
4098     function createElementAccess(expression: Expression, index: number | Expression): ElementAccessExpression;
4099     function updateElementAccess(node: ElementAccessExpression, expression: Expression, argumentExpression: Expression): ElementAccessExpression;
4100     function createElementAccessChain(expression: Expression, questionDotToken: QuestionDotToken | undefined, index: number | Expression): ElementAccessChain;
4101     function updateElementAccessChain(node: ElementAccessChain, expression: Expression, questionDotToken: QuestionDotToken | undefined, argumentExpression: Expression): ElementAccessChain;
4102     function createCall(expression: Expression, typeArguments: readonly TypeNode[] | undefined, argumentsArray: readonly Expression[] | undefined): CallExpression;
4103     function updateCall(node: CallExpression, expression: Expression, typeArguments: readonly TypeNode[] | undefined, argumentsArray: readonly Expression[]): CallExpression;
4104     function createCallChain(expression: Expression, questionDotToken: QuestionDotToken | undefined, typeArguments: readonly TypeNode[] | undefined, argumentsArray: readonly Expression[] | undefined): CallChain;
4105     function updateCallChain(node: CallChain, expression: Expression, questionDotToken: QuestionDotToken | undefined, typeArguments: readonly TypeNode[] | undefined, argumentsArray: readonly Expression[]): CallChain;
4106     function createNew(expression: Expression, typeArguments: readonly TypeNode[] | undefined, argumentsArray: readonly Expression[] | undefined): NewExpression;
4107     function updateNew(node: NewExpression, expression: Expression, typeArguments: readonly TypeNode[] | undefined, argumentsArray: readonly Expression[] | undefined): NewExpression;
4108     /** @deprecated */ function createTaggedTemplate(tag: Expression, template: TemplateLiteral): TaggedTemplateExpression;
4109     function createTaggedTemplate(tag: Expression, typeArguments: readonly TypeNode[] | undefined, template: TemplateLiteral): TaggedTemplateExpression;
4110     /** @deprecated */ function updateTaggedTemplate(node: TaggedTemplateExpression, tag: Expression, template: TemplateLiteral): TaggedTemplateExpression;
4111     function updateTaggedTemplate(node: TaggedTemplateExpression, tag: Expression, typeArguments: readonly TypeNode[] | undefined, template: TemplateLiteral): TaggedTemplateExpression;
4112     function createTypeAssertion(type: TypeNode, expression: Expression): TypeAssertion;
4113     function updateTypeAssertion(node: TypeAssertion, type: TypeNode, expression: Expression): TypeAssertion;
4114     function createParen(expression: Expression): ParenthesizedExpression;
4115     function updateParen(node: ParenthesizedExpression, expression: Expression): ParenthesizedExpression;
4116     function createFunctionExpression(modifiers: readonly Modifier[] | undefined, asteriskToken: AsteriskToken | undefined, name: string | Identifier | undefined, typeParameters: readonly TypeParameterDeclaration[] | undefined, parameters: readonly ParameterDeclaration[] | undefined, type: TypeNode | undefined, body: Block): FunctionExpression;
4117     function updateFunctionExpression(node: FunctionExpression, modifiers: readonly Modifier[] | undefined, asteriskToken: AsteriskToken | undefined, name: Identifier | undefined, typeParameters: readonly TypeParameterDeclaration[] | undefined, parameters: readonly ParameterDeclaration[], type: TypeNode | undefined, body: Block): FunctionExpression;
4118     function createArrowFunction(modifiers: readonly Modifier[] | undefined, typeParameters: readonly TypeParameterDeclaration[] | undefined, parameters: readonly ParameterDeclaration[], type: TypeNode | undefined, equalsGreaterThanToken: EqualsGreaterThanToken | undefined, body: ConciseBody): ArrowFunction;
4119     function updateArrowFunction(node: ArrowFunction, modifiers: readonly Modifier[] | undefined, typeParameters: readonly TypeParameterDeclaration[] | undefined, parameters: readonly ParameterDeclaration[], type: TypeNode | undefined, equalsGreaterThanToken: Token<SyntaxKind.EqualsGreaterThanToken>, body: ConciseBody): ArrowFunction;
4120     function createDelete(expression: Expression): DeleteExpression;
4121     function updateDelete(node: DeleteExpression, expression: Expression): DeleteExpression;
4122     function createTypeOf(expression: Expression): TypeOfExpression;
4123     function updateTypeOf(node: TypeOfExpression, expression: Expression): TypeOfExpression;
4124     function createVoid(expression: Expression): VoidExpression;
4125     function updateVoid(node: VoidExpression, expression: Expression): VoidExpression;
4126     function createAwait(expression: Expression): AwaitExpression;
4127     function updateAwait(node: AwaitExpression, expression: Expression): AwaitExpression;
4128     function createPrefix(operator: PrefixUnaryOperator, operand: Expression): PrefixUnaryExpression;
4129     function updatePrefix(node: PrefixUnaryExpression, operand: Expression): PrefixUnaryExpression;
4130     function createPostfix(operand: Expression, operator: PostfixUnaryOperator): PostfixUnaryExpression;
4131     function updatePostfix(node: PostfixUnaryExpression, operand: Expression): PostfixUnaryExpression;
4132     function createBinary(left: Expression, operator: BinaryOperator | BinaryOperatorToken, right: Expression): BinaryExpression;
4133     function updateBinary(node: BinaryExpression, left: Expression, right: Expression, operator?: BinaryOperator | BinaryOperatorToken): BinaryExpression;
4134     /** @deprecated */ function createConditional(condition: Expression, whenTrue: Expression, whenFalse: Expression): ConditionalExpression;
4135     function createConditional(condition: Expression, questionToken: QuestionToken, whenTrue: Expression, colonToken: ColonToken, whenFalse: Expression): ConditionalExpression;
4136     function updateConditional(node: ConditionalExpression, condition: Expression, questionToken: Token<SyntaxKind.QuestionToken>, whenTrue: Expression, colonToken: Token<SyntaxKind.ColonToken>, whenFalse: Expression): ConditionalExpression;
4137     function createTemplateExpression(head: TemplateHead, templateSpans: readonly TemplateSpan[]): TemplateExpression;
4138     function updateTemplateExpression(node: TemplateExpression, head: TemplateHead, templateSpans: readonly TemplateSpan[]): TemplateExpression;
4139     function createTemplateHead(text: string, rawText?: string): TemplateHead;
4140     function createTemplateMiddle(text: string, rawText?: string): TemplateMiddle;
4141     function createTemplateTail(text: string, rawText?: string): TemplateTail;
4142     function createNoSubstitutionTemplateLiteral(text: string, rawText?: string): NoSubstitutionTemplateLiteral;
4143     function createYield(expression?: Expression): YieldExpression;
4144     function createYield(asteriskToken: AsteriskToken | undefined, expression: Expression): YieldExpression;
4145     function updateYield(node: YieldExpression, asteriskToken: AsteriskToken | undefined, expression: Expression): YieldExpression;
4146     function createSpread(expression: Expression): SpreadElement;
4147     function updateSpread(node: SpreadElement, expression: Expression): SpreadElement;
4148     function createClassExpression(modifiers: readonly Modifier[] | undefined, name: string | Identifier | undefined, typeParameters: readonly TypeParameterDeclaration[] | undefined, heritageClauses: readonly HeritageClause[] | undefined, members: readonly ClassElement[]): ClassExpression;
4149     function updateClassExpression(node: ClassExpression, modifiers: readonly Modifier[] | undefined, name: Identifier | undefined, typeParameters: readonly TypeParameterDeclaration[] | undefined, heritageClauses: readonly HeritageClause[] | undefined, members: readonly ClassElement[]): ClassExpression;
4150     function createOmittedExpression(): OmittedExpression;
4151     function createExpressionWithTypeArguments(typeArguments: readonly TypeNode[] | undefined, expression: Expression): ExpressionWithTypeArguments;
4152     function updateExpressionWithTypeArguments(node: ExpressionWithTypeArguments, typeArguments: readonly TypeNode[] | undefined, expression: Expression): ExpressionWithTypeArguments;
4153     function createAsExpression(expression: Expression, type: TypeNode): AsExpression;
4154     function updateAsExpression(node: AsExpression, expression: Expression, type: TypeNode): AsExpression;
4155     function createNonNullExpression(expression: Expression): NonNullExpression;
4156     function updateNonNullExpression(node: NonNullExpression, expression: Expression): NonNullExpression;
4157     function createNonNullChain(expression: Expression): NonNullChain;
4158     function updateNonNullChain(node: NonNullChain, expression: Expression): NonNullChain;
4159     function createMetaProperty(keywordToken: MetaProperty["keywordToken"], name: Identifier): MetaProperty;
4160     function updateMetaProperty(node: MetaProperty, name: Identifier): MetaProperty;
4161     function createTemplateSpan(expression: Expression, literal: TemplateMiddle | TemplateTail): TemplateSpan;
4162     function updateTemplateSpan(node: TemplateSpan, expression: Expression, literal: TemplateMiddle | TemplateTail): TemplateSpan;
4163     function createSemicolonClassElement(): SemicolonClassElement;
4164     function createBlock(statements: readonly Statement[], multiLine?: boolean): Block;
4165     function updateBlock(node: Block, statements: readonly Statement[]): Block;
4166     function createVariableStatement(modifiers: readonly Modifier[] | undefined, declarationList: VariableDeclarationList | readonly VariableDeclaration[]): VariableStatement;
4167     function updateVariableStatement(node: VariableStatement, modifiers: readonly Modifier[] | undefined, declarationList: VariableDeclarationList): VariableStatement;
4168     function createEmptyStatement(): EmptyStatement;
4169     function createExpressionStatement(expression: Expression): ExpressionStatement;
4170     function updateExpressionStatement(node: ExpressionStatement, expression: Expression): ExpressionStatement;
4171     /** @deprecated Use `createExpressionStatement` instead.  */
4172     const createStatement: typeof createExpressionStatement;
4173     /** @deprecated Use `updateExpressionStatement` instead.  */
4174     const updateStatement: typeof updateExpressionStatement;
4175     function createIf(expression: Expression, thenStatement: Statement, elseStatement?: Statement): IfStatement;
4176     function updateIf(node: IfStatement, expression: Expression, thenStatement: Statement, elseStatement: Statement | undefined): IfStatement;
4177     function createDo(statement: Statement, expression: Expression): DoStatement;
4178     function updateDo(node: DoStatement, statement: Statement, expression: Expression): DoStatement;
4179     function createWhile(expression: Expression, statement: Statement): WhileStatement;
4180     function updateWhile(node: WhileStatement, expression: Expression, statement: Statement): WhileStatement;
4181     function createFor(initializer: ForInitializer | undefined, condition: Expression | undefined, incrementor: Expression | undefined, statement: Statement): ForStatement;
4182     function updateFor(node: ForStatement, initializer: ForInitializer | undefined, condition: Expression | undefined, incrementor: Expression | undefined, statement: Statement): ForStatement;
4183     function createForIn(initializer: ForInitializer, expression: Expression, statement: Statement): ForInStatement;
4184     function updateForIn(node: ForInStatement, initializer: ForInitializer, expression: Expression, statement: Statement): ForInStatement;
4185     function createForOf(awaitModifier: AwaitKeywordToken | undefined, initializer: ForInitializer, expression: Expression, statement: Statement): ForOfStatement;
4186     function updateForOf(node: ForOfStatement, awaitModifier: AwaitKeywordToken | undefined, initializer: ForInitializer, expression: Expression, statement: Statement): ForOfStatement;
4187     function createContinue(label?: string | Identifier): ContinueStatement;
4188     function updateContinue(node: ContinueStatement, label: Identifier | undefined): ContinueStatement;
4189     function createBreak(label?: string | Identifier): BreakStatement;
4190     function updateBreak(node: BreakStatement, label: Identifier | undefined): BreakStatement;
4191     function createReturn(expression?: Expression): ReturnStatement;
4192     function updateReturn(node: ReturnStatement, expression: Expression | undefined): ReturnStatement;
4193     function createWith(expression: Expression, statement: Statement): WithStatement;
4194     function updateWith(node: WithStatement, expression: Expression, statement: Statement): WithStatement;
4195     function createSwitch(expression: Expression, caseBlock: CaseBlock): SwitchStatement;
4196     function updateSwitch(node: SwitchStatement, expression: Expression, caseBlock: CaseBlock): SwitchStatement;
4197     function createLabel(label: string | Identifier, statement: Statement): LabeledStatement;
4198     function updateLabel(node: LabeledStatement, label: Identifier, statement: Statement): LabeledStatement;
4199     function createThrow(expression: Expression): ThrowStatement;
4200     function updateThrow(node: ThrowStatement, expression: Expression): ThrowStatement;
4201     function createTry(tryBlock: Block, catchClause: CatchClause | undefined, finallyBlock: Block | undefined): TryStatement;
4202     function updateTry(node: TryStatement, tryBlock: Block, catchClause: CatchClause | undefined, finallyBlock: Block | undefined): TryStatement;
4203     function createDebuggerStatement(): DebuggerStatement;
4204     function createVariableDeclaration(name: string | BindingName, type?: TypeNode, initializer?: Expression): VariableDeclaration;
4205     function updateVariableDeclaration(node: VariableDeclaration, name: BindingName, type: TypeNode | undefined, initializer: Expression | undefined): VariableDeclaration;
4206     function createVariableDeclarationList(declarations: readonly VariableDeclaration[], flags?: NodeFlags): VariableDeclarationList;
4207     function updateVariableDeclarationList(node: VariableDeclarationList, declarations: readonly VariableDeclaration[]): VariableDeclarationList;
4208     function createFunctionDeclaration(decorators: readonly Decorator[] | undefined, modifiers: readonly Modifier[] | undefined, asteriskToken: AsteriskToken | undefined, name: string | Identifier | undefined, typeParameters: readonly TypeParameterDeclaration[] | undefined, parameters: readonly ParameterDeclaration[], type: TypeNode | undefined, body: Block | undefined): FunctionDeclaration;
4209     function updateFunctionDeclaration(node: FunctionDeclaration, decorators: readonly Decorator[] | undefined, modifiers: readonly Modifier[] | undefined, asteriskToken: AsteriskToken | undefined, name: Identifier | undefined, typeParameters: readonly TypeParameterDeclaration[] | undefined, parameters: readonly ParameterDeclaration[], type: TypeNode | undefined, body: Block | undefined): FunctionDeclaration;
4210     function createClassDeclaration(decorators: readonly Decorator[] | undefined, modifiers: readonly Modifier[] | undefined, name: string | Identifier | undefined, typeParameters: readonly TypeParameterDeclaration[] | undefined, heritageClauses: readonly HeritageClause[] | undefined, members: readonly ClassElement[]): ClassDeclaration;
4211     function updateClassDeclaration(node: ClassDeclaration, decorators: readonly Decorator[] | undefined, modifiers: readonly Modifier[] | undefined, name: Identifier | undefined, typeParameters: readonly TypeParameterDeclaration[] | undefined, heritageClauses: readonly HeritageClause[] | undefined, members: readonly ClassElement[]): ClassDeclaration;
4212     function createInterfaceDeclaration(decorators: readonly Decorator[] | undefined, modifiers: readonly Modifier[] | undefined, name: string | Identifier, typeParameters: readonly TypeParameterDeclaration[] | undefined, heritageClauses: readonly HeritageClause[] | undefined, members: readonly TypeElement[]): InterfaceDeclaration;
4213     function updateInterfaceDeclaration(node: InterfaceDeclaration, decorators: readonly Decorator[] | undefined, modifiers: readonly Modifier[] | undefined, name: Identifier, typeParameters: readonly TypeParameterDeclaration[] | undefined, heritageClauses: readonly HeritageClause[] | undefined, members: readonly TypeElement[]): InterfaceDeclaration;
4214     function createTypeAliasDeclaration(decorators: readonly Decorator[] | undefined, modifiers: readonly Modifier[] | undefined, name: string | Identifier, typeParameters: readonly TypeParameterDeclaration[] | undefined, type: TypeNode): TypeAliasDeclaration;
4215     function updateTypeAliasDeclaration(node: TypeAliasDeclaration, decorators: readonly Decorator[] | undefined, modifiers: readonly Modifier[] | undefined, name: Identifier, typeParameters: readonly TypeParameterDeclaration[] | undefined, type: TypeNode): TypeAliasDeclaration;
4216     function createEnumDeclaration(decorators: readonly Decorator[] | undefined, modifiers: readonly Modifier[] | undefined, name: string | Identifier, members: readonly EnumMember[]): EnumDeclaration;
4217     function updateEnumDeclaration(node: EnumDeclaration, decorators: readonly Decorator[] | undefined, modifiers: readonly Modifier[] | undefined, name: Identifier, members: readonly EnumMember[]): EnumDeclaration;
4218     function createModuleDeclaration(decorators: readonly Decorator[] | undefined, modifiers: readonly Modifier[] | undefined, name: ModuleName, body: ModuleBody | undefined, flags?: NodeFlags): ModuleDeclaration;
4219     function updateModuleDeclaration(node: ModuleDeclaration, decorators: readonly Decorator[] | undefined, modifiers: readonly Modifier[] | undefined, name: ModuleName, body: ModuleBody | undefined): ModuleDeclaration;
4220     function createModuleBlock(statements: readonly Statement[]): ModuleBlock;
4221     function updateModuleBlock(node: ModuleBlock, statements: readonly Statement[]): ModuleBlock;
4222     function createCaseBlock(clauses: readonly CaseOrDefaultClause[]): CaseBlock;
4223     function updateCaseBlock(node: CaseBlock, clauses: readonly CaseOrDefaultClause[]): CaseBlock;
4224     function createNamespaceExportDeclaration(name: string | Identifier): NamespaceExportDeclaration;
4225     function updateNamespaceExportDeclaration(node: NamespaceExportDeclaration, name: Identifier): NamespaceExportDeclaration;
4226     function createImportEqualsDeclaration(decorators: readonly Decorator[] | undefined, modifiers: readonly Modifier[] | undefined, name: string | Identifier, moduleReference: ModuleReference): ImportEqualsDeclaration;
4227     function updateImportEqualsDeclaration(node: ImportEqualsDeclaration, decorators: readonly Decorator[] | undefined, modifiers: readonly Modifier[] | undefined, name: Identifier, moduleReference: ModuleReference): ImportEqualsDeclaration;
4228     function createImportDeclaration(decorators: readonly Decorator[] | undefined, modifiers: readonly Modifier[] | undefined, importClause: ImportClause | undefined, moduleSpecifier: Expression): ImportDeclaration;
4229     function updateImportDeclaration(node: ImportDeclaration, decorators: readonly Decorator[] | undefined, modifiers: readonly Modifier[] | undefined, importClause: ImportClause | undefined, moduleSpecifier: Expression): ImportDeclaration;
4230     function createImportClause(name: Identifier | undefined, namedBindings: NamedImportBindings | undefined, isTypeOnly?: boolean): ImportClause;
4231     function updateImportClause(node: ImportClause, name: Identifier | undefined, namedBindings: NamedImportBindings | undefined, isTypeOnly: boolean): ImportClause;
4232     function createNamespaceImport(name: Identifier): NamespaceImport;
4233     function createNamespaceExport(name: Identifier): NamespaceExport;
4234     function updateNamespaceImport(node: NamespaceImport, name: Identifier): NamespaceImport;
4235     function updateNamespaceExport(node: NamespaceExport, name: Identifier): NamespaceExport;
4236     function createNamedImports(elements: readonly ImportSpecifier[]): NamedImports;
4237     function updateNamedImports(node: NamedImports, elements: readonly ImportSpecifier[]): NamedImports;
4238     function createImportSpecifier(propertyName: Identifier | undefined, name: Identifier): ImportSpecifier;
4239     function updateImportSpecifier(node: ImportSpecifier, propertyName: Identifier | undefined, name: Identifier): ImportSpecifier;
4240     function createExportAssignment(decorators: readonly Decorator[] | undefined, modifiers: readonly Modifier[] | undefined, isExportEquals: boolean | undefined, expression: Expression): ExportAssignment;
4241     function updateExportAssignment(node: ExportAssignment, decorators: readonly Decorator[] | undefined, modifiers: readonly Modifier[] | undefined, expression: Expression): ExportAssignment;
4242     function createExportDeclaration(decorators: readonly Decorator[] | undefined, modifiers: readonly Modifier[] | undefined, exportClause: NamedExportBindings | undefined, moduleSpecifier?: Expression, isTypeOnly?: boolean): ExportDeclaration;
4243     function updateExportDeclaration(node: ExportDeclaration, decorators: readonly Decorator[] | undefined, modifiers: readonly Modifier[] | undefined, exportClause: NamedExportBindings | undefined, moduleSpecifier: Expression | undefined, isTypeOnly: boolean): ExportDeclaration;
4244     function createNamedExports(elements: readonly ExportSpecifier[]): NamedExports;
4245     function updateNamedExports(node: NamedExports, elements: readonly ExportSpecifier[]): NamedExports;
4246     function createExportSpecifier(propertyName: string | Identifier | undefined, name: string | Identifier): ExportSpecifier;
4247     function updateExportSpecifier(node: ExportSpecifier, propertyName: Identifier | undefined, name: Identifier): ExportSpecifier;
4248     function createExternalModuleReference(expression: Expression): ExternalModuleReference;
4249     function updateExternalModuleReference(node: ExternalModuleReference, expression: Expression): ExternalModuleReference;
4250     function createJsxElement(openingElement: JsxOpeningElement, children: readonly JsxChild[], closingElement: JsxClosingElement): JsxElement;
4251     function updateJsxElement(node: JsxElement, openingElement: JsxOpeningElement, children: readonly JsxChild[], closingElement: JsxClosingElement): JsxElement;
4252     function createJsxSelfClosingElement(tagName: JsxTagNameExpression, typeArguments: readonly TypeNode[] | undefined, attributes: JsxAttributes): JsxSelfClosingElement;
4253     function updateJsxSelfClosingElement(node: JsxSelfClosingElement, tagName: JsxTagNameExpression, typeArguments: readonly TypeNode[] | undefined, attributes: JsxAttributes): JsxSelfClosingElement;
4254     function createJsxOpeningElement(tagName: JsxTagNameExpression, typeArguments: readonly TypeNode[] | undefined, attributes: JsxAttributes): JsxOpeningElement;
4255     function updateJsxOpeningElement(node: JsxOpeningElement, tagName: JsxTagNameExpression, typeArguments: readonly TypeNode[] | undefined, attributes: JsxAttributes): JsxOpeningElement;
4256     function createJsxClosingElement(tagName: JsxTagNameExpression): JsxClosingElement;
4257     function updateJsxClosingElement(node: JsxClosingElement, tagName: JsxTagNameExpression): JsxClosingElement;
4258     function createJsxFragment(openingFragment: JsxOpeningFragment, children: readonly JsxChild[], closingFragment: JsxClosingFragment): JsxFragment;
4259     function createJsxText(text: string, containsOnlyTriviaWhiteSpaces?: boolean): JsxText;
4260     function updateJsxText(node: JsxText, text: string, containsOnlyTriviaWhiteSpaces?: boolean): JsxText;
4261     function createJsxOpeningFragment(): JsxOpeningFragment;
4262     function createJsxJsxClosingFragment(): JsxClosingFragment;
4263     function updateJsxFragment(node: JsxFragment, openingFragment: JsxOpeningFragment, children: readonly JsxChild[], closingFragment: JsxClosingFragment): JsxFragment;
4264     function createJsxAttribute(name: Identifier, initializer: StringLiteral | JsxExpression): JsxAttribute;
4265     function updateJsxAttribute(node: JsxAttribute, name: Identifier, initializer: StringLiteral | JsxExpression): JsxAttribute;
4266     function createJsxAttributes(properties: readonly JsxAttributeLike[]): JsxAttributes;
4267     function updateJsxAttributes(node: JsxAttributes, properties: readonly JsxAttributeLike[]): JsxAttributes;
4268     function createJsxSpreadAttribute(expression: Expression): JsxSpreadAttribute;
4269     function updateJsxSpreadAttribute(node: JsxSpreadAttribute, expression: Expression): JsxSpreadAttribute;
4270     function createJsxExpression(dotDotDotToken: DotDotDotToken | undefined, expression: Expression | undefined): JsxExpression;
4271     function updateJsxExpression(node: JsxExpression, expression: Expression | undefined): JsxExpression;
4272     function createCaseClause(expression: Expression, statements: readonly Statement[]): CaseClause;
4273     function updateCaseClause(node: CaseClause, expression: Expression, statements: readonly Statement[]): CaseClause;
4274     function createDefaultClause(statements: readonly Statement[]): DefaultClause;
4275     function updateDefaultClause(node: DefaultClause, statements: readonly Statement[]): DefaultClause;
4276     function createHeritageClause(token: HeritageClause["token"], types: readonly ExpressionWithTypeArguments[]): HeritageClause;
4277     function updateHeritageClause(node: HeritageClause, types: readonly ExpressionWithTypeArguments[]): HeritageClause;
4278     function createCatchClause(variableDeclaration: string | VariableDeclaration | undefined, block: Block): CatchClause;
4279     function updateCatchClause(node: CatchClause, variableDeclaration: VariableDeclaration | undefined, block: Block): CatchClause;
4280     function createPropertyAssignment(name: string | PropertyName, initializer: Expression): PropertyAssignment;
4281     function updatePropertyAssignment(node: PropertyAssignment, name: PropertyName, initializer: Expression): PropertyAssignment;
4282     function createShorthandPropertyAssignment(name: string | Identifier, objectAssignmentInitializer?: Expression): ShorthandPropertyAssignment;
4283     function updateShorthandPropertyAssignment(node: ShorthandPropertyAssignment, name: Identifier, objectAssignmentInitializer: Expression | undefined): ShorthandPropertyAssignment;
4284     function createSpreadAssignment(expression: Expression): SpreadAssignment;
4285     function updateSpreadAssignment(node: SpreadAssignment, expression: Expression): SpreadAssignment;
4286     function createEnumMember(name: string | PropertyName, initializer?: Expression): EnumMember;
4287     function updateEnumMember(node: EnumMember, name: PropertyName, initializer: Expression | undefined): EnumMember;
4288     function updateSourceFileNode(node: SourceFile, statements: readonly Statement[], isDeclarationFile?: boolean, referencedFiles?: SourceFile["referencedFiles"], typeReferences?: SourceFile["typeReferenceDirectives"], hasNoDefaultLib?: boolean, libReferences?: SourceFile["libReferenceDirectives"]): SourceFile;
4289     /**
4290      * Creates a shallow, memberwise clone of a node for mutation.
4291      */
4292     function getMutableClone<T extends Node>(node: T): T;
4293     /**
4294      * Creates a synthetic statement to act as a placeholder for a not-emitted statement in
4295      * order to preserve comments.
4296      *
4297      * @param original The original statement.
4298      */
4299     function createNotEmittedStatement(original: Node): NotEmittedStatement;
4300     /**
4301      * Creates a synthetic expression to act as a placeholder for a not-emitted expression in
4302      * order to preserve comments or sourcemap positions.
4303      *
4304      * @param expression The inner expression to emit.
4305      * @param original The original outer expression.
4306      * @param location The location for the expression. Defaults to the positions from "original" if provided.
4307      */
4308     function createPartiallyEmittedExpression(expression: Expression, original?: Node): PartiallyEmittedExpression;
4309     function updatePartiallyEmittedExpression(node: PartiallyEmittedExpression, expression: Expression): PartiallyEmittedExpression;
4310     function createCommaList(elements: readonly Expression[]): CommaListExpression;
4311     function updateCommaList(node: CommaListExpression, elements: readonly Expression[]): CommaListExpression;
4312     function createBundle(sourceFiles: readonly SourceFile[], prepends?: readonly (UnparsedSource | InputFiles)[]): Bundle;
4313     function createUnparsedSourceFile(text: string): UnparsedSource;
4314     function createUnparsedSourceFile(inputFile: InputFiles, type: "js" | "dts", stripInternal?: boolean): UnparsedSource;
4315     function createUnparsedSourceFile(text: string, mapPath: string | undefined, map: string | undefined): UnparsedSource;
4316     function createInputFiles(javascriptText: string, declarationText: string): InputFiles;
4317     function createInputFiles(readFileText: (path: string) => string | undefined, javascriptPath: string, javascriptMapPath: string | undefined, declarationPath: string, declarationMapPath: string | undefined, buildInfoPath: string | undefined): InputFiles;
4318     function createInputFiles(javascriptText: string, declarationText: string, javascriptMapPath: string | undefined, javascriptMapText: string | undefined, declarationMapPath: string | undefined, declarationMapText: string | undefined): InputFiles;
4319     function updateBundle(node: Bundle, sourceFiles: readonly SourceFile[], prepends?: readonly (UnparsedSource | InputFiles)[]): Bundle;
4320     function createImmediatelyInvokedFunctionExpression(statements: readonly Statement[]): CallExpression;
4321     function createImmediatelyInvokedFunctionExpression(statements: readonly Statement[], param: ParameterDeclaration, paramValue: Expression): CallExpression;
4322     function createImmediatelyInvokedArrowFunction(statements: readonly Statement[]): CallExpression;
4323     function createImmediatelyInvokedArrowFunction(statements: readonly Statement[], param: ParameterDeclaration, paramValue: Expression): CallExpression;
4324     function createComma(left: Expression, right: Expression): Expression;
4325     function createLessThan(left: Expression, right: Expression): Expression;
4326     function createAssignment(left: ObjectLiteralExpression | ArrayLiteralExpression, right: Expression): DestructuringAssignment;
4327     function createAssignment(left: Expression, right: Expression): BinaryExpression;
4328     function createStrictEquality(left: Expression, right: Expression): BinaryExpression;
4329     function createStrictInequality(left: Expression, right: Expression): BinaryExpression;
4330     function createAdd(left: Expression, right: Expression): BinaryExpression;
4331     function createSubtract(left: Expression, right: Expression): BinaryExpression;
4332     function createPostfixIncrement(operand: Expression): PostfixUnaryExpression;
4333     function createLogicalAnd(left: Expression, right: Expression): BinaryExpression;
4334     function createLogicalOr(left: Expression, right: Expression): BinaryExpression;
4335     function createNullishCoalesce(left: Expression, right: Expression): BinaryExpression;
4336     function createLogicalNot(operand: Expression): PrefixUnaryExpression;
4337     function createVoidZero(): VoidExpression;
4338     function createExportDefault(expression: Expression): ExportAssignment;
4339     function createExternalModuleExport(exportName: Identifier): ExportDeclaration;
4340     /**
4341      * Clears any EmitNode entries from parse-tree nodes.
4342      * @param sourceFile A source file.
4343      */
4344     function disposeEmitNodes(sourceFile: SourceFile): void;
4345     function setTextRange<T extends TextRange>(range: T, location: TextRange | undefined): T;
4346     /**
4347      * Sets flags that control emit behavior of a node.
4348      */
4349     function setEmitFlags<T extends Node>(node: T, emitFlags: EmitFlags): T;
4350     /**
4351      * Gets a custom text range to use when emitting source maps.
4352      */
4353     function getSourceMapRange(node: Node): SourceMapRange;
4354     /**
4355      * Sets a custom text range to use when emitting source maps.
4356      */
4357     function setSourceMapRange<T extends Node>(node: T, range: SourceMapRange | undefined): T;
4358     /**
4359      * Create an external source map source file reference
4360      */
4361     function createSourceMapSource(fileName: string, text: string, skipTrivia?: (pos: number) => number): SourceMapSource;
4362     /**
4363      * Gets the TextRange to use for source maps for a token of a node.
4364      */
4365     function getTokenSourceMapRange(node: Node, token: SyntaxKind): SourceMapRange | undefined;
4366     /**
4367      * Sets the TextRange to use for source maps for a token of a node.
4368      */
4369     function setTokenSourceMapRange<T extends Node>(node: T, token: SyntaxKind, range: SourceMapRange | undefined): T;
4370     /**
4371      * Gets a custom text range to use when emitting comments.
4372      */
4373     function getCommentRange(node: Node): TextRange;
4374     /**
4375      * Sets a custom text range to use when emitting comments.
4376      */
4377     function setCommentRange<T extends Node>(node: T, range: TextRange): T;
4378     function getSyntheticLeadingComments(node: Node): SynthesizedComment[] | undefined;
4379     function setSyntheticLeadingComments<T extends Node>(node: T, comments: SynthesizedComment[] | undefined): T;
4380     function addSyntheticLeadingComment<T extends Node>(node: T, kind: SyntaxKind.SingleLineCommentTrivia | SyntaxKind.MultiLineCommentTrivia, text: string, hasTrailingNewLine?: boolean): T;
4381     function getSyntheticTrailingComments(node: Node): SynthesizedComment[] | undefined;
4382     function setSyntheticTrailingComments<T extends Node>(node: T, comments: SynthesizedComment[] | undefined): T;
4383     function addSyntheticTrailingComment<T extends Node>(node: T, kind: SyntaxKind.SingleLineCommentTrivia | SyntaxKind.MultiLineCommentTrivia, text: string, hasTrailingNewLine?: boolean): T;
4384     function moveSyntheticComments<T extends Node>(node: T, original: Node): T;
4385     /**
4386      * Gets the constant value to emit for an expression.
4387      */
4388     function getConstantValue(node: PropertyAccessExpression | ElementAccessExpression): string | number | undefined;
4389     /**
4390      * Sets the constant value to emit for an expression.
4391      */
4392     function setConstantValue(node: PropertyAccessExpression | ElementAccessExpression, value: string | number): PropertyAccessExpression | ElementAccessExpression;
4393     /**
4394      * Adds an EmitHelper to a node.
4395      */
4396     function addEmitHelper<T extends Node>(node: T, helper: EmitHelper): T;
4397     /**
4398      * Add EmitHelpers to a node.
4399      */
4400     function addEmitHelpers<T extends Node>(node: T, helpers: EmitHelper[] | undefined): T;
4401     /**
4402      * Removes an EmitHelper from a node.
4403      */
4404     function removeEmitHelper(node: Node, helper: EmitHelper): boolean;
4405     /**
4406      * Gets the EmitHelpers of a node.
4407      */
4408     function getEmitHelpers(node: Node): EmitHelper[] | undefined;
4409     /**
4410      * Moves matching emit helpers from a source node to a target node.
4411      */
4412     function moveEmitHelpers(source: Node, target: Node, predicate: (helper: EmitHelper) => boolean): void;
4413     function setOriginalNode<T extends Node>(node: T, original: Node | undefined): T;
4414 }
4415 declare namespace ts {
4416     /**
4417      * Visits a Node using the supplied visitor, possibly returning a new Node in its place.
4418      *
4419      * @param node The Node to visit.
4420      * @param visitor The callback used to visit the Node.
4421      * @param test A callback to execute to verify the Node is valid.
4422      * @param lift An optional callback to execute to lift a NodeArray into a valid Node.
4423      */
4424     function visitNode<T extends Node>(node: T | undefined, visitor: Visitor | undefined, test?: (node: Node) => boolean, lift?: (node: NodeArray<Node>) => T): T;
4425     /**
4426      * Visits a Node using the supplied visitor, possibly returning a new Node in its place.
4427      *
4428      * @param node The Node to visit.
4429      * @param visitor The callback used to visit the Node.
4430      * @param test A callback to execute to verify the Node is valid.
4431      * @param lift An optional callback to execute to lift a NodeArray into a valid Node.
4432      */
4433     function visitNode<T extends Node>(node: T | undefined, visitor: Visitor | undefined, test?: (node: Node) => boolean, lift?: (node: NodeArray<Node>) => T): T | undefined;
4434     /**
4435      * Visits a NodeArray using the supplied visitor, possibly returning a new NodeArray in its place.
4436      *
4437      * @param nodes The NodeArray to visit.
4438      * @param visitor The callback used to visit a Node.
4439      * @param test A node test to execute for each node.
4440      * @param start An optional value indicating the starting offset at which to start visiting.
4441      * @param count An optional value indicating the maximum number of nodes to visit.
4442      */
4443     function visitNodes<T extends Node>(nodes: NodeArray<T> | undefined, visitor: Visitor, test?: (node: Node) => boolean, start?: number, count?: number): NodeArray<T>;
4444     /**
4445      * Visits a NodeArray using the supplied visitor, possibly returning a new NodeArray in its place.
4446      *
4447      * @param nodes The NodeArray to visit.
4448      * @param visitor The callback used to visit a Node.
4449      * @param test A node test to execute for each node.
4450      * @param start An optional value indicating the starting offset at which to start visiting.
4451      * @param count An optional value indicating the maximum number of nodes to visit.
4452      */
4453     function visitNodes<T extends Node>(nodes: NodeArray<T> | undefined, visitor: Visitor, test?: (node: Node) => boolean, start?: number, count?: number): NodeArray<T> | undefined;
4454     /**
4455      * Starts a new lexical environment and visits a statement list, ending the lexical environment
4456      * and merging hoisted declarations upon completion.
4457      */
4458     function visitLexicalEnvironment(statements: NodeArray<Statement>, visitor: Visitor, context: TransformationContext, start?: number, ensureUseStrict?: boolean): NodeArray<Statement>;
4459     /**
4460      * Starts a new lexical environment and visits a parameter list, suspending the lexical
4461      * environment upon completion.
4462      */
4463     function visitParameterList(nodes: NodeArray<ParameterDeclaration>, visitor: Visitor, context: TransformationContext, nodesVisitor?: <T extends Node>(nodes: NodeArray<T>, visitor: Visitor, test?: (node: Node) => boolean, start?: number, count?: number) => NodeArray<T>): NodeArray<ParameterDeclaration>;
4464     function visitParameterList(nodes: NodeArray<ParameterDeclaration> | undefined, visitor: Visitor, context: TransformationContext, nodesVisitor?: <T extends Node>(nodes: NodeArray<T> | undefined, visitor: Visitor, test?: (node: Node) => boolean, start?: number, count?: number) => NodeArray<T> | undefined): NodeArray<ParameterDeclaration> | undefined;
4465     /**
4466      * Resumes a suspended lexical environment and visits a function body, ending the lexical
4467      * environment and merging hoisted declarations upon completion.
4468      */
4469     function visitFunctionBody(node: FunctionBody, visitor: Visitor, context: TransformationContext): FunctionBody;
4470     /**
4471      * Resumes a suspended lexical environment and visits a function body, ending the lexical
4472      * environment and merging hoisted declarations upon completion.
4473      */
4474     function visitFunctionBody(node: FunctionBody | undefined, visitor: Visitor, context: TransformationContext): FunctionBody | undefined;
4475     /**
4476      * Resumes a suspended lexical environment and visits a concise body, ending the lexical
4477      * environment and merging hoisted declarations upon completion.
4478      */
4479     function visitFunctionBody(node: ConciseBody, visitor: Visitor, context: TransformationContext): ConciseBody;
4480     /**
4481      * Visits each child of a Node using the supplied visitor, possibly returning a new Node of the same kind in its place.
4482      *
4483      * @param node The Node whose children will be visited.
4484      * @param visitor The callback used to visit each child.
4485      * @param context A lexical environment context for the visitor.
4486      */
4487     function visitEachChild<T extends Node>(node: T, visitor: Visitor, context: TransformationContext): T;
4488     /**
4489      * Visits each child of a Node using the supplied visitor, possibly returning a new Node of the same kind in its place.
4490      *
4491      * @param node The Node whose children will be visited.
4492      * @param visitor The callback used to visit each child.
4493      * @param context A lexical environment context for the visitor.
4494      */
4495     function visitEachChild<T extends Node>(node: T | undefined, visitor: Visitor, context: TransformationContext, nodesVisitor?: typeof visitNodes, tokenVisitor?: Visitor): T | undefined;
4496 }
4497 declare namespace ts {
4498     function getTsBuildInfoEmitOutputFilePath(options: CompilerOptions): string | undefined;
4499     function getOutputFileNames(commandLine: ParsedCommandLine, inputFileName: string, ignoreCase: boolean): readonly string[];
4500     function createPrinter(printerOptions?: PrinterOptions, handlers?: PrintHandlers): Printer;
4501 }
4502 declare namespace ts {
4503     export function findConfigFile(searchPath: string, fileExists: (fileName: string) => boolean, configName?: string): string | undefined;
4504     export function resolveTripleslashReference(moduleName: string, containingFile: string): string;
4505     export function createCompilerHost(options: CompilerOptions, setParentNodes?: boolean): CompilerHost;
4506     export function getPreEmitDiagnostics(program: Program, sourceFile?: SourceFile, cancellationToken?: CancellationToken): readonly Diagnostic[];
4507     export interface FormatDiagnosticsHost {
4508         getCurrentDirectory(): string;
4509         getCanonicalFileName(fileName: string): string;
4510         getNewLine(): string;
4511     }
4512     export function formatDiagnostics(diagnostics: readonly Diagnostic[], host: FormatDiagnosticsHost): string;
4513     export function formatDiagnostic(diagnostic: Diagnostic, host: FormatDiagnosticsHost): string;
4514     export function formatDiagnosticsWithColorAndContext(diagnostics: readonly Diagnostic[], host: FormatDiagnosticsHost): string;
4515     export function flattenDiagnosticMessageText(diag: string | DiagnosticMessageChain | undefined, newLine: string, indent?: number): string;
4516     export function getConfigFileParsingDiagnostics(configFileParseResult: ParsedCommandLine): readonly Diagnostic[];
4517     /**
4518      * Create a new 'Program' instance. A Program is an immutable collection of 'SourceFile's and a 'CompilerOptions'
4519      * that represent a compilation unit.
4520      *
4521      * Creating a program proceeds from a set of root files, expanding the set of inputs by following imports and
4522      * triple-slash-reference-path directives transitively. '@types' and triple-slash-reference-types are also pulled in.
4523      *
4524      * @param createProgramOptions - The options for creating a program.
4525      * @returns A 'Program' object.
4526      */
4527     export function createProgram(createProgramOptions: CreateProgramOptions): Program;
4528     /**
4529      * Create a new 'Program' instance. A Program is an immutable collection of 'SourceFile's and a 'CompilerOptions'
4530      * that represent a compilation unit.
4531      *
4532      * Creating a program proceeds from a set of root files, expanding the set of inputs by following imports and
4533      * triple-slash-reference-path directives transitively. '@types' and triple-slash-reference-types are also pulled in.
4534      *
4535      * @param rootNames - A set of root files.
4536      * @param options - The compiler options which should be used.
4537      * @param host - The host interacts with the underlying file system.
4538      * @param oldProgram - Reuses an old program structure.
4539      * @param configFileParsingDiagnostics - error during config file parsing
4540      * @returns A 'Program' object.
4541      */
4542     export function createProgram(rootNames: readonly string[], options: CompilerOptions, host?: CompilerHost, oldProgram?: Program, configFileParsingDiagnostics?: readonly Diagnostic[]): Program;
4543     /** @deprecated */ export interface ResolveProjectReferencePathHost {
4544         fileExists(fileName: string): boolean;
4545     }
4546     /**
4547      * Returns the target config filename of a project reference.
4548      * Note: The file might not exist.
4549      */
4550     export function resolveProjectReferencePath(ref: ProjectReference): ResolvedConfigFileName;
4551     /** @deprecated */ export function resolveProjectReferencePath(host: ResolveProjectReferencePathHost, ref: ProjectReference): ResolvedConfigFileName;
4552     export {};
4553 }
4554 declare namespace ts {
4555     interface EmitOutput {
4556         outputFiles: OutputFile[];
4557         emitSkipped: boolean;
4558     }
4559     interface OutputFile {
4560         name: string;
4561         writeByteOrderMark: boolean;
4562         text: string;
4563     }
4564 }
4565 declare namespace ts {
4566     type AffectedFileResult<T> = {
4567         result: T;
4568         affected: SourceFile | Program;
4569     } | undefined;
4570     interface BuilderProgramHost {
4571         /**
4572          * return true if file names are treated with case sensitivity
4573          */
4574         useCaseSensitiveFileNames(): boolean;
4575         /**
4576          * If provided this would be used this hash instead of actual file shape text for detecting changes
4577          */
4578         createHash?: (data: string) => string;
4579         /**
4580          * When emit or emitNextAffectedFile are called without writeFile,
4581          * this callback if present would be used to write files
4582          */
4583         writeFile?: WriteFileCallback;
4584     }
4585     /**
4586      * Builder to manage the program state changes
4587      */
4588     interface BuilderProgram {
4589         /**
4590          * Returns current program
4591          */
4592         getProgram(): Program;
4593         /**
4594          * Get compiler options of the program
4595          */
4596         getCompilerOptions(): CompilerOptions;
4597         /**
4598          * Get the source file in the program with file name
4599          */
4600         getSourceFile(fileName: string): SourceFile | undefined;
4601         /**
4602          * Get a list of files in the program
4603          */
4604         getSourceFiles(): readonly SourceFile[];
4605         /**
4606          * Get the diagnostics for compiler options
4607          */
4608         getOptionsDiagnostics(cancellationToken?: CancellationToken): readonly Diagnostic[];
4609         /**
4610          * Get the diagnostics that dont belong to any file
4611          */
4612         getGlobalDiagnostics(cancellationToken?: CancellationToken): readonly Diagnostic[];
4613         /**
4614          * Get the diagnostics from config file parsing
4615          */
4616         getConfigFileParsingDiagnostics(): readonly Diagnostic[];
4617         /**
4618          * Get the syntax diagnostics, for all source files if source file is not supplied
4619          */
4620         getSyntacticDiagnostics(sourceFile?: SourceFile, cancellationToken?: CancellationToken): readonly Diagnostic[];
4621         /**
4622          * Get the declaration diagnostics, for all source files if source file is not supplied
4623          */
4624         getDeclarationDiagnostics(sourceFile?: SourceFile, cancellationToken?: CancellationToken): readonly DiagnosticWithLocation[];
4625         /**
4626          * Get all the dependencies of the file
4627          */
4628         getAllDependencies(sourceFile: SourceFile): readonly string[];
4629         /**
4630          * Gets the semantic diagnostics from the program corresponding to this state of file (if provided) or whole program
4631          * The semantic diagnostics are cached and managed here
4632          * Note that it is assumed that when asked about semantic diagnostics through this API,
4633          * the file has been taken out of affected files so it is safe to use cache or get from program and cache the diagnostics
4634          * In case of SemanticDiagnosticsBuilderProgram if the source file is not provided,
4635          * it will iterate through all the affected files, to ensure that cache stays valid and yet provide a way to get all semantic diagnostics
4636          */
4637         getSemanticDiagnostics(sourceFile?: SourceFile, cancellationToken?: CancellationToken): readonly Diagnostic[];
4638         /**
4639          * Emits the JavaScript and declaration files.
4640          * When targetSource file is specified, emits the files corresponding to that source file,
4641          * otherwise for the whole program.
4642          * In case of EmitAndSemanticDiagnosticsBuilderProgram, when targetSourceFile is specified,
4643          * it is assumed that that file is handled from affected file list. If targetSourceFile is not specified,
4644          * it will only emit all the affected files instead of whole program
4645          *
4646          * The first of writeFile if provided, writeFile of BuilderProgramHost if provided, writeFile of compiler host
4647          * in that order would be used to write the files
4648          */
4649         emit(targetSourceFile?: SourceFile, writeFile?: WriteFileCallback, cancellationToken?: CancellationToken, emitOnlyDtsFiles?: boolean, customTransformers?: CustomTransformers): EmitResult;
4650         /**
4651          * Get the current directory of the program
4652          */
4653         getCurrentDirectory(): string;
4654     }
4655     /**
4656      * The builder that caches the semantic diagnostics for the program and handles the changed files and affected files
4657      */
4658     interface SemanticDiagnosticsBuilderProgram extends BuilderProgram {
4659         /**
4660          * Gets the semantic diagnostics from the program for the next affected file and caches it
4661          * Returns undefined if the iteration is complete
4662          */
4663         getSemanticDiagnosticsOfNextAffectedFile(cancellationToken?: CancellationToken, ignoreSourceFile?: (sourceFile: SourceFile) => boolean): AffectedFileResult<readonly Diagnostic[]>;
4664     }
4665     /**
4666      * The builder that can handle the changes in program and iterate through changed file to emit the files
4667      * The semantic diagnostics are cached per file and managed by clearing for the changed/affected files
4668      */
4669     interface EmitAndSemanticDiagnosticsBuilderProgram extends SemanticDiagnosticsBuilderProgram {
4670         /**
4671          * Emits the next affected file's emit result (EmitResult and sourceFiles emitted) or returns undefined if iteration is complete
4672          * The first of writeFile if provided, writeFile of BuilderProgramHost if provided, writeFile of compiler host
4673          * in that order would be used to write the files
4674          */
4675         emitNextAffectedFile(writeFile?: WriteFileCallback, cancellationToken?: CancellationToken, emitOnlyDtsFiles?: boolean, customTransformers?: CustomTransformers): AffectedFileResult<EmitResult>;
4676     }
4677     /**
4678      * Create the builder to manage semantic diagnostics and cache them
4679      */
4680     function createSemanticDiagnosticsBuilderProgram(newProgram: Program, host: BuilderProgramHost, oldProgram?: SemanticDiagnosticsBuilderProgram, configFileParsingDiagnostics?: readonly Diagnostic[]): SemanticDiagnosticsBuilderProgram;
4681     function createSemanticDiagnosticsBuilderProgram(rootNames: readonly string[] | undefined, options: CompilerOptions | undefined, host?: CompilerHost, oldProgram?: SemanticDiagnosticsBuilderProgram, configFileParsingDiagnostics?: readonly Diagnostic[], projectReferences?: readonly ProjectReference[]): SemanticDiagnosticsBuilderProgram;
4682     /**
4683      * Create the builder that can handle the changes in program and iterate through changed files
4684      * to emit the those files and manage semantic diagnostics cache as well
4685      */
4686     function createEmitAndSemanticDiagnosticsBuilderProgram(newProgram: Program, host: BuilderProgramHost, oldProgram?: EmitAndSemanticDiagnosticsBuilderProgram, configFileParsingDiagnostics?: readonly Diagnostic[]): EmitAndSemanticDiagnosticsBuilderProgram;
4687     function createEmitAndSemanticDiagnosticsBuilderProgram(rootNames: readonly string[] | undefined, options: CompilerOptions | undefined, host?: CompilerHost, oldProgram?: EmitAndSemanticDiagnosticsBuilderProgram, configFileParsingDiagnostics?: readonly Diagnostic[], projectReferences?: readonly ProjectReference[]): EmitAndSemanticDiagnosticsBuilderProgram;
4688     /**
4689      * Creates a builder thats just abstraction over program and can be used with watch
4690      */
4691     function createAbstractBuilder(newProgram: Program, host: BuilderProgramHost, oldProgram?: BuilderProgram, configFileParsingDiagnostics?: readonly Diagnostic[]): BuilderProgram;
4692     function createAbstractBuilder(rootNames: readonly string[] | undefined, options: CompilerOptions | undefined, host?: CompilerHost, oldProgram?: BuilderProgram, configFileParsingDiagnostics?: readonly Diagnostic[], projectReferences?: readonly ProjectReference[]): BuilderProgram;
4693 }
4694 declare namespace ts {
4695     interface ReadBuildProgramHost {
4696         useCaseSensitiveFileNames(): boolean;
4697         getCurrentDirectory(): string;
4698         readFile(fileName: string): string | undefined;
4699     }
4700     function readBuilderProgram(compilerOptions: CompilerOptions, host: ReadBuildProgramHost): EmitAndSemanticDiagnosticsBuilderProgram | undefined;
4701     function createIncrementalCompilerHost(options: CompilerOptions, system?: System): CompilerHost;
4702     interface IncrementalProgramOptions<T extends BuilderProgram> {
4703         rootNames: readonly string[];
4704         options: CompilerOptions;
4705         configFileParsingDiagnostics?: readonly Diagnostic[];
4706         projectReferences?: readonly ProjectReference[];
4707         host?: CompilerHost;
4708         createProgram?: CreateProgram<T>;
4709     }
4710     function createIncrementalProgram<T extends BuilderProgram = EmitAndSemanticDiagnosticsBuilderProgram>({ rootNames, options, configFileParsingDiagnostics, projectReferences, host, createProgram }: IncrementalProgramOptions<T>): T;
4711     type WatchStatusReporter = (diagnostic: Diagnostic, newLine: string, options: CompilerOptions, errorCount?: number) => void;
4712     /** Create the program with rootNames and options, if they are undefined, oldProgram and new configFile diagnostics create new program */
4713     type CreateProgram<T extends BuilderProgram> = (rootNames: readonly string[] | undefined, options: CompilerOptions | undefined, host?: CompilerHost, oldProgram?: T, configFileParsingDiagnostics?: readonly Diagnostic[], projectReferences?: readonly ProjectReference[] | undefined) => T;
4714     /** Host that has watch functionality used in --watch mode */
4715     interface WatchHost {
4716         /** If provided, called with Diagnostic message that informs about change in watch status */
4717         onWatchStatusChange?(diagnostic: Diagnostic, newLine: string, options: CompilerOptions, errorCount?: number): void;
4718         /** Used to watch changes in source files, missing files needed to update the program or config file */
4719         watchFile(path: string, callback: FileWatcherCallback, pollingInterval?: number, options?: CompilerOptions): FileWatcher;
4720         /** Used to watch resolved module's failed lookup locations, config file specs, type roots where auto type reference directives are added */
4721         watchDirectory(path: string, callback: DirectoryWatcherCallback, recursive?: boolean, options?: CompilerOptions): FileWatcher;
4722         /** If provided, will be used to set delayed compilation, so that multiple changes in short span are compiled together */
4723         setTimeout?(callback: (...args: any[]) => void, ms: number, ...args: any[]): any;
4724         /** If provided, will be used to reset existing delayed compilation */
4725         clearTimeout?(timeoutId: any): void;
4726     }
4727     interface ProgramHost<T extends BuilderProgram> {
4728         /**
4729          * Used to create the program when need for program creation or recreation detected
4730          */
4731         createProgram: CreateProgram<T>;
4732         useCaseSensitiveFileNames(): boolean;
4733         getNewLine(): string;
4734         getCurrentDirectory(): string;
4735         getDefaultLibFileName(options: CompilerOptions): string;
4736         getDefaultLibLocation?(): string;
4737         createHash?(data: string): string;
4738         /**
4739          * Use to check file presence for source files and
4740          * if resolveModuleNames is not provided (complier is in charge of module resolution) then module files as well
4741          */
4742         fileExists(path: string): boolean;
4743         /**
4744          * Use to read file text for source files and
4745          * if resolveModuleNames is not provided (complier is in charge of module resolution) then module files as well
4746          */
4747         readFile(path: string, encoding?: string): string | undefined;
4748         /** If provided, used for module resolution as well as to handle directory structure */
4749         directoryExists?(path: string): boolean;
4750         /** If provided, used in resolutions as well as handling directory structure */
4751         getDirectories?(path: string): string[];
4752         /** If provided, used to cache and handle directory structure modifications */
4753         readDirectory?(path: string, extensions?: readonly string[], exclude?: readonly string[], include?: readonly string[], depth?: number): string[];
4754         /** Symbol links resolution */
4755         realpath?(path: string): string;
4756         /** If provided would be used to write log about compilation */
4757         trace?(s: string): void;
4758         /** If provided is used to get the environment variable */
4759         getEnvironmentVariable?(name: string): string | undefined;
4760         /** If provided, used to resolve the module names, otherwise typescript's default module resolution */
4761         resolveModuleNames?(moduleNames: string[], containingFile: string, reusedNames: string[] | undefined, redirectedReference: ResolvedProjectReference | undefined, options: CompilerOptions): (ResolvedModule | undefined)[];
4762         /** If provided, used to resolve type reference directives, otherwise typescript's default resolution */
4763         resolveTypeReferenceDirectives?(typeReferenceDirectiveNames: string[], containingFile: string, redirectedReference: ResolvedProjectReference | undefined, options: CompilerOptions): (ResolvedTypeReferenceDirective | undefined)[];
4764     }
4765     interface WatchCompilerHost<T extends BuilderProgram> extends ProgramHost<T>, WatchHost {
4766         /** Instead of using output d.ts file from project reference, use its source file */
4767         useSourceOfProjectReferenceRedirect?(): boolean;
4768         /** If provided, callback to invoke after every new program creation */
4769         afterProgramCreate?(program: T): void;
4770     }
4771     /**
4772      * Host to create watch with root files and options
4773      */
4774     interface WatchCompilerHostOfFilesAndCompilerOptions<T extends BuilderProgram> extends WatchCompilerHost<T> {
4775         /** root files to use to generate program */
4776         rootFiles: string[];
4777         /** Compiler options */
4778         options: CompilerOptions;
4779         watchOptions?: WatchOptions;
4780         /** Project References */
4781         projectReferences?: readonly ProjectReference[];
4782     }
4783     /**
4784      * Host to create watch with config file
4785      */
4786     interface WatchCompilerHostOfConfigFile<T extends BuilderProgram> extends WatchCompilerHost<T>, ConfigFileDiagnosticsReporter {
4787         /** Name of the config file to compile */
4788         configFileName: string;
4789         /** Options to extend */
4790         optionsToExtend?: CompilerOptions;
4791         watchOptionsToExtend?: WatchOptions;
4792         extraFileExtensions?: readonly FileExtensionInfo[];
4793         /**
4794          * Used to generate source file names from the config file and its include, exclude, files rules
4795          * and also to cache the directory stucture
4796          */
4797         readDirectory(path: string, extensions?: readonly string[], exclude?: readonly string[], include?: readonly string[], depth?: number): string[];
4798     }
4799     interface Watch<T> {
4800         /** Synchronize with host and get updated program */
4801         getProgram(): T;
4802         /** Closes the watch */
4803         close(): void;
4804     }
4805     /**
4806      * Creates the watch what generates program using the config file
4807      */
4808     interface WatchOfConfigFile<T> extends Watch<T> {
4809     }
4810     /**
4811      * Creates the watch that generates program using the root files and compiler options
4812      */
4813     interface WatchOfFilesAndCompilerOptions<T> extends Watch<T> {
4814         /** Updates the root files in the program, only if this is not config file compilation */
4815         updateRootFileNames(fileNames: string[]): void;
4816     }
4817     /**
4818      * Create the watch compiler host for either configFile or fileNames and its options
4819      */
4820     function createWatchCompilerHost<T extends BuilderProgram>(configFileName: string, optionsToExtend: CompilerOptions | undefined, system: System, createProgram?: CreateProgram<T>, reportDiagnostic?: DiagnosticReporter, reportWatchStatus?: WatchStatusReporter, watchOptionsToExtend?: WatchOptions, extraFileExtensions?: readonly FileExtensionInfo[]): WatchCompilerHostOfConfigFile<T>;
4821     function createWatchCompilerHost<T extends BuilderProgram>(rootFiles: string[], options: CompilerOptions, system: System, createProgram?: CreateProgram<T>, reportDiagnostic?: DiagnosticReporter, reportWatchStatus?: WatchStatusReporter, projectReferences?: readonly ProjectReference[], watchOptions?: WatchOptions): WatchCompilerHostOfFilesAndCompilerOptions<T>;
4822     /**
4823      * Creates the watch from the host for root files and compiler options
4824      */
4825     function createWatchProgram<T extends BuilderProgram>(host: WatchCompilerHostOfFilesAndCompilerOptions<T>): WatchOfFilesAndCompilerOptions<T>;
4826     /**
4827      * Creates the watch from the host for config file
4828      */
4829     function createWatchProgram<T extends BuilderProgram>(host: WatchCompilerHostOfConfigFile<T>): WatchOfConfigFile<T>;
4830 }
4831 declare namespace ts {
4832     interface BuildOptions {
4833         dry?: boolean;
4834         force?: boolean;
4835         verbose?: boolean;
4836         incremental?: boolean;
4837         assumeChangesOnlyAffectDirectDependencies?: boolean;
4838         traceResolution?: boolean;
4839         [option: string]: CompilerOptionsValue | undefined;
4840     }
4841     type ReportEmitErrorSummary = (errorCount: number) => void;
4842     interface SolutionBuilderHostBase<T extends BuilderProgram> extends ProgramHost<T> {
4843         createDirectory?(path: string): void;
4844         /**
4845          * Should provide create directory and writeFile if done of invalidatedProjects is not invoked with
4846          * writeFileCallback
4847          */
4848         writeFile?(path: string, data: string, writeByteOrderMark?: boolean): void;
4849         getModifiedTime(fileName: string): Date | undefined;
4850         setModifiedTime(fileName: string, date: Date): void;
4851         deleteFile(fileName: string): void;
4852         getParsedCommandLine?(fileName: string): ParsedCommandLine | undefined;
4853         reportDiagnostic: DiagnosticReporter;
4854         reportSolutionBuilderStatus: DiagnosticReporter;
4855         afterProgramEmitAndDiagnostics?(program: T): void;
4856     }
4857     interface SolutionBuilderHost<T extends BuilderProgram> extends SolutionBuilderHostBase<T> {
4858         reportErrorSummary?: ReportEmitErrorSummary;
4859     }
4860     interface SolutionBuilderWithWatchHost<T extends BuilderProgram> extends SolutionBuilderHostBase<T>, WatchHost {
4861     }
4862     interface SolutionBuilder<T extends BuilderProgram> {
4863         build(project?: string, cancellationToken?: CancellationToken): ExitStatus;
4864         clean(project?: string): ExitStatus;
4865         buildReferences(project: string, cancellationToken?: CancellationToken): ExitStatus;
4866         cleanReferences(project?: string): ExitStatus;
4867         getNextInvalidatedProject(cancellationToken?: CancellationToken): InvalidatedProject<T> | undefined;
4868     }
4869     /**
4870      * Create a function that reports watch status by writing to the system and handles the formating of the diagnostic
4871      */
4872     function createBuilderStatusReporter(system: System, pretty?: boolean): DiagnosticReporter;
4873     function createSolutionBuilderHost<T extends BuilderProgram = EmitAndSemanticDiagnosticsBuilderProgram>(system?: System, createProgram?: CreateProgram<T>, reportDiagnostic?: DiagnosticReporter, reportSolutionBuilderStatus?: DiagnosticReporter, reportErrorSummary?: ReportEmitErrorSummary): SolutionBuilderHost<T>;
4874     function createSolutionBuilderWithWatchHost<T extends BuilderProgram = EmitAndSemanticDiagnosticsBuilderProgram>(system?: System, createProgram?: CreateProgram<T>, reportDiagnostic?: DiagnosticReporter, reportSolutionBuilderStatus?: DiagnosticReporter, reportWatchStatus?: WatchStatusReporter): SolutionBuilderWithWatchHost<T>;
4875     function createSolutionBuilder<T extends BuilderProgram>(host: SolutionBuilderHost<T>, rootNames: readonly string[], defaultOptions: BuildOptions): SolutionBuilder<T>;
4876     function createSolutionBuilderWithWatch<T extends BuilderProgram>(host: SolutionBuilderWithWatchHost<T>, rootNames: readonly string[], defaultOptions: BuildOptions, baseWatchOptions?: WatchOptions): SolutionBuilder<T>;
4877     enum InvalidatedProjectKind {
4878         Build = 0,
4879         UpdateBundle = 1,
4880         UpdateOutputFileStamps = 2
4881     }
4882     interface InvalidatedProjectBase {
4883         readonly kind: InvalidatedProjectKind;
4884         readonly project: ResolvedConfigFileName;
4885         /**
4886          *  To dispose this project and ensure that all the necessary actions are taken and state is updated accordingly
4887          */
4888         done(cancellationToken?: CancellationToken, writeFile?: WriteFileCallback, customTransformers?: CustomTransformers): ExitStatus;
4889         getCompilerOptions(): CompilerOptions;
4890         getCurrentDirectory(): string;
4891     }
4892     interface UpdateOutputFileStampsProject extends InvalidatedProjectBase {
4893         readonly kind: InvalidatedProjectKind.UpdateOutputFileStamps;
4894         updateOutputFileStatmps(): void;
4895     }
4896     interface BuildInvalidedProject<T extends BuilderProgram> extends InvalidatedProjectBase {
4897         readonly kind: InvalidatedProjectKind.Build;
4898         getBuilderProgram(): T | undefined;
4899         getProgram(): Program | undefined;
4900         getSourceFile(fileName: string): SourceFile | undefined;
4901         getSourceFiles(): readonly SourceFile[];
4902         getOptionsDiagnostics(cancellationToken?: CancellationToken): readonly Diagnostic[];
4903         getGlobalDiagnostics(cancellationToken?: CancellationToken): readonly Diagnostic[];
4904         getConfigFileParsingDiagnostics(): readonly Diagnostic[];
4905         getSyntacticDiagnostics(sourceFile?: SourceFile, cancellationToken?: CancellationToken): readonly Diagnostic[];
4906         getAllDependencies(sourceFile: SourceFile): readonly string[];
4907         getSemanticDiagnostics(sourceFile?: SourceFile, cancellationToken?: CancellationToken): readonly Diagnostic[];
4908         getSemanticDiagnosticsOfNextAffectedFile(cancellationToken?: CancellationToken, ignoreSourceFile?: (sourceFile: SourceFile) => boolean): AffectedFileResult<readonly Diagnostic[]>;
4909         emit(targetSourceFile?: SourceFile, writeFile?: WriteFileCallback, cancellationToken?: CancellationToken, emitOnlyDtsFiles?: boolean, customTransformers?: CustomTransformers): EmitResult | undefined;
4910     }
4911     interface UpdateBundleProject<T extends BuilderProgram> extends InvalidatedProjectBase {
4912         readonly kind: InvalidatedProjectKind.UpdateBundle;
4913         emit(writeFile?: WriteFileCallback, customTransformers?: CustomTransformers): EmitResult | BuildInvalidedProject<T> | undefined;
4914     }
4915     type InvalidatedProject<T extends BuilderProgram> = UpdateOutputFileStampsProject | BuildInvalidedProject<T> | UpdateBundleProject<T>;
4916 }
4917 declare namespace ts.server {
4918     type ActionSet = "action::set";
4919     type ActionInvalidate = "action::invalidate";
4920     type ActionPackageInstalled = "action::packageInstalled";
4921     type EventTypesRegistry = "event::typesRegistry";
4922     type EventBeginInstallTypes = "event::beginInstallTypes";
4923     type EventEndInstallTypes = "event::endInstallTypes";
4924     type EventInitializationFailed = "event::initializationFailed";
4925 }
4926 declare namespace ts.server {
4927     interface TypingInstallerResponse {
4928         readonly kind: ActionSet | ActionInvalidate | EventTypesRegistry | ActionPackageInstalled | EventBeginInstallTypes | EventEndInstallTypes | EventInitializationFailed;
4929     }
4930     interface TypingInstallerRequestWithProjectName {
4931         readonly projectName: string;
4932     }
4933     interface DiscoverTypings extends TypingInstallerRequestWithProjectName {
4934         readonly fileNames: string[];
4935         readonly projectRootPath: Path;
4936         readonly compilerOptions: CompilerOptions;
4937         readonly watchOptions?: WatchOptions;
4938         readonly typeAcquisition: TypeAcquisition;
4939         readonly unresolvedImports: SortedReadonlyArray<string>;
4940         readonly cachePath?: string;
4941         readonly kind: "discover";
4942     }
4943     interface CloseProject extends TypingInstallerRequestWithProjectName {
4944         readonly kind: "closeProject";
4945     }
4946     interface TypesRegistryRequest {
4947         readonly kind: "typesRegistry";
4948     }
4949     interface InstallPackageRequest extends TypingInstallerRequestWithProjectName {
4950         readonly kind: "installPackage";
4951         readonly fileName: Path;
4952         readonly packageName: string;
4953         readonly projectRootPath: Path;
4954     }
4955     interface PackageInstalledResponse extends ProjectResponse {
4956         readonly kind: ActionPackageInstalled;
4957         readonly success: boolean;
4958         readonly message: string;
4959     }
4960     interface InitializationFailedResponse extends TypingInstallerResponse {
4961         readonly kind: EventInitializationFailed;
4962         readonly message: string;
4963     }
4964     interface ProjectResponse extends TypingInstallerResponse {
4965         readonly projectName: string;
4966     }
4967     interface InvalidateCachedTypings extends ProjectResponse {
4968         readonly kind: ActionInvalidate;
4969     }
4970     interface InstallTypes extends ProjectResponse {
4971         readonly kind: EventBeginInstallTypes | EventEndInstallTypes;
4972         readonly eventId: number;
4973         readonly typingsInstallerVersion: string;
4974         readonly packagesToInstall: readonly string[];
4975     }
4976     interface BeginInstallTypes extends InstallTypes {
4977         readonly kind: EventBeginInstallTypes;
4978     }
4979     interface EndInstallTypes extends InstallTypes {
4980         readonly kind: EventEndInstallTypes;
4981         readonly installSuccess: boolean;
4982     }
4983     interface SetTypings extends ProjectResponse {
4984         readonly typeAcquisition: TypeAcquisition;
4985         readonly compilerOptions: CompilerOptions;
4986         readonly typings: string[];
4987         readonly unresolvedImports: SortedReadonlyArray<string>;
4988         readonly kind: ActionSet;
4989     }
4990 }
4991 declare namespace ts {
4992     interface Node {
4993         getSourceFile(): SourceFile;
4994         getChildCount(sourceFile?: SourceFile): number;
4995         getChildAt(index: number, sourceFile?: SourceFile): Node;
4996         getChildren(sourceFile?: SourceFile): Node[];
4997         getStart(sourceFile?: SourceFile, includeJsDocComment?: boolean): number;
4998         getFullStart(): number;
4999         getEnd(): number;
5000         getWidth(sourceFile?: SourceFileLike): number;
5001         getFullWidth(): number;
5002         getLeadingTriviaWidth(sourceFile?: SourceFile): number;
5003         getFullText(sourceFile?: SourceFile): string;
5004         getText(sourceFile?: SourceFile): string;
5005         getFirstToken(sourceFile?: SourceFile): Node | undefined;
5006         getLastToken(sourceFile?: SourceFile): Node | undefined;
5007         forEachChild<T>(cbNode: (node: Node) => T | undefined, cbNodeArray?: (nodes: NodeArray<Node>) => T | undefined): T | undefined;
5008     }
5009     interface Identifier {
5010         readonly text: string;
5011     }
5012     interface PrivateIdentifier {
5013         readonly text: string;
5014     }
5015     interface Symbol {
5016         readonly name: string;
5017         getFlags(): SymbolFlags;
5018         getEscapedName(): __String;
5019         getName(): string;
5020         getDeclarations(): Declaration[] | undefined;
5021         getDocumentationComment(typeChecker: TypeChecker | undefined): SymbolDisplayPart[];
5022         getJsDocTags(): JSDocTagInfo[];
5023     }
5024     interface Type {
5025         getFlags(): TypeFlags;
5026         getSymbol(): Symbol | undefined;
5027         getProperties(): Symbol[];
5028         getProperty(propertyName: string): Symbol | undefined;
5029         getApparentProperties(): Symbol[];
5030         getCallSignatures(): readonly Signature[];
5031         getConstructSignatures(): readonly Signature[];
5032         getStringIndexType(): Type | undefined;
5033         getNumberIndexType(): Type | undefined;
5034         getBaseTypes(): BaseType[] | undefined;
5035         getNonNullableType(): Type;
5036         getConstraint(): Type | undefined;
5037         getDefault(): Type | undefined;
5038         isUnion(): this is UnionType;
5039         isIntersection(): this is IntersectionType;
5040         isUnionOrIntersection(): this is UnionOrIntersectionType;
5041         isLiteral(): this is LiteralType;
5042         isStringLiteral(): this is StringLiteralType;
5043         isNumberLiteral(): this is NumberLiteralType;
5044         isTypeParameter(): this is TypeParameter;
5045         isClassOrInterface(): this is InterfaceType;
5046         isClass(): this is InterfaceType;
5047     }
5048     interface TypeReference {
5049         typeArguments?: readonly Type[];
5050     }
5051     interface Signature {
5052         getDeclaration(): SignatureDeclaration;
5053         getTypeParameters(): TypeParameter[] | undefined;
5054         getParameters(): Symbol[];
5055         getReturnType(): Type;
5056         getDocumentationComment(typeChecker: TypeChecker | undefined): SymbolDisplayPart[];
5057         getJsDocTags(): JSDocTagInfo[];
5058     }
5059     interface SourceFile {
5060         getLineAndCharacterOfPosition(pos: number): LineAndCharacter;
5061         getLineEndOfPosition(pos: number): number;
5062         getLineStarts(): readonly number[];
5063         getPositionOfLineAndCharacter(line: number, character: number): number;
5064         update(newText: string, textChangeRange: TextChangeRange): SourceFile;
5065     }
5066     interface SourceFileLike {
5067         getLineAndCharacterOfPosition(pos: number): LineAndCharacter;
5068     }
5069     interface SourceMapSource {
5070         getLineAndCharacterOfPosition(pos: number): LineAndCharacter;
5071     }
5072     /**
5073      * Represents an immutable snapshot of a script at a specified time.Once acquired, the
5074      * snapshot is observably immutable. i.e. the same calls with the same parameters will return
5075      * the same values.
5076      */
5077     interface IScriptSnapshot {
5078         /** Gets a portion of the script snapshot specified by [start, end). */
5079         getText(start: number, end: number): string;
5080         /** Gets the length of this script snapshot. */
5081         getLength(): number;
5082         /**
5083          * Gets the TextChangeRange that describe how the text changed between this text and
5084          * an older version.  This information is used by the incremental parser to determine
5085          * what sections of the script need to be re-parsed.  'undefined' can be returned if the
5086          * change range cannot be determined.  However, in that case, incremental parsing will
5087          * not happen and the entire document will be re - parsed.
5088          */
5089         getChangeRange(oldSnapshot: IScriptSnapshot): TextChangeRange | undefined;
5090         /** Releases all resources held by this script snapshot */
5091         dispose?(): void;
5092     }
5093     namespace ScriptSnapshot {
5094         function fromString(text: string): IScriptSnapshot;
5095     }
5096     interface PreProcessedFileInfo {
5097         referencedFiles: FileReference[];
5098         typeReferenceDirectives: FileReference[];
5099         libReferenceDirectives: FileReference[];
5100         importedFiles: FileReference[];
5101         ambientExternalModules?: string[];
5102         isLibFile: boolean;
5103     }
5104     interface HostCancellationToken {
5105         isCancellationRequested(): boolean;
5106     }
5107     interface InstallPackageOptions {
5108         fileName: Path;
5109         packageName: string;
5110     }
5111     interface LanguageServiceHost extends GetEffectiveTypeRootsHost {
5112         getCompilationSettings(): CompilerOptions;
5113         getNewLine?(): string;
5114         getProjectVersion?(): string;
5115         getScriptFileNames(): string[];
5116         getScriptKind?(fileName: string): ScriptKind;
5117         getScriptVersion(fileName: string): string;
5118         getScriptSnapshot(fileName: string): IScriptSnapshot | undefined;
5119         getProjectReferences?(): readonly ProjectReference[] | undefined;
5120         getLocalizedDiagnosticMessages?(): any;
5121         getCancellationToken?(): HostCancellationToken;
5122         getCurrentDirectory(): string;
5123         getDefaultLibFileName(options: CompilerOptions): string;
5124         log?(s: string): void;
5125         trace?(s: string): void;
5126         error?(s: string): void;
5127         useCaseSensitiveFileNames?(): boolean;
5128         readDirectory?(path: string, extensions?: readonly string[], exclude?: readonly string[], include?: readonly string[], depth?: number): string[];
5129         readFile?(path: string, encoding?: string): string | undefined;
5130         realpath?(path: string): string;
5131         fileExists?(path: string): boolean;
5132         getTypeRootsVersion?(): number;
5133         resolveModuleNames?(moduleNames: string[], containingFile: string, reusedNames: string[] | undefined, redirectedReference: ResolvedProjectReference | undefined, options: CompilerOptions): (ResolvedModule | undefined)[];
5134         getResolvedModuleWithFailedLookupLocationsFromCache?(modulename: string, containingFile: string): ResolvedModuleWithFailedLookupLocations | undefined;
5135         resolveTypeReferenceDirectives?(typeDirectiveNames: string[], containingFile: string, redirectedReference: ResolvedProjectReference | undefined, options: CompilerOptions): (ResolvedTypeReferenceDirective | undefined)[];
5136         getDirectories?(directoryName: string): string[];
5137         /**
5138          * Gets a set of custom transformers to use during emit.
5139          */
5140         getCustomTransformers?(): CustomTransformers | undefined;
5141         isKnownTypesPackageName?(name: string): boolean;
5142         installPackage?(options: InstallPackageOptions): Promise<ApplyCodeActionCommandResult>;
5143         writeFile?(fileName: string, content: string): void;
5144     }
5145     type WithMetadata<T> = T & {
5146         metadata?: unknown;
5147     };
5148     interface LanguageService {
5149         /** This is used as a part of restarting the language service. */
5150         cleanupSemanticCache(): void;
5151         /**
5152          * Gets errors indicating invalid syntax in a file.
5153          *
5154          * In English, "this cdeo have, erorrs" is syntactically invalid because it has typos,
5155          * grammatical errors, and misplaced punctuation. Likewise, examples of syntax
5156          * errors in TypeScript are missing parentheses in an `if` statement, mismatched
5157          * curly braces, and using a reserved keyword as a variable name.
5158          *
5159          * These diagnostics are inexpensive to compute and don't require knowledge of
5160          * other files. Note that a non-empty result increases the likelihood of false positives
5161          * from `getSemanticDiagnostics`.
5162          *
5163          * While these represent the majority of syntax-related diagnostics, there are some
5164          * that require the type system, which will be present in `getSemanticDiagnostics`.
5165          *
5166          * @param fileName A path to the file you want syntactic diagnostics for
5167          */
5168         getSyntacticDiagnostics(fileName: string): DiagnosticWithLocation[];
5169         /**
5170          * Gets warnings or errors indicating type system issues in a given file.
5171          * Requesting semantic diagnostics may start up the type system and
5172          * run deferred work, so the first call may take longer than subsequent calls.
5173          *
5174          * Unlike the other get*Diagnostics functions, these diagnostics can potentially not
5175          * include a reference to a source file. Specifically, the first time this is called,
5176          * it will return global diagnostics with no associated location.
5177          *
5178          * To contrast the differences between semantic and syntactic diagnostics, consider the
5179          * sentence: "The sun is green." is syntactically correct; those are real English words with
5180          * correct sentence structure. However, it is semantically invalid, because it is not true.
5181          *
5182          * @param fileName A path to the file you want semantic diagnostics for
5183          */
5184         getSemanticDiagnostics(fileName: string): Diagnostic[];
5185         /**
5186          * Gets suggestion diagnostics for a specific file. These diagnostics tend to
5187          * proactively suggest refactors, as opposed to diagnostics that indicate
5188          * potentially incorrect runtime behavior.
5189          *
5190          * @param fileName A path to the file you want semantic diagnostics for
5191          */
5192         getSuggestionDiagnostics(fileName: string): DiagnosticWithLocation[];
5193         /**
5194          * Gets global diagnostics related to the program configuration and compiler options.
5195          */
5196         getCompilerOptionsDiagnostics(): Diagnostic[];
5197         /** @deprecated Use getEncodedSyntacticClassifications instead. */
5198         getSyntacticClassifications(fileName: string, span: TextSpan): ClassifiedSpan[];
5199         /** @deprecated Use getEncodedSemanticClassifications instead. */
5200         getSemanticClassifications(fileName: string, span: TextSpan): ClassifiedSpan[];
5201         getEncodedSyntacticClassifications(fileName: string, span: TextSpan): Classifications;
5202         getEncodedSemanticClassifications(fileName: string, span: TextSpan): Classifications;
5203         /**
5204          * Gets completion entries at a particular position in a file.
5205          *
5206          * @param fileName The path to the file
5207          * @param position A zero-based index of the character where you want the entries
5208          * @param options An object describing how the request was triggered and what kinds
5209          * of code actions can be returned with the completions.
5210          */
5211         getCompletionsAtPosition(fileName: string, position: number, options: GetCompletionsAtPositionOptions | undefined): WithMetadata<CompletionInfo> | undefined;
5212         /**
5213          * Gets the extended details for a completion entry retrieved from `getCompletionsAtPosition`.
5214          *
5215          * @param fileName The path to the file
5216          * @param position A zero based index of the character where you want the entries
5217          * @param entryName The name from an existing completion which came from `getCompletionsAtPosition`
5218          * @param formatOptions How should code samples in the completions be formatted, can be undefined for backwards compatibility
5219          * @param source Source code for the current file, can be undefined for backwards compatibility
5220          * @param preferences User settings, can be undefined for backwards compatibility
5221          */
5222         getCompletionEntryDetails(fileName: string, position: number, entryName: string, formatOptions: FormatCodeOptions | FormatCodeSettings | undefined, source: string | undefined, preferences: UserPreferences | undefined): CompletionEntryDetails | undefined;
5223         getCompletionEntrySymbol(fileName: string, position: number, name: string, source: string | undefined): Symbol | undefined;
5224         /**
5225          * Gets semantic information about the identifier at a particular position in a
5226          * file. Quick info is what you typically see when you hover in an editor.
5227          *
5228          * @param fileName The path to the file
5229          * @param position A zero-based index of the character where you want the quick info
5230          */
5231         getQuickInfoAtPosition(fileName: string, position: number): QuickInfo | undefined;
5232         getNameOrDottedNameSpan(fileName: string, startPos: number, endPos: number): TextSpan | undefined;
5233         getBreakpointStatementAtPosition(fileName: string, position: number): TextSpan | undefined;
5234         getSignatureHelpItems(fileName: string, position: number, options: SignatureHelpItemsOptions | undefined): SignatureHelpItems | undefined;
5235         getRenameInfo(fileName: string, position: number, options?: RenameInfoOptions): RenameInfo;
5236         findRenameLocations(fileName: string, position: number, findInStrings: boolean, findInComments: boolean, providePrefixAndSuffixTextForRename?: boolean): readonly RenameLocation[] | undefined;
5237         getSmartSelectionRange(fileName: string, position: number): SelectionRange;
5238         getDefinitionAtPosition(fileName: string, position: number): readonly DefinitionInfo[] | undefined;
5239         getDefinitionAndBoundSpan(fileName: string, position: number): DefinitionInfoAndBoundSpan | undefined;
5240         getTypeDefinitionAtPosition(fileName: string, position: number): readonly DefinitionInfo[] | undefined;
5241         getImplementationAtPosition(fileName: string, position: number): readonly ImplementationLocation[] | undefined;
5242         getReferencesAtPosition(fileName: string, position: number): ReferenceEntry[] | undefined;
5243         findReferences(fileName: string, position: number): ReferencedSymbol[] | undefined;
5244         getDocumentHighlights(fileName: string, position: number, filesToSearch: string[]): DocumentHighlights[] | undefined;
5245         /** @deprecated */
5246         getOccurrencesAtPosition(fileName: string, position: number): readonly ReferenceEntry[] | undefined;
5247         getNavigateToItems(searchValue: string, maxResultCount?: number, fileName?: string, excludeDtsFiles?: boolean): NavigateToItem[];
5248         getNavigationBarItems(fileName: string): NavigationBarItem[];
5249         getNavigationTree(fileName: string): NavigationTree;
5250         prepareCallHierarchy(fileName: string, position: number): CallHierarchyItem | CallHierarchyItem[] | undefined;
5251         provideCallHierarchyIncomingCalls(fileName: string, position: number): CallHierarchyIncomingCall[];
5252         provideCallHierarchyOutgoingCalls(fileName: string, position: number): CallHierarchyOutgoingCall[];
5253         getOutliningSpans(fileName: string): OutliningSpan[];
5254         getTodoComments(fileName: string, descriptors: TodoCommentDescriptor[]): TodoComment[];
5255         getBraceMatchingAtPosition(fileName: string, position: number): TextSpan[];
5256         getIndentationAtPosition(fileName: string, position: number, options: EditorOptions | EditorSettings): number;
5257         getFormattingEditsForRange(fileName: string, start: number, end: number, options: FormatCodeOptions | FormatCodeSettings): TextChange[];
5258         getFormattingEditsForDocument(fileName: string, options: FormatCodeOptions | FormatCodeSettings): TextChange[];
5259         getFormattingEditsAfterKeystroke(fileName: string, position: number, key: string, options: FormatCodeOptions | FormatCodeSettings): TextChange[];
5260         getDocCommentTemplateAtPosition(fileName: string, position: number): TextInsertion | undefined;
5261         isValidBraceCompletionAtPosition(fileName: string, position: number, openingBrace: number): boolean;
5262         /**
5263          * This will return a defined result if the position is after the `>` of the opening tag, or somewhere in the text, of a JSXElement with no closing tag.
5264          * Editors should call this after `>` is typed.
5265          */
5266         getJsxClosingTagAtPosition(fileName: string, position: number): JsxClosingTagInfo | undefined;
5267         getSpanOfEnclosingComment(fileName: string, position: number, onlyMultiLine: boolean): TextSpan | undefined;
5268         toLineColumnOffset?(fileName: string, position: number): LineAndCharacter;
5269         getCodeFixesAtPosition(fileName: string, start: number, end: number, errorCodes: readonly number[], formatOptions: FormatCodeSettings, preferences: UserPreferences): readonly CodeFixAction[];
5270         getCombinedCodeFix(scope: CombinedCodeFixScope, fixId: {}, formatOptions: FormatCodeSettings, preferences: UserPreferences): CombinedCodeActions;
5271         applyCodeActionCommand(action: CodeActionCommand, formatSettings?: FormatCodeSettings): Promise<ApplyCodeActionCommandResult>;
5272         applyCodeActionCommand(action: CodeActionCommand[], formatSettings?: FormatCodeSettings): Promise<ApplyCodeActionCommandResult[]>;
5273         applyCodeActionCommand(action: CodeActionCommand | CodeActionCommand[], formatSettings?: FormatCodeSettings): Promise<ApplyCodeActionCommandResult | ApplyCodeActionCommandResult[]>;
5274         /** @deprecated `fileName` will be ignored */
5275         applyCodeActionCommand(fileName: string, action: CodeActionCommand): Promise<ApplyCodeActionCommandResult>;
5276         /** @deprecated `fileName` will be ignored */
5277         applyCodeActionCommand(fileName: string, action: CodeActionCommand[]): Promise<ApplyCodeActionCommandResult[]>;
5278         /** @deprecated `fileName` will be ignored */
5279         applyCodeActionCommand(fileName: string, action: CodeActionCommand | CodeActionCommand[]): Promise<ApplyCodeActionCommandResult | ApplyCodeActionCommandResult[]>;
5280         getApplicableRefactors(fileName: string, positionOrRange: number | TextRange, preferences: UserPreferences | undefined): ApplicableRefactorInfo[];
5281         getEditsForRefactor(fileName: string, formatOptions: FormatCodeSettings, positionOrRange: number | TextRange, refactorName: string, actionName: string, preferences: UserPreferences | undefined): RefactorEditInfo | undefined;
5282         organizeImports(scope: OrganizeImportsScope, formatOptions: FormatCodeSettings, preferences: UserPreferences | undefined): readonly FileTextChanges[];
5283         getEditsForFileRename(oldFilePath: string, newFilePath: string, formatOptions: FormatCodeSettings, preferences: UserPreferences | undefined): readonly FileTextChanges[];
5284         getEmitOutput(fileName: string, emitOnlyDtsFiles?: boolean, forceDtsEmit?: boolean): EmitOutput;
5285         getProgram(): Program | undefined;
5286         dispose(): void;
5287     }
5288     interface JsxClosingTagInfo {
5289         readonly newText: string;
5290     }
5291     interface CombinedCodeFixScope {
5292         type: "file";
5293         fileName: string;
5294     }
5295     type OrganizeImportsScope = CombinedCodeFixScope;
5296     type CompletionsTriggerCharacter = "." | '"' | "'" | "`" | "/" | "@" | "<" | "#";
5297     interface GetCompletionsAtPositionOptions extends UserPreferences {
5298         /**
5299          * If the editor is asking for completions because a certain character was typed
5300          * (as opposed to when the user explicitly requested them) this should be set.
5301          */
5302         triggerCharacter?: CompletionsTriggerCharacter;
5303         /** @deprecated Use includeCompletionsForModuleExports */
5304         includeExternalModuleExports?: boolean;
5305         /** @deprecated Use includeCompletionsWithInsertText */
5306         includeInsertTextCompletions?: boolean;
5307     }
5308     type SignatureHelpTriggerCharacter = "," | "(" | "<";
5309     type SignatureHelpRetriggerCharacter = SignatureHelpTriggerCharacter | ")";
5310     interface SignatureHelpItemsOptions {
5311         triggerReason?: SignatureHelpTriggerReason;
5312     }
5313     type SignatureHelpTriggerReason = SignatureHelpInvokedReason | SignatureHelpCharacterTypedReason | SignatureHelpRetriggeredReason;
5314     /**
5315      * Signals that the user manually requested signature help.
5316      * The language service will unconditionally attempt to provide a result.
5317      */
5318     interface SignatureHelpInvokedReason {
5319         kind: "invoked";
5320         triggerCharacter?: undefined;
5321     }
5322     /**
5323      * Signals that the signature help request came from a user typing a character.
5324      * Depending on the character and the syntactic context, the request may or may not be served a result.
5325      */
5326     interface SignatureHelpCharacterTypedReason {
5327         kind: "characterTyped";
5328         /**
5329          * Character that was responsible for triggering signature help.
5330          */
5331         triggerCharacter: SignatureHelpTriggerCharacter;
5332     }
5333     /**
5334      * Signals that this signature help request came from typing a character or moving the cursor.
5335      * This should only occur if a signature help session was already active and the editor needs to see if it should adjust.
5336      * The language service will unconditionally attempt to provide a result.
5337      * `triggerCharacter` can be `undefined` for a retrigger caused by a cursor move.
5338      */
5339     interface SignatureHelpRetriggeredReason {
5340         kind: "retrigger";
5341         /**
5342          * Character that was responsible for triggering signature help.
5343          */
5344         triggerCharacter?: SignatureHelpRetriggerCharacter;
5345     }
5346     interface ApplyCodeActionCommandResult {
5347         successMessage: string;
5348     }
5349     interface Classifications {
5350         spans: number[];
5351         endOfLineState: EndOfLineState;
5352     }
5353     interface ClassifiedSpan {
5354         textSpan: TextSpan;
5355         classificationType: ClassificationTypeNames;
5356     }
5357     /**
5358      * Navigation bar interface designed for visual studio's dual-column layout.
5359      * This does not form a proper tree.
5360      * The navbar is returned as a list of top-level items, each of which has a list of child items.
5361      * Child items always have an empty array for their `childItems`.
5362      */
5363     interface NavigationBarItem {
5364         text: string;
5365         kind: ScriptElementKind;
5366         kindModifiers: string;
5367         spans: TextSpan[];
5368         childItems: NavigationBarItem[];
5369         indent: number;
5370         bolded: boolean;
5371         grayed: boolean;
5372     }
5373     /**
5374      * Node in a tree of nested declarations in a file.
5375      * The top node is always a script or module node.
5376      */
5377     interface NavigationTree {
5378         /** Name of the declaration, or a short description, e.g. "<class>". */
5379         text: string;
5380         kind: ScriptElementKind;
5381         /** ScriptElementKindModifier separated by commas, e.g. "public,abstract" */
5382         kindModifiers: string;
5383         /**
5384          * Spans of the nodes that generated this declaration.
5385          * There will be more than one if this is the result of merging.
5386          */
5387         spans: TextSpan[];
5388         nameSpan: TextSpan | undefined;
5389         /** Present if non-empty */
5390         childItems?: NavigationTree[];
5391     }
5392     interface CallHierarchyItem {
5393         name: string;
5394         kind: ScriptElementKind;
5395         file: string;
5396         span: TextSpan;
5397         selectionSpan: TextSpan;
5398     }
5399     interface CallHierarchyIncomingCall {
5400         from: CallHierarchyItem;
5401         fromSpans: TextSpan[];
5402     }
5403     interface CallHierarchyOutgoingCall {
5404         to: CallHierarchyItem;
5405         fromSpans: TextSpan[];
5406     }
5407     interface TodoCommentDescriptor {
5408         text: string;
5409         priority: number;
5410     }
5411     interface TodoComment {
5412         descriptor: TodoCommentDescriptor;
5413         message: string;
5414         position: number;
5415     }
5416     interface TextChange {
5417         span: TextSpan;
5418         newText: string;
5419     }
5420     interface FileTextChanges {
5421         fileName: string;
5422         textChanges: readonly TextChange[];
5423         isNewFile?: boolean;
5424     }
5425     interface CodeAction {
5426         /** Description of the code action to display in the UI of the editor */
5427         description: string;
5428         /** Text changes to apply to each file as part of the code action */
5429         changes: FileTextChanges[];
5430         /**
5431          * If the user accepts the code fix, the editor should send the action back in a `applyAction` request.
5432          * This allows the language service to have side effects (e.g. installing dependencies) upon a code fix.
5433          */
5434         commands?: CodeActionCommand[];
5435     }
5436     interface CodeFixAction extends CodeAction {
5437         /** Short name to identify the fix, for use by telemetry. */
5438         fixName: string;
5439         /**
5440          * If present, one may call 'getCombinedCodeFix' with this fixId.
5441          * This may be omitted to indicate that the code fix can't be applied in a group.
5442          */
5443         fixId?: {};
5444         fixAllDescription?: string;
5445     }
5446     interface CombinedCodeActions {
5447         changes: readonly FileTextChanges[];
5448         commands?: readonly CodeActionCommand[];
5449     }
5450     type CodeActionCommand = InstallPackageAction;
5451     interface InstallPackageAction {
5452     }
5453     /**
5454      * A set of one or more available refactoring actions, grouped under a parent refactoring.
5455      */
5456     interface ApplicableRefactorInfo {
5457         /**
5458          * The programmatic name of the refactoring
5459          */
5460         name: string;
5461         /**
5462          * A description of this refactoring category to show to the user.
5463          * If the refactoring gets inlined (see below), this text will not be visible.
5464          */
5465         description: string;
5466         /**
5467          * Inlineable refactorings can have their actions hoisted out to the top level
5468          * of a context menu. Non-inlineanable refactorings should always be shown inside
5469          * their parent grouping.
5470          *
5471          * If not specified, this value is assumed to be 'true'
5472          */
5473         inlineable?: boolean;
5474         actions: RefactorActionInfo[];
5475     }
5476     /**
5477      * Represents a single refactoring action - for example, the "Extract Method..." refactor might
5478      * offer several actions, each corresponding to a surround class or closure to extract into.
5479      */
5480     interface RefactorActionInfo {
5481         /**
5482          * The programmatic name of the refactoring action
5483          */
5484         name: string;
5485         /**
5486          * A description of this refactoring action to show to the user.
5487          * If the parent refactoring is inlined away, this will be the only text shown,
5488          * so this description should make sense by itself if the parent is inlineable=true
5489          */
5490         description: string;
5491     }
5492     /**
5493      * A set of edits to make in response to a refactor action, plus an optional
5494      * location where renaming should be invoked from
5495      */
5496     interface RefactorEditInfo {
5497         edits: FileTextChanges[];
5498         renameFilename?: string;
5499         renameLocation?: number;
5500         commands?: CodeActionCommand[];
5501     }
5502     interface TextInsertion {
5503         newText: string;
5504         /** The position in newText the caret should point to after the insertion. */
5505         caretOffset: number;
5506     }
5507     interface DocumentSpan {
5508         textSpan: TextSpan;
5509         fileName: string;
5510         /**
5511          * If the span represents a location that was remapped (e.g. via a .d.ts.map file),
5512          * then the original filename and span will be specified here
5513          */
5514         originalTextSpan?: TextSpan;
5515         originalFileName?: string;
5516         /**
5517          * If DocumentSpan.textSpan is the span for name of the declaration,
5518          * then this is the span for relevant declaration
5519          */
5520         contextSpan?: TextSpan;
5521         originalContextSpan?: TextSpan;
5522     }
5523     interface RenameLocation extends DocumentSpan {
5524         readonly prefixText?: string;
5525         readonly suffixText?: string;
5526     }
5527     interface ReferenceEntry extends DocumentSpan {
5528         isWriteAccess: boolean;
5529         isDefinition: boolean;
5530         isInString?: true;
5531     }
5532     interface ImplementationLocation extends DocumentSpan {
5533         kind: ScriptElementKind;
5534         displayParts: SymbolDisplayPart[];
5535     }
5536     enum HighlightSpanKind {
5537         none = "none",
5538         definition = "definition",
5539         reference = "reference",
5540         writtenReference = "writtenReference"
5541     }
5542     interface HighlightSpan {
5543         fileName?: string;
5544         isInString?: true;
5545         textSpan: TextSpan;
5546         contextSpan?: TextSpan;
5547         kind: HighlightSpanKind;
5548     }
5549     interface NavigateToItem {
5550         name: string;
5551         kind: ScriptElementKind;
5552         kindModifiers: string;
5553         matchKind: "exact" | "prefix" | "substring" | "camelCase";
5554         isCaseSensitive: boolean;
5555         fileName: string;
5556         textSpan: TextSpan;
5557         containerName: string;
5558         containerKind: ScriptElementKind;
5559     }
5560     enum IndentStyle {
5561         None = 0,
5562         Block = 1,
5563         Smart = 2
5564     }
5565     enum SemicolonPreference {
5566         Ignore = "ignore",
5567         Insert = "insert",
5568         Remove = "remove"
5569     }
5570     interface EditorOptions {
5571         BaseIndentSize?: number;
5572         IndentSize: number;
5573         TabSize: number;
5574         NewLineCharacter: string;
5575         ConvertTabsToSpaces: boolean;
5576         IndentStyle: IndentStyle;
5577     }
5578     interface EditorSettings {
5579         baseIndentSize?: number;
5580         indentSize?: number;
5581         tabSize?: number;
5582         newLineCharacter?: string;
5583         convertTabsToSpaces?: boolean;
5584         indentStyle?: IndentStyle;
5585         trimTrailingWhitespace?: boolean;
5586     }
5587     interface FormatCodeOptions extends EditorOptions {
5588         InsertSpaceAfterCommaDelimiter: boolean;
5589         InsertSpaceAfterSemicolonInForStatements: boolean;
5590         InsertSpaceBeforeAndAfterBinaryOperators: boolean;
5591         InsertSpaceAfterConstructor?: boolean;
5592         InsertSpaceAfterKeywordsInControlFlowStatements: boolean;
5593         InsertSpaceAfterFunctionKeywordForAnonymousFunctions: boolean;
5594         InsertSpaceAfterOpeningAndBeforeClosingNonemptyParenthesis: boolean;
5595         InsertSpaceAfterOpeningAndBeforeClosingNonemptyBrackets: boolean;
5596         InsertSpaceAfterOpeningAndBeforeClosingNonemptyBraces?: boolean;
5597         InsertSpaceAfterOpeningAndBeforeClosingTemplateStringBraces: boolean;
5598         InsertSpaceAfterOpeningAndBeforeClosingJsxExpressionBraces?: boolean;
5599         InsertSpaceAfterTypeAssertion?: boolean;
5600         InsertSpaceBeforeFunctionParenthesis?: boolean;
5601         PlaceOpenBraceOnNewLineForFunctions: boolean;
5602         PlaceOpenBraceOnNewLineForControlBlocks: boolean;
5603         insertSpaceBeforeTypeAnnotation?: boolean;
5604     }
5605     interface FormatCodeSettings extends EditorSettings {
5606         readonly insertSpaceAfterCommaDelimiter?: boolean;
5607         readonly insertSpaceAfterSemicolonInForStatements?: boolean;
5608         readonly insertSpaceBeforeAndAfterBinaryOperators?: boolean;
5609         readonly insertSpaceAfterConstructor?: boolean;
5610         readonly insertSpaceAfterKeywordsInControlFlowStatements?: boolean;
5611         readonly insertSpaceAfterFunctionKeywordForAnonymousFunctions?: boolean;
5612         readonly insertSpaceAfterOpeningAndBeforeClosingNonemptyParenthesis?: boolean;
5613         readonly insertSpaceAfterOpeningAndBeforeClosingNonemptyBrackets?: boolean;
5614         readonly insertSpaceAfterOpeningAndBeforeClosingNonemptyBraces?: boolean;
5615         readonly insertSpaceAfterOpeningAndBeforeClosingEmptyBraces?: boolean;
5616         readonly insertSpaceAfterOpeningAndBeforeClosingTemplateStringBraces?: boolean;
5617         readonly insertSpaceAfterOpeningAndBeforeClosingJsxExpressionBraces?: boolean;
5618         readonly insertSpaceAfterTypeAssertion?: boolean;
5619         readonly insertSpaceBeforeFunctionParenthesis?: boolean;
5620         readonly placeOpenBraceOnNewLineForFunctions?: boolean;
5621         readonly placeOpenBraceOnNewLineForControlBlocks?: boolean;
5622         readonly insertSpaceBeforeTypeAnnotation?: boolean;
5623         readonly indentMultiLineObjectLiteralBeginningOnBlankLine?: boolean;
5624         readonly semicolons?: SemicolonPreference;
5625     }
5626     function getDefaultFormatCodeSettings(newLineCharacter?: string): FormatCodeSettings;
5627     interface DefinitionInfo extends DocumentSpan {
5628         kind: ScriptElementKind;
5629         name: string;
5630         containerKind: ScriptElementKind;
5631         containerName: string;
5632     }
5633     interface DefinitionInfoAndBoundSpan {
5634         definitions?: readonly DefinitionInfo[];
5635         textSpan: TextSpan;
5636     }
5637     interface ReferencedSymbolDefinitionInfo extends DefinitionInfo {
5638         displayParts: SymbolDisplayPart[];
5639     }
5640     interface ReferencedSymbol {
5641         definition: ReferencedSymbolDefinitionInfo;
5642         references: ReferenceEntry[];
5643     }
5644     enum SymbolDisplayPartKind {
5645         aliasName = 0,
5646         className = 1,
5647         enumName = 2,
5648         fieldName = 3,
5649         interfaceName = 4,
5650         keyword = 5,
5651         lineBreak = 6,
5652         numericLiteral = 7,
5653         stringLiteral = 8,
5654         localName = 9,
5655         methodName = 10,
5656         moduleName = 11,
5657         operator = 12,
5658         parameterName = 13,
5659         propertyName = 14,
5660         punctuation = 15,
5661         space = 16,
5662         text = 17,
5663         typeParameterName = 18,
5664         enumMemberName = 19,
5665         functionName = 20,
5666         regularExpressionLiteral = 21
5667     }
5668     interface SymbolDisplayPart {
5669         text: string;
5670         kind: string;
5671     }
5672     interface JSDocTagInfo {
5673         name: string;
5674         text?: string;
5675     }
5676     interface QuickInfo {
5677         kind: ScriptElementKind;
5678         kindModifiers: string;
5679         textSpan: TextSpan;
5680         displayParts?: SymbolDisplayPart[];
5681         documentation?: SymbolDisplayPart[];
5682         tags?: JSDocTagInfo[];
5683     }
5684     type RenameInfo = RenameInfoSuccess | RenameInfoFailure;
5685     interface RenameInfoSuccess {
5686         canRename: true;
5687         /**
5688          * File or directory to rename.
5689          * If set, `getEditsForFileRename` should be called instead of `findRenameLocations`.
5690          */
5691         fileToRename?: string;
5692         displayName: string;
5693         fullDisplayName: string;
5694         kind: ScriptElementKind;
5695         kindModifiers: string;
5696         triggerSpan: TextSpan;
5697     }
5698     interface RenameInfoFailure {
5699         canRename: false;
5700         localizedErrorMessage: string;
5701     }
5702     interface RenameInfoOptions {
5703         readonly allowRenameOfImportPath?: boolean;
5704     }
5705     interface SignatureHelpParameter {
5706         name: string;
5707         documentation: SymbolDisplayPart[];
5708         displayParts: SymbolDisplayPart[];
5709         isOptional: boolean;
5710     }
5711     interface SelectionRange {
5712         textSpan: TextSpan;
5713         parent?: SelectionRange;
5714     }
5715     /**
5716      * Represents a single signature to show in signature help.
5717      * The id is used for subsequent calls into the language service to ask questions about the
5718      * signature help item in the context of any documents that have been updated.  i.e. after
5719      * an edit has happened, while signature help is still active, the host can ask important
5720      * questions like 'what parameter is the user currently contained within?'.
5721      */
5722     interface SignatureHelpItem {
5723         isVariadic: boolean;
5724         prefixDisplayParts: SymbolDisplayPart[];
5725         suffixDisplayParts: SymbolDisplayPart[];
5726         separatorDisplayParts: SymbolDisplayPart[];
5727         parameters: SignatureHelpParameter[];
5728         documentation: SymbolDisplayPart[];
5729         tags: JSDocTagInfo[];
5730     }
5731     /**
5732      * Represents a set of signature help items, and the preferred item that should be selected.
5733      */
5734     interface SignatureHelpItems {
5735         items: SignatureHelpItem[];
5736         applicableSpan: TextSpan;
5737         selectedItemIndex: number;
5738         argumentIndex: number;
5739         argumentCount: number;
5740     }
5741     interface CompletionInfo {
5742         /** Not true for all global completions. This will be true if the enclosing scope matches a few syntax kinds. See `isSnippetScope`. */
5743         isGlobalCompletion: boolean;
5744         isMemberCompletion: boolean;
5745         /**
5746          * true when the current location also allows for a new identifier
5747          */
5748         isNewIdentifierLocation: boolean;
5749         entries: CompletionEntry[];
5750     }
5751     interface CompletionEntry {
5752         name: string;
5753         kind: ScriptElementKind;
5754         kindModifiers?: string;
5755         sortText: string;
5756         insertText?: string;
5757         /**
5758          * An optional span that indicates the text to be replaced by this completion item.
5759          * If present, this span should be used instead of the default one.
5760          * It will be set if the required span differs from the one generated by the default replacement behavior.
5761          */
5762         replacementSpan?: TextSpan;
5763         hasAction?: true;
5764         source?: string;
5765         isRecommended?: true;
5766         isFromUncheckedFile?: true;
5767     }
5768     interface CompletionEntryDetails {
5769         name: string;
5770         kind: ScriptElementKind;
5771         kindModifiers: string;
5772         displayParts: SymbolDisplayPart[];
5773         documentation?: SymbolDisplayPart[];
5774         tags?: JSDocTagInfo[];
5775         codeActions?: CodeAction[];
5776         source?: SymbolDisplayPart[];
5777     }
5778     interface OutliningSpan {
5779         /** The span of the document to actually collapse. */
5780         textSpan: TextSpan;
5781         /** The span of the document to display when the user hovers over the collapsed span. */
5782         hintSpan: TextSpan;
5783         /** The text to display in the editor for the collapsed region. */
5784         bannerText: string;
5785         /**
5786          * Whether or not this region should be automatically collapsed when
5787          * the 'Collapse to Definitions' command is invoked.
5788          */
5789         autoCollapse: boolean;
5790         /**
5791          * Classification of the contents of the span
5792          */
5793         kind: OutliningSpanKind;
5794     }
5795     enum OutliningSpanKind {
5796         /** Single or multi-line comments */
5797         Comment = "comment",
5798         /** Sections marked by '// #region' and '// #endregion' comments */
5799         Region = "region",
5800         /** Declarations and expressions */
5801         Code = "code",
5802         /** Contiguous blocks of import declarations */
5803         Imports = "imports"
5804     }
5805     enum OutputFileType {
5806         JavaScript = 0,
5807         SourceMap = 1,
5808         Declaration = 2
5809     }
5810     enum EndOfLineState {
5811         None = 0,
5812         InMultiLineCommentTrivia = 1,
5813         InSingleQuoteStringLiteral = 2,
5814         InDoubleQuoteStringLiteral = 3,
5815         InTemplateHeadOrNoSubstitutionTemplate = 4,
5816         InTemplateMiddleOrTail = 5,
5817         InTemplateSubstitutionPosition = 6
5818     }
5819     enum TokenClass {
5820         Punctuation = 0,
5821         Keyword = 1,
5822         Operator = 2,
5823         Comment = 3,
5824         Whitespace = 4,
5825         Identifier = 5,
5826         NumberLiteral = 6,
5827         BigIntLiteral = 7,
5828         StringLiteral = 8,
5829         RegExpLiteral = 9
5830     }
5831     interface ClassificationResult {
5832         finalLexState: EndOfLineState;
5833         entries: ClassificationInfo[];
5834     }
5835     interface ClassificationInfo {
5836         length: number;
5837         classification: TokenClass;
5838     }
5839     interface Classifier {
5840         /**
5841          * Gives lexical classifications of tokens on a line without any syntactic context.
5842          * For instance, a token consisting of the text 'string' can be either an identifier
5843          * named 'string' or the keyword 'string', however, because this classifier is not aware,
5844          * it relies on certain heuristics to give acceptable results. For classifications where
5845          * speed trumps accuracy, this function is preferable; however, for true accuracy, the
5846          * syntactic classifier is ideal. In fact, in certain editing scenarios, combining the
5847          * lexical, syntactic, and semantic classifiers may issue the best user experience.
5848          *
5849          * @param text                      The text of a line to classify.
5850          * @param lexState                  The state of the lexical classifier at the end of the previous line.
5851          * @param syntacticClassifierAbsent Whether the client is *not* using a syntactic classifier.
5852          *                                  If there is no syntactic classifier (syntacticClassifierAbsent=true),
5853          *                                  certain heuristics may be used in its place; however, if there is a
5854          *                                  syntactic classifier (syntacticClassifierAbsent=false), certain
5855          *                                  classifications which may be incorrectly categorized will be given
5856          *                                  back as Identifiers in order to allow the syntactic classifier to
5857          *                                  subsume the classification.
5858          * @deprecated Use getLexicalClassifications instead.
5859          */
5860         getClassificationsForLine(text: string, lexState: EndOfLineState, syntacticClassifierAbsent: boolean): ClassificationResult;
5861         getEncodedLexicalClassifications(text: string, endOfLineState: EndOfLineState, syntacticClassifierAbsent: boolean): Classifications;
5862     }
5863     enum ScriptElementKind {
5864         unknown = "",
5865         warning = "warning",
5866         /** predefined type (void) or keyword (class) */
5867         keyword = "keyword",
5868         /** top level script node */
5869         scriptElement = "script",
5870         /** module foo {} */
5871         moduleElement = "module",
5872         /** class X {} */
5873         classElement = "class",
5874         /** var x = class X {} */
5875         localClassElement = "local class",
5876         /** interface Y {} */
5877         interfaceElement = "interface",
5878         /** type T = ... */
5879         typeElement = "type",
5880         /** enum E */
5881         enumElement = "enum",
5882         enumMemberElement = "enum member",
5883         /**
5884          * Inside module and script only
5885          * const v = ..
5886          */
5887         variableElement = "var",
5888         /** Inside function */
5889         localVariableElement = "local var",
5890         /**
5891          * Inside module and script only
5892          * function f() { }
5893          */
5894         functionElement = "function",
5895         /** Inside function */
5896         localFunctionElement = "local function",
5897         /** class X { [public|private]* foo() {} } */
5898         memberFunctionElement = "method",
5899         /** class X { [public|private]* [get|set] foo:number; } */
5900         memberGetAccessorElement = "getter",
5901         memberSetAccessorElement = "setter",
5902         /**
5903          * class X { [public|private]* foo:number; }
5904          * interface Y { foo:number; }
5905          */
5906         memberVariableElement = "property",
5907         /** class X { constructor() { } } */
5908         constructorImplementationElement = "constructor",
5909         /** interface Y { ():number; } */
5910         callSignatureElement = "call",
5911         /** interface Y { []:number; } */
5912         indexSignatureElement = "index",
5913         /** interface Y { new():Y; } */
5914         constructSignatureElement = "construct",
5915         /** function foo(*Y*: string) */
5916         parameterElement = "parameter",
5917         typeParameterElement = "type parameter",
5918         primitiveType = "primitive type",
5919         label = "label",
5920         alias = "alias",
5921         constElement = "const",
5922         letElement = "let",
5923         directory = "directory",
5924         externalModuleName = "external module name",
5925         /**
5926          * <JsxTagName attribute1 attribute2={0} />
5927          */
5928         jsxAttribute = "JSX attribute",
5929         /** String literal */
5930         string = "string"
5931     }
5932     enum ScriptElementKindModifier {
5933         none = "",
5934         publicMemberModifier = "public",
5935         privateMemberModifier = "private",
5936         protectedMemberModifier = "protected",
5937         exportedModifier = "export",
5938         ambientModifier = "declare",
5939         staticModifier = "static",
5940         abstractModifier = "abstract",
5941         optionalModifier = "optional",
5942         dtsModifier = ".d.ts",
5943         tsModifier = ".ts",
5944         tsxModifier = ".tsx",
5945         jsModifier = ".js",
5946         jsxModifier = ".jsx",
5947         jsonModifier = ".json"
5948     }
5949     enum ClassificationTypeNames {
5950         comment = "comment",
5951         identifier = "identifier",
5952         keyword = "keyword",
5953         numericLiteral = "number",
5954         bigintLiteral = "bigint",
5955         operator = "operator",
5956         stringLiteral = "string",
5957         whiteSpace = "whitespace",
5958         text = "text",
5959         punctuation = "punctuation",
5960         className = "class name",
5961         enumName = "enum name",
5962         interfaceName = "interface name",
5963         moduleName = "module name",
5964         typeParameterName = "type parameter name",
5965         typeAliasName = "type alias name",
5966         parameterName = "parameter name",
5967         docCommentTagName = "doc comment tag name",
5968         jsxOpenTagName = "jsx open tag name",
5969         jsxCloseTagName = "jsx close tag name",
5970         jsxSelfClosingTagName = "jsx self closing tag name",
5971         jsxAttribute = "jsx attribute",
5972         jsxText = "jsx text",
5973         jsxAttributeStringLiteralValue = "jsx attribute string literal value"
5974     }
5975     enum ClassificationType {
5976         comment = 1,
5977         identifier = 2,
5978         keyword = 3,
5979         numericLiteral = 4,
5980         operator = 5,
5981         stringLiteral = 6,
5982         regularExpressionLiteral = 7,
5983         whiteSpace = 8,
5984         text = 9,
5985         punctuation = 10,
5986         className = 11,
5987         enumName = 12,
5988         interfaceName = 13,
5989         moduleName = 14,
5990         typeParameterName = 15,
5991         typeAliasName = 16,
5992         parameterName = 17,
5993         docCommentTagName = 18,
5994         jsxOpenTagName = 19,
5995         jsxCloseTagName = 20,
5996         jsxSelfClosingTagName = 21,
5997         jsxAttribute = 22,
5998         jsxText = 23,
5999         jsxAttributeStringLiteralValue = 24,
6000         bigintLiteral = 25
6001     }
6002 }
6003 declare namespace ts {
6004     /** The classifier is used for syntactic highlighting in editors via the TSServer */
6005     function createClassifier(): Classifier;
6006 }
6007 declare namespace ts {
6008     interface DocumentHighlights {
6009         fileName: string;
6010         highlightSpans: HighlightSpan[];
6011     }
6012 }
6013 declare namespace ts {
6014     /**
6015      * The document registry represents a store of SourceFile objects that can be shared between
6016      * multiple LanguageService instances. A LanguageService instance holds on the SourceFile (AST)
6017      * of files in the context.
6018      * SourceFile objects account for most of the memory usage by the language service. Sharing
6019      * the same DocumentRegistry instance between different instances of LanguageService allow
6020      * for more efficient memory utilization since all projects will share at least the library
6021      * file (lib.d.ts).
6022      *
6023      * A more advanced use of the document registry is to serialize sourceFile objects to disk
6024      * and re-hydrate them when needed.
6025      *
6026      * To create a default DocumentRegistry, use createDocumentRegistry to create one, and pass it
6027      * to all subsequent createLanguageService calls.
6028      */
6029     interface DocumentRegistry {
6030         /**
6031          * Request a stored SourceFile with a given fileName and compilationSettings.
6032          * The first call to acquire will call createLanguageServiceSourceFile to generate
6033          * the SourceFile if was not found in the registry.
6034          *
6035          * @param fileName The name of the file requested
6036          * @param compilationSettings Some compilation settings like target affects the
6037          * shape of a the resulting SourceFile. This allows the DocumentRegistry to store
6038          * multiple copies of the same file for different compilation settings.
6039          * @param scriptSnapshot Text of the file. Only used if the file was not found
6040          * in the registry and a new one was created.
6041          * @param version Current version of the file. Only used if the file was not found
6042          * in the registry and a new one was created.
6043          */
6044         acquireDocument(fileName: string, compilationSettings: CompilerOptions, scriptSnapshot: IScriptSnapshot, version: string, scriptKind?: ScriptKind): SourceFile;
6045         acquireDocumentWithKey(fileName: string, path: Path, compilationSettings: CompilerOptions, key: DocumentRegistryBucketKey, scriptSnapshot: IScriptSnapshot, version: string, scriptKind?: ScriptKind): SourceFile;
6046         /**
6047          * Request an updated version of an already existing SourceFile with a given fileName
6048          * and compilationSettings. The update will in-turn call updateLanguageServiceSourceFile
6049          * to get an updated SourceFile.
6050          *
6051          * @param fileName The name of the file requested
6052          * @param compilationSettings Some compilation settings like target affects the
6053          * shape of a the resulting SourceFile. This allows the DocumentRegistry to store
6054          * multiple copies of the same file for different compilation settings.
6055          * @param scriptSnapshot Text of the file.
6056          * @param version Current version of the file.
6057          */
6058         updateDocument(fileName: string, compilationSettings: CompilerOptions, scriptSnapshot: IScriptSnapshot, version: string, scriptKind?: ScriptKind): SourceFile;
6059         updateDocumentWithKey(fileName: string, path: Path, compilationSettings: CompilerOptions, key: DocumentRegistryBucketKey, scriptSnapshot: IScriptSnapshot, version: string, scriptKind?: ScriptKind): SourceFile;
6060         getKeyForCompilationSettings(settings: CompilerOptions): DocumentRegistryBucketKey;
6061         /**
6062          * Informs the DocumentRegistry that a file is not needed any longer.
6063          *
6064          * Note: It is not allowed to call release on a SourceFile that was not acquired from
6065          * this registry originally.
6066          *
6067          * @param fileName The name of the file to be released
6068          * @param compilationSettings The compilation settings used to acquire the file
6069          */
6070         releaseDocument(fileName: string, compilationSettings: CompilerOptions): void;
6071         releaseDocumentWithKey(path: Path, key: DocumentRegistryBucketKey): void;
6072         reportStats(): string;
6073     }
6074     type DocumentRegistryBucketKey = string & {
6075         __bucketKey: any;
6076     };
6077     function createDocumentRegistry(useCaseSensitiveFileNames?: boolean, currentDirectory?: string): DocumentRegistry;
6078 }
6079 declare namespace ts {
6080     function preProcessFile(sourceText: string, readImportFiles?: boolean, detectJavaScriptImports?: boolean): PreProcessedFileInfo;
6081 }
6082 declare namespace ts {
6083     interface TranspileOptions {
6084         compilerOptions?: CompilerOptions;
6085         fileName?: string;
6086         reportDiagnostics?: boolean;
6087         moduleName?: string;
6088         renamedDependencies?: MapLike<string>;
6089         transformers?: CustomTransformers;
6090     }
6091     interface TranspileOutput {
6092         outputText: string;
6093         diagnostics?: Diagnostic[];
6094         sourceMapText?: string;
6095     }
6096     function transpileModule(input: string, transpileOptions: TranspileOptions): TranspileOutput;
6097     function transpile(input: string, compilerOptions?: CompilerOptions, fileName?: string, diagnostics?: Diagnostic[], moduleName?: string): string;
6098 }
6099 declare namespace ts {
6100     /** The version of the language service API */
6101     const servicesVersion = "0.8";
6102     function toEditorSettings(options: EditorOptions | EditorSettings): EditorSettings;
6103     function displayPartsToString(displayParts: SymbolDisplayPart[] | undefined): string;
6104     function getDefaultCompilerOptions(): CompilerOptions;
6105     function getSupportedCodeFixes(): string[];
6106     function createLanguageServiceSourceFile(fileName: string, scriptSnapshot: IScriptSnapshot, scriptTarget: ScriptTarget, version: string, setNodeParents: boolean, scriptKind?: ScriptKind): SourceFile;
6107     function updateLanguageServiceSourceFile(sourceFile: SourceFile, scriptSnapshot: IScriptSnapshot, version: string, textChangeRange: TextChangeRange | undefined, aggressiveChecks?: boolean): SourceFile;
6108     function createLanguageService(host: LanguageServiceHost, documentRegistry?: DocumentRegistry, syntaxOnly?: boolean): LanguageService;
6109     /**
6110      * Get the path of the default library files (lib.d.ts) as distributed with the typescript
6111      * node package.
6112      * The functionality is not supported if the ts module is consumed outside of a node module.
6113      */
6114     function getDefaultLibFilePath(options: CompilerOptions): string;
6115 }
6116 declare namespace ts {
6117     /**
6118      * Transform one or more nodes using the supplied transformers.
6119      * @param source A single `Node` or an array of `Node` objects.
6120      * @param transformers An array of `TransformerFactory` callbacks used to process the transformation.
6121      * @param compilerOptions Optional compiler options.
6122      */
6123     function transform<T extends Node>(source: T | T[], transformers: TransformerFactory<T>[], compilerOptions?: CompilerOptions): TransformationResult<T>;
6124 }
6125
6126 export = ts;