hermes-estree 0.28.1 → 0.29.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,2944 @@
1
+ /**
2
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
3
+ *
4
+ * This source code is licensed under the MIT license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ *
7
+ *
8
+ * @generated
9
+ */
10
+
11
+ /*
12
+ * !!! GENERATED FILE !!!
13
+ *
14
+ * Any manual changes to this file will be overwritten. To regenerate run `yarn build`.
15
+ */
16
+ // lint directives to let us do some basic validation of generated files
17
+
18
+ /* eslint no-undef: 'error', no-unused-vars: ['error', {vars: "local"}], no-redeclare: 'error' */
19
+
20
+ /* global $NonMaybeType, Partial, $ReadOnly, $ReadOnlyArray, $FlowFixMe */
21
+ 'use strict';
22
+ /*::
23
+ import type {
24
+ ESNode,
25
+ Token,
26
+ AFunction,
27
+ ClassMember,
28
+ BigIntLiteral,
29
+ BooleanLiteral,
30
+ NullLiteral,
31
+ NumericLiteral,
32
+ RegExpLiteral,
33
+ StringLiteral,
34
+ Identifier,
35
+ JSXIdentifier,
36
+ JSXText,
37
+ AnyTypeAnnotation,
38
+ ArrayExpression,
39
+ ArrayPattern,
40
+ ArrayTypeAnnotation,
41
+ ArrowFunctionExpression,
42
+ AsConstExpression,
43
+ AsExpression,
44
+ AssignmentExpression,
45
+ AssignmentPattern,
46
+ AwaitExpression,
47
+ BigIntLiteralTypeAnnotation,
48
+ BigIntTypeAnnotation,
49
+ BinaryExpression,
50
+ BlockStatement,
51
+ BooleanLiteralTypeAnnotation,
52
+ BooleanTypeAnnotation,
53
+ BreakStatement,
54
+ CallExpression,
55
+ CatchClause,
56
+ ChainExpression,
57
+ ClassBody,
58
+ ClassDeclaration,
59
+ ClassExpression,
60
+ ClassImplements,
61
+ ComponentDeclaration,
62
+ ComponentParameter,
63
+ ComponentTypeAnnotation,
64
+ ComponentTypeParameter,
65
+ ConditionalExpression,
66
+ ConditionalTypeAnnotation,
67
+ ContinueStatement,
68
+ DebuggerStatement,
69
+ DeclareClass,
70
+ DeclareComponent,
71
+ DeclaredPredicate,
72
+ DeclareEnum,
73
+ DeclareExportAllDeclaration,
74
+ DeclareExportDeclaration,
75
+ DeclareFunction,
76
+ DeclareHook,
77
+ DeclareInterface,
78
+ DeclareModule,
79
+ DeclareModuleExports,
80
+ DeclareNamespace,
81
+ DeclareOpaqueType,
82
+ DeclareTypeAlias,
83
+ DeclareVariable,
84
+ DoWhileStatement,
85
+ EmptyStatement,
86
+ EmptyTypeAnnotation,
87
+ EnumBigIntBody,
88
+ EnumBigIntMember,
89
+ EnumBooleanBody,
90
+ EnumBooleanMember,
91
+ EnumDeclaration,
92
+ EnumDefaultedMember,
93
+ EnumNumberBody,
94
+ EnumNumberMember,
95
+ EnumStringBody,
96
+ EnumStringMember,
97
+ EnumSymbolBody,
98
+ ExistsTypeAnnotation,
99
+ ExportAllDeclaration,
100
+ ExportDefaultDeclaration,
101
+ ExportNamedDeclaration,
102
+ ExportSpecifier,
103
+ ExpressionStatement,
104
+ ForInStatement,
105
+ ForOfStatement,
106
+ ForStatement,
107
+ FunctionDeclaration,
108
+ FunctionExpression,
109
+ FunctionTypeAnnotation,
110
+ FunctionTypeParam,
111
+ GenericTypeAnnotation,
112
+ HookDeclaration,
113
+ HookTypeAnnotation,
114
+ IfStatement,
115
+ ImportAttribute,
116
+ ImportDeclaration,
117
+ ImportDefaultSpecifier,
118
+ ImportExpression,
119
+ ImportNamespaceSpecifier,
120
+ ImportSpecifier,
121
+ IndexedAccessType,
122
+ InferredPredicate,
123
+ InferTypeAnnotation,
124
+ InterfaceDeclaration,
125
+ InterfaceExtends,
126
+ InterfaceTypeAnnotation,
127
+ IntersectionTypeAnnotation,
128
+ JSXAttribute,
129
+ JSXClosingElement,
130
+ JSXClosingFragment,
131
+ JSXElement,
132
+ JSXEmptyExpression,
133
+ JSXExpressionContainer,
134
+ JSXFragment,
135
+ JSXMemberExpression,
136
+ JSXNamespacedName,
137
+ JSXOpeningElement,
138
+ JSXOpeningFragment,
139
+ JSXSpreadAttribute,
140
+ JSXSpreadChild,
141
+ KeyofTypeAnnotation,
142
+ LabeledStatement,
143
+ LogicalExpression,
144
+ MatchArrayPattern,
145
+ MatchAsPattern,
146
+ MatchBindingPattern,
147
+ MatchExpression,
148
+ MatchExpressionCase,
149
+ MatchIdentifierPattern,
150
+ MatchLiteralPattern,
151
+ MatchMemberPattern,
152
+ MatchObjectPattern,
153
+ MatchObjectPatternProperty,
154
+ MatchOrPattern,
155
+ MatchRestPattern,
156
+ MatchStatement,
157
+ MatchStatementCase,
158
+ MatchUnaryPattern,
159
+ MatchWildcardPattern,
160
+ MemberExpression,
161
+ MetaProperty,
162
+ MethodDefinition,
163
+ MixedTypeAnnotation,
164
+ NewExpression,
165
+ NullableTypeAnnotation,
166
+ NullLiteralTypeAnnotation,
167
+ NumberLiteralTypeAnnotation,
168
+ NumberTypeAnnotation,
169
+ ObjectExpression,
170
+ ObjectPattern,
171
+ ObjectTypeAnnotation,
172
+ ObjectTypeCallProperty,
173
+ ObjectTypeIndexer,
174
+ ObjectTypeInternalSlot,
175
+ ObjectTypeMappedTypeProperty,
176
+ ObjectTypeProperty,
177
+ ObjectTypeSpreadProperty,
178
+ OpaqueType,
179
+ OptionalIndexedAccessType,
180
+ PrivateIdentifier,
181
+ Program,
182
+ Property,
183
+ PropertyDefinition,
184
+ QualifiedTypeIdentifier,
185
+ QualifiedTypeofIdentifier,
186
+ RestElement,
187
+ ReturnStatement,
188
+ SequenceExpression,
189
+ SpreadElement,
190
+ StaticBlock,
191
+ StringLiteralTypeAnnotation,
192
+ StringTypeAnnotation,
193
+ Super,
194
+ SwitchCase,
195
+ SwitchStatement,
196
+ SymbolTypeAnnotation,
197
+ TaggedTemplateExpression,
198
+ TemplateElement,
199
+ TemplateLiteral,
200
+ ThisExpression,
201
+ ThisTypeAnnotation,
202
+ ThrowStatement,
203
+ TryStatement,
204
+ TupleTypeAnnotation,
205
+ TupleTypeLabeledElement,
206
+ TupleTypeSpreadElement,
207
+ TypeAlias,
208
+ TypeAnnotation,
209
+ TypeCastExpression,
210
+ TypeofTypeAnnotation,
211
+ TypeOperator,
212
+ TypeParameter,
213
+ TypeParameterDeclaration,
214
+ TypeParameterInstantiation,
215
+ TypePredicate,
216
+ UnaryExpression,
217
+ UnionTypeAnnotation,
218
+ UpdateExpression,
219
+ VariableDeclaration,
220
+ VariableDeclarator,
221
+ Variance,
222
+ VoidTypeAnnotation,
223
+ WhileStatement,
224
+ WithStatement,
225
+ YieldExpression,
226
+ Literal,
227
+ LineComment,
228
+ BlockComment,
229
+ MostTokens,
230
+ } from '../types';
231
+ */
232
+
233
+ Object.defineProperty(exports, "__esModule", {
234
+ value: true
235
+ });
236
+ exports.isAnyTypeAnnotation = isAnyTypeAnnotation;
237
+ exports.isArrayExpression = isArrayExpression;
238
+ exports.isArrayPattern = isArrayPattern;
239
+ exports.isArrayTypeAnnotation = isArrayTypeAnnotation;
240
+ exports.isArrowFunctionExpression = isArrowFunctionExpression;
241
+ exports.isAsConstExpression = isAsConstExpression;
242
+ exports.isAsExpression = isAsExpression;
243
+ exports.isAsKeyword = isAsKeyword;
244
+ exports.isAssignmentExpression = isAssignmentExpression;
245
+ exports.isAssignmentPattern = isAssignmentPattern;
246
+ exports.isAsterixToken = isAsterixToken;
247
+ exports.isAsyncKeyword = isAsyncKeyword;
248
+ exports.isAwaitExpression = isAwaitExpression;
249
+ exports.isAwaitKeyword = isAwaitKeyword;
250
+ exports.isBigIntLiteralTypeAnnotation = isBigIntLiteralTypeAnnotation;
251
+ exports.isBigIntTypeAnnotation = isBigIntTypeAnnotation;
252
+ exports.isBinaryExpression = isBinaryExpression;
253
+ exports.isBitwiseANDEqualToken = isBitwiseANDEqualToken;
254
+ exports.isBitwiseANDToken = isBitwiseANDToken;
255
+ exports.isBitwiseLeftShiftEqualToken = isBitwiseLeftShiftEqualToken;
256
+ exports.isBitwiseLeftShiftToken = isBitwiseLeftShiftToken;
257
+ exports.isBitwiseOREqualToken = isBitwiseOREqualToken;
258
+ exports.isBitwiseORToken = isBitwiseORToken;
259
+ exports.isBitwiseRightShiftEqualToken = isBitwiseRightShiftEqualToken;
260
+ exports.isBitwiseRightShiftToken = isBitwiseRightShiftToken;
261
+ exports.isBitwiseUnsignedRightShiftEqualToken = isBitwiseUnsignedRightShiftEqualToken;
262
+ exports.isBitwiseUnsignedRightShiftToken = isBitwiseUnsignedRightShiftToken;
263
+ exports.isBitwiseXOREqualToken = isBitwiseXOREqualToken;
264
+ exports.isBitwiseXORToken = isBitwiseXORToken;
265
+ exports.isBlockComment = isBlockComment;
266
+ exports.isBlockStatement = isBlockStatement;
267
+ exports.isBooleanLiteralTypeAnnotation = isBooleanLiteralTypeAnnotation;
268
+ exports.isBooleanTypeAnnotation = isBooleanTypeAnnotation;
269
+ exports.isBreakStatement = isBreakStatement;
270
+ exports.isBreakToken = isBreakToken;
271
+ exports.isCallExpression = isCallExpression;
272
+ exports.isCaseToken = isCaseToken;
273
+ exports.isCatchClause = isCatchClause;
274
+ exports.isCatchToken = isCatchToken;
275
+ exports.isChainExpression = isChainExpression;
276
+ exports.isClassBody = isClassBody;
277
+ exports.isClassDeclaration = isClassDeclaration;
278
+ exports.isClassExpression = isClassExpression;
279
+ exports.isClassImplements = isClassImplements;
280
+ exports.isClassToken = isClassToken;
281
+ exports.isClosingAngleBracketToken = isClosingAngleBracketToken;
282
+ exports.isClosingCurlyBracketToken = isClosingCurlyBracketToken;
283
+ exports.isClosingParenthesisToken = isClosingParenthesisToken;
284
+ exports.isColonToken = isColonToken;
285
+ exports.isCommaToken = isCommaToken;
286
+ exports.isComponentDeclaration = isComponentDeclaration;
287
+ exports.isComponentParameter = isComponentParameter;
288
+ exports.isComponentTypeAnnotation = isComponentTypeAnnotation;
289
+ exports.isComponentTypeParameter = isComponentTypeParameter;
290
+ exports.isConditionalExpression = isConditionalExpression;
291
+ exports.isConditionalTypeAnnotation = isConditionalTypeAnnotation;
292
+ exports.isConstToken = isConstToken;
293
+ exports.isContinueStatement = isContinueStatement;
294
+ exports.isContinueToken = isContinueToken;
295
+ exports.isDebuggerStatement = isDebuggerStatement;
296
+ exports.isDebuggerToken = isDebuggerToken;
297
+ exports.isDeclareClass = isDeclareClass;
298
+ exports.isDeclareComponent = isDeclareComponent;
299
+ exports.isDeclareEnum = isDeclareEnum;
300
+ exports.isDeclareExportAllDeclaration = isDeclareExportAllDeclaration;
301
+ exports.isDeclareExportDeclaration = isDeclareExportDeclaration;
302
+ exports.isDeclareFunction = isDeclareFunction;
303
+ exports.isDeclareHook = isDeclareHook;
304
+ exports.isDeclareInterface = isDeclareInterface;
305
+ exports.isDeclareKeyword = isDeclareKeyword;
306
+ exports.isDeclareModule = isDeclareModule;
307
+ exports.isDeclareModuleExports = isDeclareModuleExports;
308
+ exports.isDeclareNamespace = isDeclareNamespace;
309
+ exports.isDeclareOpaqueType = isDeclareOpaqueType;
310
+ exports.isDeclareTypeAlias = isDeclareTypeAlias;
311
+ exports.isDeclareVariable = isDeclareVariable;
312
+ exports.isDeclaredPredicate = isDeclaredPredicate;
313
+ exports.isDecrementToken = isDecrementToken;
314
+ exports.isDefaultToken = isDefaultToken;
315
+ exports.isDeleteToken = isDeleteToken;
316
+ exports.isDivideEqualToken = isDivideEqualToken;
317
+ exports.isDoToken = isDoToken;
318
+ exports.isDoWhileStatement = isDoWhileStatement;
319
+ exports.isDotDotDotToken = isDotDotDotToken;
320
+ exports.isDotToken = isDotToken;
321
+ exports.isElseToken = isElseToken;
322
+ exports.isEmptyStatement = isEmptyStatement;
323
+ exports.isEmptyTypeAnnotation = isEmptyTypeAnnotation;
324
+ exports.isEnumBigIntBody = isEnumBigIntBody;
325
+ exports.isEnumBigIntMember = isEnumBigIntMember;
326
+ exports.isEnumBooleanBody = isEnumBooleanBody;
327
+ exports.isEnumBooleanMember = isEnumBooleanMember;
328
+ exports.isEnumDeclaration = isEnumDeclaration;
329
+ exports.isEnumDefaultedMember = isEnumDefaultedMember;
330
+ exports.isEnumNumberBody = isEnumNumberBody;
331
+ exports.isEnumNumberMember = isEnumNumberMember;
332
+ exports.isEnumStringBody = isEnumStringBody;
333
+ exports.isEnumStringMember = isEnumStringMember;
334
+ exports.isEnumSymbolBody = isEnumSymbolBody;
335
+ exports.isEnumToken = isEnumToken;
336
+ exports.isEqualToken = isEqualToken;
337
+ exports.isExistsTypeAnnotation = isExistsTypeAnnotation;
338
+ exports.isExponentateEqualToken = isExponentateEqualToken;
339
+ exports.isExponentiationToken = isExponentiationToken;
340
+ exports.isExportAllDeclaration = isExportAllDeclaration;
341
+ exports.isExportDefaultDeclaration = isExportDefaultDeclaration;
342
+ exports.isExportNamedDeclaration = isExportNamedDeclaration;
343
+ exports.isExportSpecifier = isExportSpecifier;
344
+ exports.isExportToken = isExportToken;
345
+ exports.isExpressionStatement = isExpressionStatement;
346
+ exports.isExtendsToken = isExtendsToken;
347
+ exports.isFinallyToken = isFinallyToken;
348
+ exports.isForInStatement = isForInStatement;
349
+ exports.isForOfStatement = isForOfStatement;
350
+ exports.isForStatement = isForStatement;
351
+ exports.isForToken = isForToken;
352
+ exports.isForwardSlashToken = isForwardSlashToken;
353
+ exports.isFromKeyword = isFromKeyword;
354
+ exports.isFunctionDeclaration = isFunctionDeclaration;
355
+ exports.isFunctionExpression = isFunctionExpression;
356
+ exports.isFunctionToken = isFunctionToken;
357
+ exports.isFunctionTypeAnnotation = isFunctionTypeAnnotation;
358
+ exports.isFunctionTypeParam = isFunctionTypeParam;
359
+ exports.isGenericTypeAnnotation = isGenericTypeAnnotation;
360
+ exports.isGetKeyword = isGetKeyword;
361
+ exports.isGreaterThanOrEqualToToken = isGreaterThanOrEqualToToken;
362
+ exports.isGreaterThanToken = isGreaterThanToken;
363
+ exports.isHookDeclaration = isHookDeclaration;
364
+ exports.isHookTypeAnnotation = isHookTypeAnnotation;
365
+ exports.isIdentifier = isIdentifier;
366
+ exports.isIfStatement = isIfStatement;
367
+ exports.isIfToken = isIfToken;
368
+ exports.isImplementsToken = isImplementsToken;
369
+ exports.isImportAttribute = isImportAttribute;
370
+ exports.isImportDeclaration = isImportDeclaration;
371
+ exports.isImportDefaultSpecifier = isImportDefaultSpecifier;
372
+ exports.isImportExpression = isImportExpression;
373
+ exports.isImportNamespaceSpecifier = isImportNamespaceSpecifier;
374
+ exports.isImportSpecifier = isImportSpecifier;
375
+ exports.isImportToken = isImportToken;
376
+ exports.isInToken = isInToken;
377
+ exports.isIncrementToken = isIncrementToken;
378
+ exports.isIndexedAccessType = isIndexedAccessType;
379
+ exports.isInferTypeAnnotation = isInferTypeAnnotation;
380
+ exports.isInferredPredicate = isInferredPredicate;
381
+ exports.isInstanceOfToken = isInstanceOfToken;
382
+ exports.isInterfaceDeclaration = isInterfaceDeclaration;
383
+ exports.isInterfaceExtends = isInterfaceExtends;
384
+ exports.isInterfaceToken = isInterfaceToken;
385
+ exports.isInterfaceTypeAnnotation = isInterfaceTypeAnnotation;
386
+ exports.isIntersectionTypeAnnotation = isIntersectionTypeAnnotation;
387
+ exports.isIntersectionTypeToken = isIntersectionTypeToken;
388
+ exports.isJSXAttribute = isJSXAttribute;
389
+ exports.isJSXClosingElement = isJSXClosingElement;
390
+ exports.isJSXClosingFragment = isJSXClosingFragment;
391
+ exports.isJSXElement = isJSXElement;
392
+ exports.isJSXEmptyExpression = isJSXEmptyExpression;
393
+ exports.isJSXExpressionContainer = isJSXExpressionContainer;
394
+ exports.isJSXFragment = isJSXFragment;
395
+ exports.isJSXIdentifier = isJSXIdentifier;
396
+ exports.isJSXMemberExpression = isJSXMemberExpression;
397
+ exports.isJSXNamespacedName = isJSXNamespacedName;
398
+ exports.isJSXOpeningElement = isJSXOpeningElement;
399
+ exports.isJSXOpeningFragment = isJSXOpeningFragment;
400
+ exports.isJSXSpreadAttribute = isJSXSpreadAttribute;
401
+ exports.isJSXSpreadChild = isJSXSpreadChild;
402
+ exports.isJSXText = isJSXText;
403
+ exports.isKeyofTypeAnnotation = isKeyofTypeAnnotation;
404
+ exports.isLabeledStatement = isLabeledStatement;
405
+ exports.isLessThanOrEqualToToken = isLessThanOrEqualToToken;
406
+ exports.isLessThanToken = isLessThanToken;
407
+ exports.isLetKeyword = isLetKeyword;
408
+ exports.isLineComment = isLineComment;
409
+ exports.isLiteral = isLiteral;
410
+ exports.isLogicalANDEqualToken = isLogicalANDEqualToken;
411
+ exports.isLogicalANDToken = isLogicalANDToken;
412
+ exports.isLogicalExpression = isLogicalExpression;
413
+ exports.isLogicalNotToken = isLogicalNotToken;
414
+ exports.isLogicalOREqualToken = isLogicalOREqualToken;
415
+ exports.isLogicalORToken = isLogicalORToken;
416
+ exports.isLooseEqualToken = isLooseEqualToken;
417
+ exports.isLooseNotEqualToken = isLooseNotEqualToken;
418
+ exports.isMatchArrayPattern = isMatchArrayPattern;
419
+ exports.isMatchAsPattern = isMatchAsPattern;
420
+ exports.isMatchBindingPattern = isMatchBindingPattern;
421
+ exports.isMatchExpression = isMatchExpression;
422
+ exports.isMatchExpressionCase = isMatchExpressionCase;
423
+ exports.isMatchIdentifierPattern = isMatchIdentifierPattern;
424
+ exports.isMatchLiteralPattern = isMatchLiteralPattern;
425
+ exports.isMatchMemberPattern = isMatchMemberPattern;
426
+ exports.isMatchObjectPattern = isMatchObjectPattern;
427
+ exports.isMatchObjectPatternProperty = isMatchObjectPatternProperty;
428
+ exports.isMatchOrPattern = isMatchOrPattern;
429
+ exports.isMatchRestPattern = isMatchRestPattern;
430
+ exports.isMatchStatement = isMatchStatement;
431
+ exports.isMatchStatementCase = isMatchStatementCase;
432
+ exports.isMatchUnaryPattern = isMatchUnaryPattern;
433
+ exports.isMatchWildcardPattern = isMatchWildcardPattern;
434
+ exports.isMemberExpression = isMemberExpression;
435
+ exports.isMetaProperty = isMetaProperty;
436
+ exports.isMethodDefinition = isMethodDefinition;
437
+ exports.isMinusEqualToken = isMinusEqualToken;
438
+ exports.isMinusToken = isMinusToken;
439
+ exports.isMixedTypeAnnotation = isMixedTypeAnnotation;
440
+ exports.isModuleKeyword = isModuleKeyword;
441
+ exports.isMultiplyEqualToken = isMultiplyEqualToken;
442
+ exports.isNewExpression = isNewExpression;
443
+ exports.isNewToken = isNewToken;
444
+ exports.isNullLiteralTypeAnnotation = isNullLiteralTypeAnnotation;
445
+ exports.isNullableTypeAnnotation = isNullableTypeAnnotation;
446
+ exports.isNullishCoalesceEqualToken = isNullishCoalesceEqualToken;
447
+ exports.isNullishCoalesceToken = isNullishCoalesceToken;
448
+ exports.isNumberLiteralTypeAnnotation = isNumberLiteralTypeAnnotation;
449
+ exports.isNumberTypeAnnotation = isNumberTypeAnnotation;
450
+ exports.isObjectExpression = isObjectExpression;
451
+ exports.isObjectPattern = isObjectPattern;
452
+ exports.isObjectTypeAnnotation = isObjectTypeAnnotation;
453
+ exports.isObjectTypeCallProperty = isObjectTypeCallProperty;
454
+ exports.isObjectTypeIndexer = isObjectTypeIndexer;
455
+ exports.isObjectTypeInternalSlot = isObjectTypeInternalSlot;
456
+ exports.isObjectTypeMappedTypeProperty = isObjectTypeMappedTypeProperty;
457
+ exports.isObjectTypeProperty = isObjectTypeProperty;
458
+ exports.isObjectTypeSpreadProperty = isObjectTypeSpreadProperty;
459
+ exports.isOfKeyword = isOfKeyword;
460
+ exports.isOpaqueType = isOpaqueType;
461
+ exports.isOpeningAngleBracketToken = isOpeningAngleBracketToken;
462
+ exports.isOpeningCurlyBracketToken = isOpeningCurlyBracketToken;
463
+ exports.isOpeningParenthesisToken = isOpeningParenthesisToken;
464
+ exports.isOptionalChainToken = isOptionalChainToken;
465
+ exports.isOptionalIndexedAccessType = isOptionalIndexedAccessType;
466
+ exports.isPercentToken = isPercentToken;
467
+ exports.isPlusEqualToken = isPlusEqualToken;
468
+ exports.isPlusToken = isPlusToken;
469
+ exports.isPrivateIdentifier = isPrivateIdentifier;
470
+ exports.isProgram = isProgram;
471
+ exports.isProperty = isProperty;
472
+ exports.isPropertyDefinition = isPropertyDefinition;
473
+ exports.isQualifiedTypeIdentifier = isQualifiedTypeIdentifier;
474
+ exports.isQualifiedTypeofIdentifier = isQualifiedTypeofIdentifier;
475
+ exports.isQuestionMarkToken = isQuestionMarkToken;
476
+ exports.isRemainderEqualToken = isRemainderEqualToken;
477
+ exports.isRestElement = isRestElement;
478
+ exports.isReturnStatement = isReturnStatement;
479
+ exports.isReturnToken = isReturnToken;
480
+ exports.isSemicolonToken = isSemicolonToken;
481
+ exports.isSequenceExpression = isSequenceExpression;
482
+ exports.isSetKeyword = isSetKeyword;
483
+ exports.isSpreadElement = isSpreadElement;
484
+ exports.isStaticBlock = isStaticBlock;
485
+ exports.isStaticToken = isStaticToken;
486
+ exports.isStrictEqualToken = isStrictEqualToken;
487
+ exports.isStrictNotEqualToken = isStrictNotEqualToken;
488
+ exports.isStringLiteralTypeAnnotation = isStringLiteralTypeAnnotation;
489
+ exports.isStringTypeAnnotation = isStringTypeAnnotation;
490
+ exports.isSuper = isSuper;
491
+ exports.isSuperToken = isSuperToken;
492
+ exports.isSwitchCase = isSwitchCase;
493
+ exports.isSwitchStatement = isSwitchStatement;
494
+ exports.isSwitchToken = isSwitchToken;
495
+ exports.isSymbolTypeAnnotation = isSymbolTypeAnnotation;
496
+ exports.isTaggedTemplateExpression = isTaggedTemplateExpression;
497
+ exports.isTemplateElement = isTemplateElement;
498
+ exports.isTemplateLiteral = isTemplateLiteral;
499
+ exports.isThisExpression = isThisExpression;
500
+ exports.isThisToken = isThisToken;
501
+ exports.isThisTypeAnnotation = isThisTypeAnnotation;
502
+ exports.isThrowStatement = isThrowStatement;
503
+ exports.isThrowToken = isThrowToken;
504
+ exports.isTryStatement = isTryStatement;
505
+ exports.isTryToken = isTryToken;
506
+ exports.isTupleTypeAnnotation = isTupleTypeAnnotation;
507
+ exports.isTupleTypeLabeledElement = isTupleTypeLabeledElement;
508
+ exports.isTupleTypeSpreadElement = isTupleTypeSpreadElement;
509
+ exports.isTypeAlias = isTypeAlias;
510
+ exports.isTypeAnnotation = isTypeAnnotation;
511
+ exports.isTypeCastExpression = isTypeCastExpression;
512
+ exports.isTypeKeyword = isTypeKeyword;
513
+ exports.isTypeOfToken = isTypeOfToken;
514
+ exports.isTypeOperator = isTypeOperator;
515
+ exports.isTypeParameter = isTypeParameter;
516
+ exports.isTypeParameterDeclaration = isTypeParameterDeclaration;
517
+ exports.isTypeParameterInstantiation = isTypeParameterInstantiation;
518
+ exports.isTypePredicate = isTypePredicate;
519
+ exports.isTypeofTypeAnnotation = isTypeofTypeAnnotation;
520
+ exports.isUnaryExpression = isUnaryExpression;
521
+ exports.isUnaryNegationToken = isUnaryNegationToken;
522
+ exports.isUnionTypeAnnotation = isUnionTypeAnnotation;
523
+ exports.isUnionTypeToken = isUnionTypeToken;
524
+ exports.isUpdateExpression = isUpdateExpression;
525
+ exports.isVarToken = isVarToken;
526
+ exports.isVariableDeclaration = isVariableDeclaration;
527
+ exports.isVariableDeclarator = isVariableDeclarator;
528
+ exports.isVariance = isVariance;
529
+ exports.isVoidToken = isVoidToken;
530
+ exports.isVoidTypeAnnotation = isVoidTypeAnnotation;
531
+ exports.isWhileStatement = isWhileStatement;
532
+ exports.isWhileToken = isWhileToken;
533
+ exports.isWithStatement = isWithStatement;
534
+ exports.isWithToken = isWithToken;
535
+ exports.isYieldExpression = isYieldExpression;
536
+ exports.isYieldToken = isYieldToken;
537
+
538
+ function isIdentifier(node
539
+ /*: ESNode | Token */
540
+ )
541
+ /*: implies node is (Identifier | MostTokens) */
542
+ {
543
+ return node.type === 'Identifier';
544
+ }
545
+
546
+ function isJSXIdentifier(node
547
+ /*: ESNode | Token */
548
+ )
549
+ /*: implies node is (JSXIdentifier | MostTokens) */
550
+ {
551
+ return node.type === 'JSXIdentifier';
552
+ }
553
+
554
+ function isJSXText(node
555
+ /*: ESNode | Token */
556
+ )
557
+ /*: implies node is (JSXText | MostTokens) */
558
+ {
559
+ return node.type === 'JSXText';
560
+ }
561
+
562
+ function isAnyTypeAnnotation(node
563
+ /*: ESNode | Token */
564
+ )
565
+ /*: implies node is AnyTypeAnnotation */
566
+ {
567
+ return node.type === 'AnyTypeAnnotation';
568
+ }
569
+
570
+ function isArrayExpression(node
571
+ /*: ESNode | Token */
572
+ )
573
+ /*: implies node is ArrayExpression */
574
+ {
575
+ return node.type === 'ArrayExpression';
576
+ }
577
+
578
+ function isArrayPattern(node
579
+ /*: ESNode | Token */
580
+ )
581
+ /*: implies node is ArrayPattern */
582
+ {
583
+ return node.type === 'ArrayPattern';
584
+ }
585
+
586
+ function isArrayTypeAnnotation(node
587
+ /*: ESNode | Token */
588
+ )
589
+ /*: implies node is ArrayTypeAnnotation */
590
+ {
591
+ return node.type === 'ArrayTypeAnnotation';
592
+ }
593
+
594
+ function isArrowFunctionExpression(node
595
+ /*: ESNode | Token */
596
+ )
597
+ /*: implies node is ArrowFunctionExpression */
598
+ {
599
+ return node.type === 'ArrowFunctionExpression';
600
+ }
601
+
602
+ function isAsConstExpression(node
603
+ /*: ESNode | Token */
604
+ )
605
+ /*: implies node is AsConstExpression */
606
+ {
607
+ return node.type === 'AsConstExpression';
608
+ }
609
+
610
+ function isAsExpression(node
611
+ /*: ESNode | Token */
612
+ )
613
+ /*: implies node is AsExpression */
614
+ {
615
+ return node.type === 'AsExpression';
616
+ }
617
+
618
+ function isAssignmentExpression(node
619
+ /*: ESNode | Token */
620
+ )
621
+ /*: implies node is AssignmentExpression */
622
+ {
623
+ return node.type === 'AssignmentExpression';
624
+ }
625
+
626
+ function isAssignmentPattern(node
627
+ /*: ESNode | Token */
628
+ )
629
+ /*: implies node is AssignmentPattern */
630
+ {
631
+ return node.type === 'AssignmentPattern';
632
+ }
633
+
634
+ function isAwaitExpression(node
635
+ /*: ESNode | Token */
636
+ )
637
+ /*: implies node is AwaitExpression */
638
+ {
639
+ return node.type === 'AwaitExpression';
640
+ }
641
+
642
+ function isBigIntLiteralTypeAnnotation(node
643
+ /*: ESNode | Token */
644
+ )
645
+ /*: implies node is BigIntLiteralTypeAnnotation */
646
+ {
647
+ return node.type === 'BigIntLiteralTypeAnnotation';
648
+ }
649
+
650
+ function isBigIntTypeAnnotation(node
651
+ /*: ESNode | Token */
652
+ )
653
+ /*: implies node is BigIntTypeAnnotation */
654
+ {
655
+ return node.type === 'BigIntTypeAnnotation';
656
+ }
657
+
658
+ function isBinaryExpression(node
659
+ /*: ESNode | Token */
660
+ )
661
+ /*: implies node is BinaryExpression */
662
+ {
663
+ return node.type === 'BinaryExpression';
664
+ }
665
+
666
+ function isBlockStatement(node
667
+ /*: ESNode | Token */
668
+ )
669
+ /*: implies node is BlockStatement */
670
+ {
671
+ return node.type === 'BlockStatement';
672
+ }
673
+
674
+ function isBooleanLiteralTypeAnnotation(node
675
+ /*: ESNode | Token */
676
+ )
677
+ /*: implies node is BooleanLiteralTypeAnnotation */
678
+ {
679
+ return node.type === 'BooleanLiteralTypeAnnotation';
680
+ }
681
+
682
+ function isBooleanTypeAnnotation(node
683
+ /*: ESNode | Token */
684
+ )
685
+ /*: implies node is BooleanTypeAnnotation */
686
+ {
687
+ return node.type === 'BooleanTypeAnnotation';
688
+ }
689
+
690
+ function isBreakStatement(node
691
+ /*: ESNode | Token */
692
+ )
693
+ /*: implies node is BreakStatement */
694
+ {
695
+ return node.type === 'BreakStatement';
696
+ }
697
+
698
+ function isCallExpression(node
699
+ /*: ESNode | Token */
700
+ )
701
+ /*: implies node is CallExpression */
702
+ {
703
+ return node.type === 'CallExpression';
704
+ }
705
+
706
+ function isCatchClause(node
707
+ /*: ESNode | Token */
708
+ )
709
+ /*: implies node is CatchClause */
710
+ {
711
+ return node.type === 'CatchClause';
712
+ }
713
+
714
+ function isChainExpression(node
715
+ /*: ESNode | Token */
716
+ )
717
+ /*: implies node is ChainExpression */
718
+ {
719
+ return node.type === 'ChainExpression';
720
+ }
721
+
722
+ function isClassBody(node
723
+ /*: ESNode | Token */
724
+ )
725
+ /*: implies node is ClassBody */
726
+ {
727
+ return node.type === 'ClassBody';
728
+ }
729
+
730
+ function isClassDeclaration(node
731
+ /*: ESNode | Token */
732
+ )
733
+ /*: implies node is ClassDeclaration */
734
+ {
735
+ return node.type === 'ClassDeclaration';
736
+ }
737
+
738
+ function isClassExpression(node
739
+ /*: ESNode | Token */
740
+ )
741
+ /*: implies node is ClassExpression */
742
+ {
743
+ return node.type === 'ClassExpression';
744
+ }
745
+
746
+ function isClassImplements(node
747
+ /*: ESNode | Token */
748
+ )
749
+ /*: implies node is ClassImplements */
750
+ {
751
+ return node.type === 'ClassImplements';
752
+ }
753
+
754
+ function isComponentDeclaration(node
755
+ /*: ESNode | Token */
756
+ )
757
+ /*: implies node is ComponentDeclaration */
758
+ {
759
+ return node.type === 'ComponentDeclaration';
760
+ }
761
+
762
+ function isComponentParameter(node
763
+ /*: ESNode | Token */
764
+ )
765
+ /*: implies node is ComponentParameter */
766
+ {
767
+ return node.type === 'ComponentParameter';
768
+ }
769
+
770
+ function isComponentTypeAnnotation(node
771
+ /*: ESNode | Token */
772
+ )
773
+ /*: implies node is ComponentTypeAnnotation */
774
+ {
775
+ return node.type === 'ComponentTypeAnnotation';
776
+ }
777
+
778
+ function isComponentTypeParameter(node
779
+ /*: ESNode | Token */
780
+ )
781
+ /*: implies node is ComponentTypeParameter */
782
+ {
783
+ return node.type === 'ComponentTypeParameter';
784
+ }
785
+
786
+ function isConditionalExpression(node
787
+ /*: ESNode | Token */
788
+ )
789
+ /*: implies node is ConditionalExpression */
790
+ {
791
+ return node.type === 'ConditionalExpression';
792
+ }
793
+
794
+ function isConditionalTypeAnnotation(node
795
+ /*: ESNode | Token */
796
+ )
797
+ /*: implies node is ConditionalTypeAnnotation */
798
+ {
799
+ return node.type === 'ConditionalTypeAnnotation';
800
+ }
801
+
802
+ function isContinueStatement(node
803
+ /*: ESNode | Token */
804
+ )
805
+ /*: implies node is ContinueStatement */
806
+ {
807
+ return node.type === 'ContinueStatement';
808
+ }
809
+
810
+ function isDebuggerStatement(node
811
+ /*: ESNode | Token */
812
+ )
813
+ /*: implies node is DebuggerStatement */
814
+ {
815
+ return node.type === 'DebuggerStatement';
816
+ }
817
+
818
+ function isDeclareClass(node
819
+ /*: ESNode | Token */
820
+ )
821
+ /*: implies node is DeclareClass */
822
+ {
823
+ return node.type === 'DeclareClass';
824
+ }
825
+
826
+ function isDeclareComponent(node
827
+ /*: ESNode | Token */
828
+ )
829
+ /*: implies node is DeclareComponent */
830
+ {
831
+ return node.type === 'DeclareComponent';
832
+ }
833
+
834
+ function isDeclaredPredicate(node
835
+ /*: ESNode | Token */
836
+ )
837
+ /*: implies node is DeclaredPredicate */
838
+ {
839
+ return node.type === 'DeclaredPredicate';
840
+ }
841
+
842
+ function isDeclareEnum(node
843
+ /*: ESNode | Token */
844
+ )
845
+ /*: implies node is DeclareEnum */
846
+ {
847
+ return node.type === 'DeclareEnum';
848
+ }
849
+
850
+ function isDeclareExportAllDeclaration(node
851
+ /*: ESNode | Token */
852
+ )
853
+ /*: implies node is DeclareExportAllDeclaration */
854
+ {
855
+ return node.type === 'DeclareExportAllDeclaration';
856
+ }
857
+
858
+ function isDeclareExportDeclaration(node
859
+ /*: ESNode | Token */
860
+ )
861
+ /*: implies node is DeclareExportDeclaration */
862
+ {
863
+ return node.type === 'DeclareExportDeclaration';
864
+ }
865
+
866
+ function isDeclareFunction(node
867
+ /*: ESNode | Token */
868
+ )
869
+ /*: implies node is DeclareFunction */
870
+ {
871
+ return node.type === 'DeclareFunction';
872
+ }
873
+
874
+ function isDeclareHook(node
875
+ /*: ESNode | Token */
876
+ )
877
+ /*: implies node is DeclareHook */
878
+ {
879
+ return node.type === 'DeclareHook';
880
+ }
881
+
882
+ function isDeclareInterface(node
883
+ /*: ESNode | Token */
884
+ )
885
+ /*: implies node is DeclareInterface */
886
+ {
887
+ return node.type === 'DeclareInterface';
888
+ }
889
+
890
+ function isDeclareModule(node
891
+ /*: ESNode | Token */
892
+ )
893
+ /*: implies node is DeclareModule */
894
+ {
895
+ return node.type === 'DeclareModule';
896
+ }
897
+
898
+ function isDeclareModuleExports(node
899
+ /*: ESNode | Token */
900
+ )
901
+ /*: implies node is DeclareModuleExports */
902
+ {
903
+ return node.type === 'DeclareModuleExports';
904
+ }
905
+
906
+ function isDeclareNamespace(node
907
+ /*: ESNode | Token */
908
+ )
909
+ /*: implies node is DeclareNamespace */
910
+ {
911
+ return node.type === 'DeclareNamespace';
912
+ }
913
+
914
+ function isDeclareOpaqueType(node
915
+ /*: ESNode | Token */
916
+ )
917
+ /*: implies node is DeclareOpaqueType */
918
+ {
919
+ return node.type === 'DeclareOpaqueType';
920
+ }
921
+
922
+ function isDeclareTypeAlias(node
923
+ /*: ESNode | Token */
924
+ )
925
+ /*: implies node is DeclareTypeAlias */
926
+ {
927
+ return node.type === 'DeclareTypeAlias';
928
+ }
929
+
930
+ function isDeclareVariable(node
931
+ /*: ESNode | Token */
932
+ )
933
+ /*: implies node is DeclareVariable */
934
+ {
935
+ return node.type === 'DeclareVariable';
936
+ }
937
+
938
+ function isDoWhileStatement(node
939
+ /*: ESNode | Token */
940
+ )
941
+ /*: implies node is DoWhileStatement */
942
+ {
943
+ return node.type === 'DoWhileStatement';
944
+ }
945
+
946
+ function isEmptyStatement(node
947
+ /*: ESNode | Token */
948
+ )
949
+ /*: implies node is EmptyStatement */
950
+ {
951
+ return node.type === 'EmptyStatement';
952
+ }
953
+
954
+ function isEmptyTypeAnnotation(node
955
+ /*: ESNode | Token */
956
+ )
957
+ /*: implies node is EmptyTypeAnnotation */
958
+ {
959
+ return node.type === 'EmptyTypeAnnotation';
960
+ }
961
+
962
+ function isEnumBigIntBody(node
963
+ /*: ESNode | Token */
964
+ )
965
+ /*: implies node is EnumBigIntBody */
966
+ {
967
+ return node.type === 'EnumBigIntBody';
968
+ }
969
+
970
+ function isEnumBigIntMember(node
971
+ /*: ESNode | Token */
972
+ )
973
+ /*: implies node is EnumBigIntMember */
974
+ {
975
+ return node.type === 'EnumBigIntMember';
976
+ }
977
+
978
+ function isEnumBooleanBody(node
979
+ /*: ESNode | Token */
980
+ )
981
+ /*: implies node is EnumBooleanBody */
982
+ {
983
+ return node.type === 'EnumBooleanBody';
984
+ }
985
+
986
+ function isEnumBooleanMember(node
987
+ /*: ESNode | Token */
988
+ )
989
+ /*: implies node is EnumBooleanMember */
990
+ {
991
+ return node.type === 'EnumBooleanMember';
992
+ }
993
+
994
+ function isEnumDeclaration(node
995
+ /*: ESNode | Token */
996
+ )
997
+ /*: implies node is EnumDeclaration */
998
+ {
999
+ return node.type === 'EnumDeclaration';
1000
+ }
1001
+
1002
+ function isEnumDefaultedMember(node
1003
+ /*: ESNode | Token */
1004
+ )
1005
+ /*: implies node is EnumDefaultedMember */
1006
+ {
1007
+ return node.type === 'EnumDefaultedMember';
1008
+ }
1009
+
1010
+ function isEnumNumberBody(node
1011
+ /*: ESNode | Token */
1012
+ )
1013
+ /*: implies node is EnumNumberBody */
1014
+ {
1015
+ return node.type === 'EnumNumberBody';
1016
+ }
1017
+
1018
+ function isEnumNumberMember(node
1019
+ /*: ESNode | Token */
1020
+ )
1021
+ /*: implies node is EnumNumberMember */
1022
+ {
1023
+ return node.type === 'EnumNumberMember';
1024
+ }
1025
+
1026
+ function isEnumStringBody(node
1027
+ /*: ESNode | Token */
1028
+ )
1029
+ /*: implies node is EnumStringBody */
1030
+ {
1031
+ return node.type === 'EnumStringBody';
1032
+ }
1033
+
1034
+ function isEnumStringMember(node
1035
+ /*: ESNode | Token */
1036
+ )
1037
+ /*: implies node is EnumStringMember */
1038
+ {
1039
+ return node.type === 'EnumStringMember';
1040
+ }
1041
+
1042
+ function isEnumSymbolBody(node
1043
+ /*: ESNode | Token */
1044
+ )
1045
+ /*: implies node is EnumSymbolBody */
1046
+ {
1047
+ return node.type === 'EnumSymbolBody';
1048
+ }
1049
+
1050
+ function isExistsTypeAnnotation(node
1051
+ /*: ESNode | Token */
1052
+ )
1053
+ /*: implies node is ExistsTypeAnnotation */
1054
+ {
1055
+ return node.type === 'ExistsTypeAnnotation';
1056
+ }
1057
+
1058
+ function isExportAllDeclaration(node
1059
+ /*: ESNode | Token */
1060
+ )
1061
+ /*: implies node is ExportAllDeclaration */
1062
+ {
1063
+ return node.type === 'ExportAllDeclaration';
1064
+ }
1065
+
1066
+ function isExportDefaultDeclaration(node
1067
+ /*: ESNode | Token */
1068
+ )
1069
+ /*: implies node is ExportDefaultDeclaration */
1070
+ {
1071
+ return node.type === 'ExportDefaultDeclaration';
1072
+ }
1073
+
1074
+ function isExportNamedDeclaration(node
1075
+ /*: ESNode | Token */
1076
+ )
1077
+ /*: implies node is ExportNamedDeclaration */
1078
+ {
1079
+ return node.type === 'ExportNamedDeclaration';
1080
+ }
1081
+
1082
+ function isExportSpecifier(node
1083
+ /*: ESNode | Token */
1084
+ )
1085
+ /*: implies node is ExportSpecifier */
1086
+ {
1087
+ return node.type === 'ExportSpecifier';
1088
+ }
1089
+
1090
+ function isExpressionStatement(node
1091
+ /*: ESNode | Token */
1092
+ )
1093
+ /*: implies node is ExpressionStatement */
1094
+ {
1095
+ return node.type === 'ExpressionStatement';
1096
+ }
1097
+
1098
+ function isForInStatement(node
1099
+ /*: ESNode | Token */
1100
+ )
1101
+ /*: implies node is ForInStatement */
1102
+ {
1103
+ return node.type === 'ForInStatement';
1104
+ }
1105
+
1106
+ function isForOfStatement(node
1107
+ /*: ESNode | Token */
1108
+ )
1109
+ /*: implies node is ForOfStatement */
1110
+ {
1111
+ return node.type === 'ForOfStatement';
1112
+ }
1113
+
1114
+ function isForStatement(node
1115
+ /*: ESNode | Token */
1116
+ )
1117
+ /*: implies node is ForStatement */
1118
+ {
1119
+ return node.type === 'ForStatement';
1120
+ }
1121
+
1122
+ function isFunctionDeclaration(node
1123
+ /*: ESNode | Token */
1124
+ )
1125
+ /*: implies node is FunctionDeclaration */
1126
+ {
1127
+ return node.type === 'FunctionDeclaration';
1128
+ }
1129
+
1130
+ function isFunctionExpression(node
1131
+ /*: ESNode | Token */
1132
+ )
1133
+ /*: implies node is FunctionExpression */
1134
+ {
1135
+ return node.type === 'FunctionExpression';
1136
+ }
1137
+
1138
+ function isFunctionTypeAnnotation(node
1139
+ /*: ESNode | Token */
1140
+ )
1141
+ /*: implies node is FunctionTypeAnnotation */
1142
+ {
1143
+ return node.type === 'FunctionTypeAnnotation';
1144
+ }
1145
+
1146
+ function isFunctionTypeParam(node
1147
+ /*: ESNode | Token */
1148
+ )
1149
+ /*: implies node is FunctionTypeParam */
1150
+ {
1151
+ return node.type === 'FunctionTypeParam';
1152
+ }
1153
+
1154
+ function isGenericTypeAnnotation(node
1155
+ /*: ESNode | Token */
1156
+ )
1157
+ /*: implies node is GenericTypeAnnotation */
1158
+ {
1159
+ return node.type === 'GenericTypeAnnotation';
1160
+ }
1161
+
1162
+ function isHookDeclaration(node
1163
+ /*: ESNode | Token */
1164
+ )
1165
+ /*: implies node is HookDeclaration */
1166
+ {
1167
+ return node.type === 'HookDeclaration';
1168
+ }
1169
+
1170
+ function isHookTypeAnnotation(node
1171
+ /*: ESNode | Token */
1172
+ )
1173
+ /*: implies node is HookTypeAnnotation */
1174
+ {
1175
+ return node.type === 'HookTypeAnnotation';
1176
+ }
1177
+
1178
+ function isIfStatement(node
1179
+ /*: ESNode | Token */
1180
+ )
1181
+ /*: implies node is IfStatement */
1182
+ {
1183
+ return node.type === 'IfStatement';
1184
+ }
1185
+
1186
+ function isImportAttribute(node
1187
+ /*: ESNode | Token */
1188
+ )
1189
+ /*: implies node is ImportAttribute */
1190
+ {
1191
+ return node.type === 'ImportAttribute';
1192
+ }
1193
+
1194
+ function isImportDeclaration(node
1195
+ /*: ESNode | Token */
1196
+ )
1197
+ /*: implies node is ImportDeclaration */
1198
+ {
1199
+ return node.type === 'ImportDeclaration';
1200
+ }
1201
+
1202
+ function isImportDefaultSpecifier(node
1203
+ /*: ESNode | Token */
1204
+ )
1205
+ /*: implies node is ImportDefaultSpecifier */
1206
+ {
1207
+ return node.type === 'ImportDefaultSpecifier';
1208
+ }
1209
+
1210
+ function isImportExpression(node
1211
+ /*: ESNode | Token */
1212
+ )
1213
+ /*: implies node is ImportExpression */
1214
+ {
1215
+ return node.type === 'ImportExpression';
1216
+ }
1217
+
1218
+ function isImportNamespaceSpecifier(node
1219
+ /*: ESNode | Token */
1220
+ )
1221
+ /*: implies node is ImportNamespaceSpecifier */
1222
+ {
1223
+ return node.type === 'ImportNamespaceSpecifier';
1224
+ }
1225
+
1226
+ function isImportSpecifier(node
1227
+ /*: ESNode | Token */
1228
+ )
1229
+ /*: implies node is ImportSpecifier */
1230
+ {
1231
+ return node.type === 'ImportSpecifier';
1232
+ }
1233
+
1234
+ function isIndexedAccessType(node
1235
+ /*: ESNode | Token */
1236
+ )
1237
+ /*: implies node is IndexedAccessType */
1238
+ {
1239
+ return node.type === 'IndexedAccessType';
1240
+ }
1241
+
1242
+ function isInferredPredicate(node
1243
+ /*: ESNode | Token */
1244
+ )
1245
+ /*: implies node is InferredPredicate */
1246
+ {
1247
+ return node.type === 'InferredPredicate';
1248
+ }
1249
+
1250
+ function isInferTypeAnnotation(node
1251
+ /*: ESNode | Token */
1252
+ )
1253
+ /*: implies node is InferTypeAnnotation */
1254
+ {
1255
+ return node.type === 'InferTypeAnnotation';
1256
+ }
1257
+
1258
+ function isInterfaceDeclaration(node
1259
+ /*: ESNode | Token */
1260
+ )
1261
+ /*: implies node is InterfaceDeclaration */
1262
+ {
1263
+ return node.type === 'InterfaceDeclaration';
1264
+ }
1265
+
1266
+ function isInterfaceExtends(node
1267
+ /*: ESNode | Token */
1268
+ )
1269
+ /*: implies node is InterfaceExtends */
1270
+ {
1271
+ return node.type === 'InterfaceExtends';
1272
+ }
1273
+
1274
+ function isInterfaceTypeAnnotation(node
1275
+ /*: ESNode | Token */
1276
+ )
1277
+ /*: implies node is InterfaceTypeAnnotation */
1278
+ {
1279
+ return node.type === 'InterfaceTypeAnnotation';
1280
+ }
1281
+
1282
+ function isIntersectionTypeAnnotation(node
1283
+ /*: ESNode | Token */
1284
+ )
1285
+ /*: implies node is IntersectionTypeAnnotation */
1286
+ {
1287
+ return node.type === 'IntersectionTypeAnnotation';
1288
+ }
1289
+
1290
+ function isJSXAttribute(node
1291
+ /*: ESNode | Token */
1292
+ )
1293
+ /*: implies node is JSXAttribute */
1294
+ {
1295
+ return node.type === 'JSXAttribute';
1296
+ }
1297
+
1298
+ function isJSXClosingElement(node
1299
+ /*: ESNode | Token */
1300
+ )
1301
+ /*: implies node is JSXClosingElement */
1302
+ {
1303
+ return node.type === 'JSXClosingElement';
1304
+ }
1305
+
1306
+ function isJSXClosingFragment(node
1307
+ /*: ESNode | Token */
1308
+ )
1309
+ /*: implies node is JSXClosingFragment */
1310
+ {
1311
+ return node.type === 'JSXClosingFragment';
1312
+ }
1313
+
1314
+ function isJSXElement(node
1315
+ /*: ESNode | Token */
1316
+ )
1317
+ /*: implies node is JSXElement */
1318
+ {
1319
+ return node.type === 'JSXElement';
1320
+ }
1321
+
1322
+ function isJSXEmptyExpression(node
1323
+ /*: ESNode | Token */
1324
+ )
1325
+ /*: implies node is JSXEmptyExpression */
1326
+ {
1327
+ return node.type === 'JSXEmptyExpression';
1328
+ }
1329
+
1330
+ function isJSXExpressionContainer(node
1331
+ /*: ESNode | Token */
1332
+ )
1333
+ /*: implies node is JSXExpressionContainer */
1334
+ {
1335
+ return node.type === 'JSXExpressionContainer';
1336
+ }
1337
+
1338
+ function isJSXFragment(node
1339
+ /*: ESNode | Token */
1340
+ )
1341
+ /*: implies node is JSXFragment */
1342
+ {
1343
+ return node.type === 'JSXFragment';
1344
+ }
1345
+
1346
+ function isJSXMemberExpression(node
1347
+ /*: ESNode | Token */
1348
+ )
1349
+ /*: implies node is JSXMemberExpression */
1350
+ {
1351
+ return node.type === 'JSXMemberExpression';
1352
+ }
1353
+
1354
+ function isJSXNamespacedName(node
1355
+ /*: ESNode | Token */
1356
+ )
1357
+ /*: implies node is JSXNamespacedName */
1358
+ {
1359
+ return node.type === 'JSXNamespacedName';
1360
+ }
1361
+
1362
+ function isJSXOpeningElement(node
1363
+ /*: ESNode | Token */
1364
+ )
1365
+ /*: implies node is JSXOpeningElement */
1366
+ {
1367
+ return node.type === 'JSXOpeningElement';
1368
+ }
1369
+
1370
+ function isJSXOpeningFragment(node
1371
+ /*: ESNode | Token */
1372
+ )
1373
+ /*: implies node is JSXOpeningFragment */
1374
+ {
1375
+ return node.type === 'JSXOpeningFragment';
1376
+ }
1377
+
1378
+ function isJSXSpreadAttribute(node
1379
+ /*: ESNode | Token */
1380
+ )
1381
+ /*: implies node is JSXSpreadAttribute */
1382
+ {
1383
+ return node.type === 'JSXSpreadAttribute';
1384
+ }
1385
+
1386
+ function isJSXSpreadChild(node
1387
+ /*: ESNode | Token */
1388
+ )
1389
+ /*: implies node is JSXSpreadChild */
1390
+ {
1391
+ return node.type === 'JSXSpreadChild';
1392
+ }
1393
+
1394
+ function isKeyofTypeAnnotation(node
1395
+ /*: ESNode | Token */
1396
+ )
1397
+ /*: implies node is KeyofTypeAnnotation */
1398
+ {
1399
+ return node.type === 'KeyofTypeAnnotation';
1400
+ }
1401
+
1402
+ function isLabeledStatement(node
1403
+ /*: ESNode | Token */
1404
+ )
1405
+ /*: implies node is LabeledStatement */
1406
+ {
1407
+ return node.type === 'LabeledStatement';
1408
+ }
1409
+
1410
+ function isLogicalExpression(node
1411
+ /*: ESNode | Token */
1412
+ )
1413
+ /*: implies node is LogicalExpression */
1414
+ {
1415
+ return node.type === 'LogicalExpression';
1416
+ }
1417
+
1418
+ function isMatchArrayPattern(node
1419
+ /*: ESNode | Token */
1420
+ )
1421
+ /*: implies node is MatchArrayPattern */
1422
+ {
1423
+ return node.type === 'MatchArrayPattern';
1424
+ }
1425
+
1426
+ function isMatchAsPattern(node
1427
+ /*: ESNode | Token */
1428
+ )
1429
+ /*: implies node is MatchAsPattern */
1430
+ {
1431
+ return node.type === 'MatchAsPattern';
1432
+ }
1433
+
1434
+ function isMatchBindingPattern(node
1435
+ /*: ESNode | Token */
1436
+ )
1437
+ /*: implies node is MatchBindingPattern */
1438
+ {
1439
+ return node.type === 'MatchBindingPattern';
1440
+ }
1441
+
1442
+ function isMatchExpression(node
1443
+ /*: ESNode | Token */
1444
+ )
1445
+ /*: implies node is MatchExpression */
1446
+ {
1447
+ return node.type === 'MatchExpression';
1448
+ }
1449
+
1450
+ function isMatchExpressionCase(node
1451
+ /*: ESNode | Token */
1452
+ )
1453
+ /*: implies node is MatchExpressionCase */
1454
+ {
1455
+ return node.type === 'MatchExpressionCase';
1456
+ }
1457
+
1458
+ function isMatchIdentifierPattern(node
1459
+ /*: ESNode | Token */
1460
+ )
1461
+ /*: implies node is MatchIdentifierPattern */
1462
+ {
1463
+ return node.type === 'MatchIdentifierPattern';
1464
+ }
1465
+
1466
+ function isMatchLiteralPattern(node
1467
+ /*: ESNode | Token */
1468
+ )
1469
+ /*: implies node is MatchLiteralPattern */
1470
+ {
1471
+ return node.type === 'MatchLiteralPattern';
1472
+ }
1473
+
1474
+ function isMatchMemberPattern(node
1475
+ /*: ESNode | Token */
1476
+ )
1477
+ /*: implies node is MatchMemberPattern */
1478
+ {
1479
+ return node.type === 'MatchMemberPattern';
1480
+ }
1481
+
1482
+ function isMatchObjectPattern(node
1483
+ /*: ESNode | Token */
1484
+ )
1485
+ /*: implies node is MatchObjectPattern */
1486
+ {
1487
+ return node.type === 'MatchObjectPattern';
1488
+ }
1489
+
1490
+ function isMatchObjectPatternProperty(node
1491
+ /*: ESNode | Token */
1492
+ )
1493
+ /*: implies node is MatchObjectPatternProperty */
1494
+ {
1495
+ return node.type === 'MatchObjectPatternProperty';
1496
+ }
1497
+
1498
+ function isMatchOrPattern(node
1499
+ /*: ESNode | Token */
1500
+ )
1501
+ /*: implies node is MatchOrPattern */
1502
+ {
1503
+ return node.type === 'MatchOrPattern';
1504
+ }
1505
+
1506
+ function isMatchRestPattern(node
1507
+ /*: ESNode | Token */
1508
+ )
1509
+ /*: implies node is MatchRestPattern */
1510
+ {
1511
+ return node.type === 'MatchRestPattern';
1512
+ }
1513
+
1514
+ function isMatchStatement(node
1515
+ /*: ESNode | Token */
1516
+ )
1517
+ /*: implies node is MatchStatement */
1518
+ {
1519
+ return node.type === 'MatchStatement';
1520
+ }
1521
+
1522
+ function isMatchStatementCase(node
1523
+ /*: ESNode | Token */
1524
+ )
1525
+ /*: implies node is MatchStatementCase */
1526
+ {
1527
+ return node.type === 'MatchStatementCase';
1528
+ }
1529
+
1530
+ function isMatchUnaryPattern(node
1531
+ /*: ESNode | Token */
1532
+ )
1533
+ /*: implies node is MatchUnaryPattern */
1534
+ {
1535
+ return node.type === 'MatchUnaryPattern';
1536
+ }
1537
+
1538
+ function isMatchWildcardPattern(node
1539
+ /*: ESNode | Token */
1540
+ )
1541
+ /*: implies node is MatchWildcardPattern */
1542
+ {
1543
+ return node.type === 'MatchWildcardPattern';
1544
+ }
1545
+
1546
+ function isMemberExpression(node
1547
+ /*: ESNode | Token */
1548
+ )
1549
+ /*: implies node is MemberExpression */
1550
+ {
1551
+ return node.type === 'MemberExpression';
1552
+ }
1553
+
1554
+ function isMetaProperty(node
1555
+ /*: ESNode | Token */
1556
+ )
1557
+ /*: implies node is MetaProperty */
1558
+ {
1559
+ return node.type === 'MetaProperty';
1560
+ }
1561
+
1562
+ function isMethodDefinition(node
1563
+ /*: ESNode | Token */
1564
+ )
1565
+ /*: implies node is MethodDefinition */
1566
+ {
1567
+ return node.type === 'MethodDefinition';
1568
+ }
1569
+
1570
+ function isMixedTypeAnnotation(node
1571
+ /*: ESNode | Token */
1572
+ )
1573
+ /*: implies node is MixedTypeAnnotation */
1574
+ {
1575
+ return node.type === 'MixedTypeAnnotation';
1576
+ }
1577
+
1578
+ function isNewExpression(node
1579
+ /*: ESNode | Token */
1580
+ )
1581
+ /*: implies node is NewExpression */
1582
+ {
1583
+ return node.type === 'NewExpression';
1584
+ }
1585
+
1586
+ function isNullableTypeAnnotation(node
1587
+ /*: ESNode | Token */
1588
+ )
1589
+ /*: implies node is NullableTypeAnnotation */
1590
+ {
1591
+ return node.type === 'NullableTypeAnnotation';
1592
+ }
1593
+
1594
+ function isNullLiteralTypeAnnotation(node
1595
+ /*: ESNode | Token */
1596
+ )
1597
+ /*: implies node is NullLiteralTypeAnnotation */
1598
+ {
1599
+ return node.type === 'NullLiteralTypeAnnotation';
1600
+ }
1601
+
1602
+ function isNumberLiteralTypeAnnotation(node
1603
+ /*: ESNode | Token */
1604
+ )
1605
+ /*: implies node is NumberLiteralTypeAnnotation */
1606
+ {
1607
+ return node.type === 'NumberLiteralTypeAnnotation';
1608
+ }
1609
+
1610
+ function isNumberTypeAnnotation(node
1611
+ /*: ESNode | Token */
1612
+ )
1613
+ /*: implies node is NumberTypeAnnotation */
1614
+ {
1615
+ return node.type === 'NumberTypeAnnotation';
1616
+ }
1617
+
1618
+ function isObjectExpression(node
1619
+ /*: ESNode | Token */
1620
+ )
1621
+ /*: implies node is ObjectExpression */
1622
+ {
1623
+ return node.type === 'ObjectExpression';
1624
+ }
1625
+
1626
+ function isObjectPattern(node
1627
+ /*: ESNode | Token */
1628
+ )
1629
+ /*: implies node is ObjectPattern */
1630
+ {
1631
+ return node.type === 'ObjectPattern';
1632
+ }
1633
+
1634
+ function isObjectTypeAnnotation(node
1635
+ /*: ESNode | Token */
1636
+ )
1637
+ /*: implies node is ObjectTypeAnnotation */
1638
+ {
1639
+ return node.type === 'ObjectTypeAnnotation';
1640
+ }
1641
+
1642
+ function isObjectTypeCallProperty(node
1643
+ /*: ESNode | Token */
1644
+ )
1645
+ /*: implies node is ObjectTypeCallProperty */
1646
+ {
1647
+ return node.type === 'ObjectTypeCallProperty';
1648
+ }
1649
+
1650
+ function isObjectTypeIndexer(node
1651
+ /*: ESNode | Token */
1652
+ )
1653
+ /*: implies node is ObjectTypeIndexer */
1654
+ {
1655
+ return node.type === 'ObjectTypeIndexer';
1656
+ }
1657
+
1658
+ function isObjectTypeInternalSlot(node
1659
+ /*: ESNode | Token */
1660
+ )
1661
+ /*: implies node is ObjectTypeInternalSlot */
1662
+ {
1663
+ return node.type === 'ObjectTypeInternalSlot';
1664
+ }
1665
+
1666
+ function isObjectTypeMappedTypeProperty(node
1667
+ /*: ESNode | Token */
1668
+ )
1669
+ /*: implies node is ObjectTypeMappedTypeProperty */
1670
+ {
1671
+ return node.type === 'ObjectTypeMappedTypeProperty';
1672
+ }
1673
+
1674
+ function isObjectTypeProperty(node
1675
+ /*: ESNode | Token */
1676
+ )
1677
+ /*: implies node is ObjectTypeProperty */
1678
+ {
1679
+ return node.type === 'ObjectTypeProperty';
1680
+ }
1681
+
1682
+ function isObjectTypeSpreadProperty(node
1683
+ /*: ESNode | Token */
1684
+ )
1685
+ /*: implies node is ObjectTypeSpreadProperty */
1686
+ {
1687
+ return node.type === 'ObjectTypeSpreadProperty';
1688
+ }
1689
+
1690
+ function isOpaqueType(node
1691
+ /*: ESNode | Token */
1692
+ )
1693
+ /*: implies node is OpaqueType */
1694
+ {
1695
+ return node.type === 'OpaqueType';
1696
+ }
1697
+
1698
+ function isOptionalIndexedAccessType(node
1699
+ /*: ESNode | Token */
1700
+ )
1701
+ /*: implies node is OptionalIndexedAccessType */
1702
+ {
1703
+ return node.type === 'OptionalIndexedAccessType';
1704
+ }
1705
+
1706
+ function isPrivateIdentifier(node
1707
+ /*: ESNode | Token */
1708
+ )
1709
+ /*: implies node is PrivateIdentifier */
1710
+ {
1711
+ return node.type === 'PrivateIdentifier';
1712
+ }
1713
+
1714
+ function isProgram(node
1715
+ /*: ESNode | Token */
1716
+ )
1717
+ /*: implies node is Program */
1718
+ {
1719
+ return node.type === 'Program';
1720
+ }
1721
+
1722
+ function isProperty(node
1723
+ /*: ESNode | Token */
1724
+ )
1725
+ /*: implies node is Property */
1726
+ {
1727
+ return node.type === 'Property';
1728
+ }
1729
+
1730
+ function isPropertyDefinition(node
1731
+ /*: ESNode | Token */
1732
+ )
1733
+ /*: implies node is PropertyDefinition */
1734
+ {
1735
+ return node.type === 'PropertyDefinition';
1736
+ }
1737
+
1738
+ function isQualifiedTypeIdentifier(node
1739
+ /*: ESNode | Token */
1740
+ )
1741
+ /*: implies node is QualifiedTypeIdentifier */
1742
+ {
1743
+ return node.type === 'QualifiedTypeIdentifier';
1744
+ }
1745
+
1746
+ function isQualifiedTypeofIdentifier(node
1747
+ /*: ESNode | Token */
1748
+ )
1749
+ /*: implies node is QualifiedTypeofIdentifier */
1750
+ {
1751
+ return node.type === 'QualifiedTypeofIdentifier';
1752
+ }
1753
+
1754
+ function isRestElement(node
1755
+ /*: ESNode | Token */
1756
+ )
1757
+ /*: implies node is RestElement */
1758
+ {
1759
+ return node.type === 'RestElement';
1760
+ }
1761
+
1762
+ function isReturnStatement(node
1763
+ /*: ESNode | Token */
1764
+ )
1765
+ /*: implies node is ReturnStatement */
1766
+ {
1767
+ return node.type === 'ReturnStatement';
1768
+ }
1769
+
1770
+ function isSequenceExpression(node
1771
+ /*: ESNode | Token */
1772
+ )
1773
+ /*: implies node is SequenceExpression */
1774
+ {
1775
+ return node.type === 'SequenceExpression';
1776
+ }
1777
+
1778
+ function isSpreadElement(node
1779
+ /*: ESNode | Token */
1780
+ )
1781
+ /*: implies node is SpreadElement */
1782
+ {
1783
+ return node.type === 'SpreadElement';
1784
+ }
1785
+
1786
+ function isStaticBlock(node
1787
+ /*: ESNode | Token */
1788
+ )
1789
+ /*: implies node is StaticBlock */
1790
+ {
1791
+ return node.type === 'StaticBlock';
1792
+ }
1793
+
1794
+ function isStringLiteralTypeAnnotation(node
1795
+ /*: ESNode | Token */
1796
+ )
1797
+ /*: implies node is StringLiteralTypeAnnotation */
1798
+ {
1799
+ return node.type === 'StringLiteralTypeAnnotation';
1800
+ }
1801
+
1802
+ function isStringTypeAnnotation(node
1803
+ /*: ESNode | Token */
1804
+ )
1805
+ /*: implies node is StringTypeAnnotation */
1806
+ {
1807
+ return node.type === 'StringTypeAnnotation';
1808
+ }
1809
+
1810
+ function isSuper(node
1811
+ /*: ESNode | Token */
1812
+ )
1813
+ /*: implies node is Super */
1814
+ {
1815
+ return node.type === 'Super';
1816
+ }
1817
+
1818
+ function isSwitchCase(node
1819
+ /*: ESNode | Token */
1820
+ )
1821
+ /*: implies node is SwitchCase */
1822
+ {
1823
+ return node.type === 'SwitchCase';
1824
+ }
1825
+
1826
+ function isSwitchStatement(node
1827
+ /*: ESNode | Token */
1828
+ )
1829
+ /*: implies node is SwitchStatement */
1830
+ {
1831
+ return node.type === 'SwitchStatement';
1832
+ }
1833
+
1834
+ function isSymbolTypeAnnotation(node
1835
+ /*: ESNode | Token */
1836
+ )
1837
+ /*: implies node is SymbolTypeAnnotation */
1838
+ {
1839
+ return node.type === 'SymbolTypeAnnotation';
1840
+ }
1841
+
1842
+ function isTaggedTemplateExpression(node
1843
+ /*: ESNode | Token */
1844
+ )
1845
+ /*: implies node is TaggedTemplateExpression */
1846
+ {
1847
+ return node.type === 'TaggedTemplateExpression';
1848
+ }
1849
+
1850
+ function isTemplateElement(node
1851
+ /*: ESNode | Token */
1852
+ )
1853
+ /*: implies node is TemplateElement */
1854
+ {
1855
+ return node.type === 'TemplateElement';
1856
+ }
1857
+
1858
+ function isTemplateLiteral(node
1859
+ /*: ESNode | Token */
1860
+ )
1861
+ /*: implies node is TemplateLiteral */
1862
+ {
1863
+ return node.type === 'TemplateLiteral';
1864
+ }
1865
+
1866
+ function isThisExpression(node
1867
+ /*: ESNode | Token */
1868
+ )
1869
+ /*: implies node is ThisExpression */
1870
+ {
1871
+ return node.type === 'ThisExpression';
1872
+ }
1873
+
1874
+ function isThisTypeAnnotation(node
1875
+ /*: ESNode | Token */
1876
+ )
1877
+ /*: implies node is ThisTypeAnnotation */
1878
+ {
1879
+ return node.type === 'ThisTypeAnnotation';
1880
+ }
1881
+
1882
+ function isThrowStatement(node
1883
+ /*: ESNode | Token */
1884
+ )
1885
+ /*: implies node is ThrowStatement */
1886
+ {
1887
+ return node.type === 'ThrowStatement';
1888
+ }
1889
+
1890
+ function isTryStatement(node
1891
+ /*: ESNode | Token */
1892
+ )
1893
+ /*: implies node is TryStatement */
1894
+ {
1895
+ return node.type === 'TryStatement';
1896
+ }
1897
+
1898
+ function isTupleTypeAnnotation(node
1899
+ /*: ESNode | Token */
1900
+ )
1901
+ /*: implies node is TupleTypeAnnotation */
1902
+ {
1903
+ return node.type === 'TupleTypeAnnotation';
1904
+ }
1905
+
1906
+ function isTupleTypeLabeledElement(node
1907
+ /*: ESNode | Token */
1908
+ )
1909
+ /*: implies node is TupleTypeLabeledElement */
1910
+ {
1911
+ return node.type === 'TupleTypeLabeledElement';
1912
+ }
1913
+
1914
+ function isTupleTypeSpreadElement(node
1915
+ /*: ESNode | Token */
1916
+ )
1917
+ /*: implies node is TupleTypeSpreadElement */
1918
+ {
1919
+ return node.type === 'TupleTypeSpreadElement';
1920
+ }
1921
+
1922
+ function isTypeAlias(node
1923
+ /*: ESNode | Token */
1924
+ )
1925
+ /*: implies node is TypeAlias */
1926
+ {
1927
+ return node.type === 'TypeAlias';
1928
+ }
1929
+
1930
+ function isTypeAnnotation(node
1931
+ /*: ESNode | Token */
1932
+ )
1933
+ /*: implies node is TypeAnnotation */
1934
+ {
1935
+ return node.type === 'TypeAnnotation';
1936
+ }
1937
+
1938
+ function isTypeCastExpression(node
1939
+ /*: ESNode | Token */
1940
+ )
1941
+ /*: implies node is TypeCastExpression */
1942
+ {
1943
+ return node.type === 'TypeCastExpression';
1944
+ }
1945
+
1946
+ function isTypeofTypeAnnotation(node
1947
+ /*: ESNode | Token */
1948
+ )
1949
+ /*: implies node is TypeofTypeAnnotation */
1950
+ {
1951
+ return node.type === 'TypeofTypeAnnotation';
1952
+ }
1953
+
1954
+ function isTypeOperator(node
1955
+ /*: ESNode | Token */
1956
+ )
1957
+ /*: implies node is TypeOperator */
1958
+ {
1959
+ return node.type === 'TypeOperator';
1960
+ }
1961
+
1962
+ function isTypeParameter(node
1963
+ /*: ESNode | Token */
1964
+ )
1965
+ /*: implies node is TypeParameter */
1966
+ {
1967
+ return node.type === 'TypeParameter';
1968
+ }
1969
+
1970
+ function isTypeParameterDeclaration(node
1971
+ /*: ESNode | Token */
1972
+ )
1973
+ /*: implies node is TypeParameterDeclaration */
1974
+ {
1975
+ return node.type === 'TypeParameterDeclaration';
1976
+ }
1977
+
1978
+ function isTypeParameterInstantiation(node
1979
+ /*: ESNode | Token */
1980
+ )
1981
+ /*: implies node is TypeParameterInstantiation */
1982
+ {
1983
+ return node.type === 'TypeParameterInstantiation';
1984
+ }
1985
+
1986
+ function isTypePredicate(node
1987
+ /*: ESNode | Token */
1988
+ )
1989
+ /*: implies node is TypePredicate */
1990
+ {
1991
+ return node.type === 'TypePredicate';
1992
+ }
1993
+
1994
+ function isUnaryExpression(node
1995
+ /*: ESNode | Token */
1996
+ )
1997
+ /*: implies node is UnaryExpression */
1998
+ {
1999
+ return node.type === 'UnaryExpression';
2000
+ }
2001
+
2002
+ function isUnionTypeAnnotation(node
2003
+ /*: ESNode | Token */
2004
+ )
2005
+ /*: implies node is UnionTypeAnnotation */
2006
+ {
2007
+ return node.type === 'UnionTypeAnnotation';
2008
+ }
2009
+
2010
+ function isUpdateExpression(node
2011
+ /*: ESNode | Token */
2012
+ )
2013
+ /*: implies node is UpdateExpression */
2014
+ {
2015
+ return node.type === 'UpdateExpression';
2016
+ }
2017
+
2018
+ function isVariableDeclaration(node
2019
+ /*: ESNode | Token */
2020
+ )
2021
+ /*: implies node is VariableDeclaration */
2022
+ {
2023
+ return node.type === 'VariableDeclaration';
2024
+ }
2025
+
2026
+ function isVariableDeclarator(node
2027
+ /*: ESNode | Token */
2028
+ )
2029
+ /*: implies node is VariableDeclarator */
2030
+ {
2031
+ return node.type === 'VariableDeclarator';
2032
+ }
2033
+
2034
+ function isVariance(node
2035
+ /*: ESNode | Token */
2036
+ )
2037
+ /*: implies node is Variance */
2038
+ {
2039
+ return node.type === 'Variance';
2040
+ }
2041
+
2042
+ function isVoidTypeAnnotation(node
2043
+ /*: ESNode | Token */
2044
+ )
2045
+ /*: implies node is VoidTypeAnnotation */
2046
+ {
2047
+ return node.type === 'VoidTypeAnnotation';
2048
+ }
2049
+
2050
+ function isWhileStatement(node
2051
+ /*: ESNode | Token */
2052
+ )
2053
+ /*: implies node is WhileStatement */
2054
+ {
2055
+ return node.type === 'WhileStatement';
2056
+ }
2057
+
2058
+ function isWithStatement(node
2059
+ /*: ESNode | Token */
2060
+ )
2061
+ /*: implies node is WithStatement */
2062
+ {
2063
+ return node.type === 'WithStatement';
2064
+ }
2065
+
2066
+ function isYieldExpression(node
2067
+ /*: ESNode | Token */
2068
+ )
2069
+ /*: implies node is YieldExpression */
2070
+ {
2071
+ return node.type === 'YieldExpression';
2072
+ }
2073
+
2074
+ function isLiteral(node
2075
+ /*: ESNode | Token */
2076
+ )
2077
+ /*: implies node is Literal */
2078
+ {
2079
+ return node.type === 'Literal';
2080
+ }
2081
+
2082
+ function isLineComment(node
2083
+ /*: ESNode | Token */
2084
+ )
2085
+ /*: implies node is (MostTokens | LineComment) */
2086
+ {
2087
+ return node.type === 'Line';
2088
+ }
2089
+
2090
+ function isBlockComment(node
2091
+ /*: ESNode | Token */
2092
+ )
2093
+ /*: implies node is (MostTokens | BlockComment) */
2094
+ {
2095
+ return node.type === 'Block';
2096
+ }
2097
+
2098
+ function isMinusToken(node
2099
+ /*: ESNode | Token */
2100
+ )
2101
+ /*: implies node is MostTokens */
2102
+ {
2103
+ return node.type === 'Punctuator' && node.value === '-';
2104
+ }
2105
+
2106
+ function isPlusToken(node
2107
+ /*: ESNode | Token */
2108
+ )
2109
+ /*: implies node is MostTokens */
2110
+ {
2111
+ return node.type === 'Punctuator' && node.value === '+';
2112
+ }
2113
+
2114
+ function isLogicalNotToken(node
2115
+ /*: ESNode | Token */
2116
+ )
2117
+ /*: implies node is MostTokens */
2118
+ {
2119
+ return node.type === 'Punctuator' && node.value === '!';
2120
+ }
2121
+
2122
+ function isUnaryNegationToken(node
2123
+ /*: ESNode | Token */
2124
+ )
2125
+ /*: implies node is MostTokens */
2126
+ {
2127
+ return node.type === 'Punctuator' && node.value === '~';
2128
+ }
2129
+
2130
+ function isTypeOfToken(node
2131
+ /*: ESNode | Token */
2132
+ )
2133
+ /*: implies node is MostTokens */
2134
+ {
2135
+ return node.type === 'Keyword' && node.value === 'typeof';
2136
+ }
2137
+
2138
+ function isVoidToken(node
2139
+ /*: ESNode | Token */
2140
+ )
2141
+ /*: implies node is MostTokens */
2142
+ {
2143
+ return node.type === 'Keyword' && node.value === 'void';
2144
+ }
2145
+
2146
+ function isDeleteToken(node
2147
+ /*: ESNode | Token */
2148
+ )
2149
+ /*: implies node is MostTokens */
2150
+ {
2151
+ return node.type === 'Keyword' && node.value === 'delete';
2152
+ }
2153
+
2154
+ function isLooseEqualToken(node
2155
+ /*: ESNode | Token */
2156
+ )
2157
+ /*: implies node is MostTokens */
2158
+ {
2159
+ return node.type === 'Punctuator' && node.value === '==';
2160
+ }
2161
+
2162
+ function isLooseNotEqualToken(node
2163
+ /*: ESNode | Token */
2164
+ )
2165
+ /*: implies node is MostTokens */
2166
+ {
2167
+ return node.type === 'Punctuator' && node.value === '!=';
2168
+ }
2169
+
2170
+ function isStrictEqualToken(node
2171
+ /*: ESNode | Token */
2172
+ )
2173
+ /*: implies node is MostTokens */
2174
+ {
2175
+ return node.type === 'Punctuator' && node.value === '===';
2176
+ }
2177
+
2178
+ function isStrictNotEqualToken(node
2179
+ /*: ESNode | Token */
2180
+ )
2181
+ /*: implies node is MostTokens */
2182
+ {
2183
+ return node.type === 'Punctuator' && node.value === '!==';
2184
+ }
2185
+
2186
+ function isLessThanToken(node
2187
+ /*: ESNode | Token */
2188
+ )
2189
+ /*: implies node is MostTokens */
2190
+ {
2191
+ return node.type === 'Punctuator' && node.value === '<';
2192
+ }
2193
+
2194
+ function isLessThanOrEqualToToken(node
2195
+ /*: ESNode | Token */
2196
+ )
2197
+ /*: implies node is MostTokens */
2198
+ {
2199
+ return node.type === 'Punctuator' && node.value === '<=';
2200
+ }
2201
+
2202
+ function isGreaterThanToken(node
2203
+ /*: ESNode | Token */
2204
+ )
2205
+ /*: implies node is MostTokens */
2206
+ {
2207
+ return node.type === 'Punctuator' && node.value === '>';
2208
+ }
2209
+
2210
+ function isGreaterThanOrEqualToToken(node
2211
+ /*: ESNode | Token */
2212
+ )
2213
+ /*: implies node is MostTokens */
2214
+ {
2215
+ return node.type === 'Punctuator' && node.value === '>=';
2216
+ }
2217
+
2218
+ function isBitwiseLeftShiftToken(node
2219
+ /*: ESNode | Token */
2220
+ )
2221
+ /*: implies node is MostTokens */
2222
+ {
2223
+ return node.type === 'Punctuator' && node.value === '<<';
2224
+ }
2225
+
2226
+ function isBitwiseRightShiftToken(node
2227
+ /*: ESNode | Token */
2228
+ )
2229
+ /*: implies node is MostTokens */
2230
+ {
2231
+ return node.type === 'Punctuator' && node.value === '>>';
2232
+ }
2233
+
2234
+ function isBitwiseUnsignedRightShiftToken(node
2235
+ /*: ESNode | Token */
2236
+ )
2237
+ /*: implies node is MostTokens */
2238
+ {
2239
+ return node.type === 'Punctuator' && node.value === '>>>';
2240
+ }
2241
+
2242
+ function isAsterixToken(node
2243
+ /*: ESNode | Token */
2244
+ )
2245
+ /*: implies node is MostTokens */
2246
+ {
2247
+ return node.type === 'Punctuator' && node.value === '*';
2248
+ }
2249
+
2250
+ function isForwardSlashToken(node
2251
+ /*: ESNode | Token */
2252
+ )
2253
+ /*: implies node is MostTokens */
2254
+ {
2255
+ return node.type === 'Punctuator' && node.value === '/';
2256
+ }
2257
+
2258
+ function isPercentToken(node
2259
+ /*: ESNode | Token */
2260
+ )
2261
+ /*: implies node is MostTokens */
2262
+ {
2263
+ return node.type === 'Punctuator' && node.value === '%';
2264
+ }
2265
+
2266
+ function isExponentiationToken(node
2267
+ /*: ESNode | Token */
2268
+ )
2269
+ /*: implies node is MostTokens */
2270
+ {
2271
+ return node.type === 'Punctuator' && node.value === '**';
2272
+ }
2273
+
2274
+ function isBitwiseORToken(node
2275
+ /*: ESNode | Token */
2276
+ )
2277
+ /*: implies node is MostTokens */
2278
+ {
2279
+ return node.type === 'Punctuator' && node.value === '|';
2280
+ }
2281
+
2282
+ function isBitwiseXORToken(node
2283
+ /*: ESNode | Token */
2284
+ )
2285
+ /*: implies node is MostTokens */
2286
+ {
2287
+ return node.type === 'Punctuator' && node.value === '^';
2288
+ }
2289
+
2290
+ function isBitwiseANDToken(node
2291
+ /*: ESNode | Token */
2292
+ )
2293
+ /*: implies node is MostTokens */
2294
+ {
2295
+ return node.type === 'Punctuator' && node.value === '&';
2296
+ }
2297
+
2298
+ function isInToken(node
2299
+ /*: ESNode | Token */
2300
+ )
2301
+ /*: implies node is MostTokens */
2302
+ {
2303
+ return node.type === 'Keyword' && node.value === 'in';
2304
+ }
2305
+
2306
+ function isInstanceOfToken(node
2307
+ /*: ESNode | Token */
2308
+ )
2309
+ /*: implies node is MostTokens */
2310
+ {
2311
+ return node.type === 'Keyword' && node.value === 'instanceof';
2312
+ }
2313
+
2314
+ function isLogicalORToken(node
2315
+ /*: ESNode | Token */
2316
+ )
2317
+ /*: implies node is MostTokens */
2318
+ {
2319
+ return node.type === 'Punctuator' && node.value === '||';
2320
+ }
2321
+
2322
+ function isLogicalANDToken(node
2323
+ /*: ESNode | Token */
2324
+ )
2325
+ /*: implies node is MostTokens */
2326
+ {
2327
+ return node.type === 'Punctuator' && node.value === '&&';
2328
+ }
2329
+
2330
+ function isNullishCoalesceToken(node
2331
+ /*: ESNode | Token */
2332
+ )
2333
+ /*: implies node is MostTokens */
2334
+ {
2335
+ return node.type === 'Punctuator' && node.value === '??';
2336
+ }
2337
+
2338
+ function isEqualToken(node
2339
+ /*: ESNode | Token */
2340
+ )
2341
+ /*: implies node is MostTokens */
2342
+ {
2343
+ return node.type === 'Punctuator' && node.value === '=';
2344
+ }
2345
+
2346
+ function isPlusEqualToken(node
2347
+ /*: ESNode | Token */
2348
+ )
2349
+ /*: implies node is MostTokens */
2350
+ {
2351
+ return node.type === 'Punctuator' && node.value === '+=';
2352
+ }
2353
+
2354
+ function isMinusEqualToken(node
2355
+ /*: ESNode | Token */
2356
+ )
2357
+ /*: implies node is MostTokens */
2358
+ {
2359
+ return node.type === 'Punctuator' && node.value === '-=';
2360
+ }
2361
+
2362
+ function isMultiplyEqualToken(node
2363
+ /*: ESNode | Token */
2364
+ )
2365
+ /*: implies node is MostTokens */
2366
+ {
2367
+ return node.type === 'Punctuator' && node.value === '*=';
2368
+ }
2369
+
2370
+ function isDivideEqualToken(node
2371
+ /*: ESNode | Token */
2372
+ )
2373
+ /*: implies node is MostTokens */
2374
+ {
2375
+ return node.type === 'Punctuator' && node.value === '/=';
2376
+ }
2377
+
2378
+ function isRemainderEqualToken(node
2379
+ /*: ESNode | Token */
2380
+ )
2381
+ /*: implies node is MostTokens */
2382
+ {
2383
+ return node.type === 'Punctuator' && node.value === '%=';
2384
+ }
2385
+
2386
+ function isExponentateEqualToken(node
2387
+ /*: ESNode | Token */
2388
+ )
2389
+ /*: implies node is MostTokens */
2390
+ {
2391
+ return node.type === 'Punctuator' && node.value === '**=';
2392
+ }
2393
+
2394
+ function isBitwiseLeftShiftEqualToken(node
2395
+ /*: ESNode | Token */
2396
+ )
2397
+ /*: implies node is MostTokens */
2398
+ {
2399
+ return node.type === 'Punctuator' && node.value === '<<=';
2400
+ }
2401
+
2402
+ function isBitwiseRightShiftEqualToken(node
2403
+ /*: ESNode | Token */
2404
+ )
2405
+ /*: implies node is MostTokens */
2406
+ {
2407
+ return node.type === 'Punctuator' && node.value === '>>=';
2408
+ }
2409
+
2410
+ function isBitwiseUnsignedRightShiftEqualToken(node
2411
+ /*: ESNode | Token */
2412
+ )
2413
+ /*: implies node is MostTokens */
2414
+ {
2415
+ return node.type === 'Punctuator' && node.value === '>>>=';
2416
+ }
2417
+
2418
+ function isBitwiseOREqualToken(node
2419
+ /*: ESNode | Token */
2420
+ )
2421
+ /*: implies node is MostTokens */
2422
+ {
2423
+ return node.type === 'Punctuator' && node.value === '|=';
2424
+ }
2425
+
2426
+ function isBitwiseXOREqualToken(node
2427
+ /*: ESNode | Token */
2428
+ )
2429
+ /*: implies node is MostTokens */
2430
+ {
2431
+ return node.type === 'Punctuator' && node.value === '^=';
2432
+ }
2433
+
2434
+ function isBitwiseANDEqualToken(node
2435
+ /*: ESNode | Token */
2436
+ )
2437
+ /*: implies node is MostTokens */
2438
+ {
2439
+ return node.type === 'Punctuator' && node.value === '&=';
2440
+ }
2441
+
2442
+ function isLogicalOREqualToken(node
2443
+ /*: ESNode | Token */
2444
+ )
2445
+ /*: implies node is MostTokens */
2446
+ {
2447
+ return node.type === 'Punctuator' && node.value === '||=';
2448
+ }
2449
+
2450
+ function isLogicalANDEqualToken(node
2451
+ /*: ESNode | Token */
2452
+ )
2453
+ /*: implies node is MostTokens */
2454
+ {
2455
+ return node.type === 'Punctuator' && node.value === '&&=';
2456
+ }
2457
+
2458
+ function isNullishCoalesceEqualToken(node
2459
+ /*: ESNode | Token */
2460
+ )
2461
+ /*: implies node is MostTokens */
2462
+ {
2463
+ return node.type === 'Punctuator' && node.value === '??=';
2464
+ }
2465
+
2466
+ function isIncrementToken(node
2467
+ /*: ESNode | Token */
2468
+ )
2469
+ /*: implies node is MostTokens */
2470
+ {
2471
+ return node.type === 'Punctuator' && node.value === '++';
2472
+ }
2473
+
2474
+ function isDecrementToken(node
2475
+ /*: ESNode | Token */
2476
+ )
2477
+ /*: implies node is MostTokens */
2478
+ {
2479
+ return node.type === 'Punctuator' && node.value === '--';
2480
+ }
2481
+
2482
+ function isUnionTypeToken(node
2483
+ /*: ESNode | Token */
2484
+ )
2485
+ /*: implies node is MostTokens */
2486
+ {
2487
+ return node.type === 'Punctuator' && node.value === '|';
2488
+ }
2489
+
2490
+ function isIntersectionTypeToken(node
2491
+ /*: ESNode | Token */
2492
+ )
2493
+ /*: implies node is MostTokens */
2494
+ {
2495
+ return node.type === 'Punctuator' && node.value === '&';
2496
+ }
2497
+
2498
+ function isBreakToken(node
2499
+ /*: ESNode | Token */
2500
+ )
2501
+ /*: implies node is MostTokens */
2502
+ {
2503
+ return node.type === 'Keyword' && node.value === 'break';
2504
+ }
2505
+
2506
+ function isCaseToken(node
2507
+ /*: ESNode | Token */
2508
+ )
2509
+ /*: implies node is MostTokens */
2510
+ {
2511
+ return node.type === 'Keyword' && node.value === 'case';
2512
+ }
2513
+
2514
+ function isCatchToken(node
2515
+ /*: ESNode | Token */
2516
+ )
2517
+ /*: implies node is MostTokens */
2518
+ {
2519
+ return node.type === 'Keyword' && node.value === 'catch';
2520
+ }
2521
+
2522
+ function isClassToken(node
2523
+ /*: ESNode | Token */
2524
+ )
2525
+ /*: implies node is MostTokens */
2526
+ {
2527
+ return node.type === 'Keyword' && node.value === 'class';
2528
+ }
2529
+
2530
+ function isConstToken(node
2531
+ /*: ESNode | Token */
2532
+ )
2533
+ /*: implies node is MostTokens */
2534
+ {
2535
+ return node.type === 'Keyword' && node.value === 'const';
2536
+ }
2537
+
2538
+ function isContinueToken(node
2539
+ /*: ESNode | Token */
2540
+ )
2541
+ /*: implies node is MostTokens */
2542
+ {
2543
+ return node.type === 'Keyword' && node.value === 'continue';
2544
+ }
2545
+
2546
+ function isDebuggerToken(node
2547
+ /*: ESNode | Token */
2548
+ )
2549
+ /*: implies node is MostTokens */
2550
+ {
2551
+ return node.type === 'Keyword' && node.value === 'debugger';
2552
+ }
2553
+
2554
+ function isDefaultToken(node
2555
+ /*: ESNode | Token */
2556
+ )
2557
+ /*: implies node is MostTokens */
2558
+ {
2559
+ return node.type === 'Keyword' && node.value === 'default';
2560
+ }
2561
+
2562
+ function isDoToken(node
2563
+ /*: ESNode | Token */
2564
+ )
2565
+ /*: implies node is MostTokens */
2566
+ {
2567
+ return node.type === 'Keyword' && node.value === 'do';
2568
+ }
2569
+
2570
+ function isElseToken(node
2571
+ /*: ESNode | Token */
2572
+ )
2573
+ /*: implies node is MostTokens */
2574
+ {
2575
+ return node.type === 'Keyword' && node.value === 'else';
2576
+ }
2577
+
2578
+ function isEnumToken(node
2579
+ /*: ESNode | Token */
2580
+ )
2581
+ /*: implies node is MostTokens */
2582
+ {
2583
+ return node.type === 'Keyword' && node.value === 'enum';
2584
+ }
2585
+
2586
+ function isExportToken(node
2587
+ /*: ESNode | Token */
2588
+ )
2589
+ /*: implies node is MostTokens */
2590
+ {
2591
+ return node.type === 'Keyword' && node.value === 'export';
2592
+ }
2593
+
2594
+ function isExtendsToken(node
2595
+ /*: ESNode | Token */
2596
+ )
2597
+ /*: implies node is MostTokens */
2598
+ {
2599
+ return node.type === 'Keyword' && node.value === 'extends';
2600
+ }
2601
+
2602
+ function isFinallyToken(node
2603
+ /*: ESNode | Token */
2604
+ )
2605
+ /*: implies node is MostTokens */
2606
+ {
2607
+ return node.type === 'Keyword' && node.value === 'finally';
2608
+ }
2609
+
2610
+ function isForToken(node
2611
+ /*: ESNode | Token */
2612
+ )
2613
+ /*: implies node is MostTokens */
2614
+ {
2615
+ return node.type === 'Keyword' && node.value === 'for';
2616
+ }
2617
+
2618
+ function isFunctionToken(node
2619
+ /*: ESNode | Token */
2620
+ )
2621
+ /*: implies node is MostTokens */
2622
+ {
2623
+ return node.type === 'Keyword' && node.value === 'function';
2624
+ }
2625
+
2626
+ function isIfToken(node
2627
+ /*: ESNode | Token */
2628
+ )
2629
+ /*: implies node is MostTokens */
2630
+ {
2631
+ return node.type === 'Keyword' && node.value === 'if';
2632
+ }
2633
+
2634
+ function isImplementsToken(node
2635
+ /*: ESNode | Token */
2636
+ )
2637
+ /*: implies node is MostTokens */
2638
+ {
2639
+ return node.type === 'Keyword' && node.value === 'implements';
2640
+ }
2641
+
2642
+ function isImportToken(node
2643
+ /*: ESNode | Token */
2644
+ )
2645
+ /*: implies node is MostTokens */
2646
+ {
2647
+ return node.type === 'Keyword' && node.value === 'import';
2648
+ }
2649
+
2650
+ function isInterfaceToken(node
2651
+ /*: ESNode | Token */
2652
+ )
2653
+ /*: implies node is MostTokens */
2654
+ {
2655
+ return node.type === 'Keyword' && node.value === 'interface';
2656
+ }
2657
+
2658
+ function isNewToken(node
2659
+ /*: ESNode | Token */
2660
+ )
2661
+ /*: implies node is MostTokens */
2662
+ {
2663
+ return node.type === 'Keyword' && node.value === 'new';
2664
+ }
2665
+
2666
+ function isReturnToken(node
2667
+ /*: ESNode | Token */
2668
+ )
2669
+ /*: implies node is MostTokens */
2670
+ {
2671
+ return node.type === 'Keyword' && node.value === 'return';
2672
+ }
2673
+
2674
+ function isStaticToken(node
2675
+ /*: ESNode | Token */
2676
+ )
2677
+ /*: implies node is MostTokens */
2678
+ {
2679
+ return node.type === 'Keyword' && node.value === 'static';
2680
+ }
2681
+
2682
+ function isSuperToken(node
2683
+ /*: ESNode | Token */
2684
+ )
2685
+ /*: implies node is MostTokens */
2686
+ {
2687
+ return node.type === 'Keyword' && node.value === 'super';
2688
+ }
2689
+
2690
+ function isSwitchToken(node
2691
+ /*: ESNode | Token */
2692
+ )
2693
+ /*: implies node is MostTokens */
2694
+ {
2695
+ return node.type === 'Keyword' && node.value === 'switch';
2696
+ }
2697
+
2698
+ function isThisToken(node
2699
+ /*: ESNode | Token */
2700
+ )
2701
+ /*: implies node is MostTokens */
2702
+ {
2703
+ return node.type === 'Keyword' && node.value === 'this';
2704
+ }
2705
+
2706
+ function isThrowToken(node
2707
+ /*: ESNode | Token */
2708
+ )
2709
+ /*: implies node is MostTokens */
2710
+ {
2711
+ return node.type === 'Keyword' && node.value === 'throw';
2712
+ }
2713
+
2714
+ function isTryToken(node
2715
+ /*: ESNode | Token */
2716
+ )
2717
+ /*: implies node is MostTokens */
2718
+ {
2719
+ return node.type === 'Keyword' && node.value === 'try';
2720
+ }
2721
+
2722
+ function isVarToken(node
2723
+ /*: ESNode | Token */
2724
+ )
2725
+ /*: implies node is MostTokens */
2726
+ {
2727
+ return node.type === 'Keyword' && node.value === 'var';
2728
+ }
2729
+
2730
+ function isWhileToken(node
2731
+ /*: ESNode | Token */
2732
+ )
2733
+ /*: implies node is MostTokens */
2734
+ {
2735
+ return node.type === 'Keyword' && node.value === 'while';
2736
+ }
2737
+
2738
+ function isWithToken(node
2739
+ /*: ESNode | Token */
2740
+ )
2741
+ /*: implies node is MostTokens */
2742
+ {
2743
+ return node.type === 'Keyword' && node.value === 'with';
2744
+ }
2745
+
2746
+ function isYieldToken(node
2747
+ /*: ESNode | Token */
2748
+ )
2749
+ /*: implies node is MostTokens */
2750
+ {
2751
+ return node.type === 'Keyword' && node.value === 'yield';
2752
+ }
2753
+
2754
+ function isAsKeyword(node
2755
+ /*: ESNode | Token */
2756
+ )
2757
+ /*: implies node is (Identifier | MostTokens) */
2758
+ {
2759
+ return node.type === 'Identifier' && node.name === 'as' || node.type === 'Keyword' && node.value === 'as';
2760
+ }
2761
+
2762
+ function isAsyncKeyword(node
2763
+ /*: ESNode | Token */
2764
+ )
2765
+ /*: implies node is (Identifier | MostTokens) */
2766
+ {
2767
+ return node.type === 'Identifier' && node.name === 'async' || node.type === 'Keyword' && node.value === 'async';
2768
+ }
2769
+
2770
+ function isAwaitKeyword(node
2771
+ /*: ESNode | Token */
2772
+ )
2773
+ /*: implies node is (Identifier | MostTokens) */
2774
+ {
2775
+ return node.type === 'Identifier' && node.name === 'await' || node.type === 'Keyword' && node.value === 'await';
2776
+ }
2777
+
2778
+ function isDeclareKeyword(node
2779
+ /*: ESNode | Token */
2780
+ )
2781
+ /*: implies node is (Identifier | MostTokens) */
2782
+ {
2783
+ return node.type === 'Identifier' && node.name === 'declare' || node.type === 'Keyword' && node.value === 'declare';
2784
+ }
2785
+
2786
+ function isFromKeyword(node
2787
+ /*: ESNode | Token */
2788
+ )
2789
+ /*: implies node is (Identifier | MostTokens) */
2790
+ {
2791
+ return node.type === 'Identifier' && node.name === 'from' || node.type === 'Keyword' && node.value === 'from';
2792
+ }
2793
+
2794
+ function isGetKeyword(node
2795
+ /*: ESNode | Token */
2796
+ )
2797
+ /*: implies node is (Identifier | MostTokens) */
2798
+ {
2799
+ return node.type === 'Identifier' && node.name === 'get' || node.type === 'Keyword' && node.value === 'get';
2800
+ }
2801
+
2802
+ function isLetKeyword(node
2803
+ /*: ESNode | Token */
2804
+ )
2805
+ /*: implies node is (Identifier | MostTokens) */
2806
+ {
2807
+ return node.type === 'Identifier' && node.name === 'let' || node.type === 'Keyword' && node.value === 'let';
2808
+ }
2809
+
2810
+ function isModuleKeyword(node
2811
+ /*: ESNode | Token */
2812
+ )
2813
+ /*: implies node is (Identifier | MostTokens) */
2814
+ {
2815
+ return node.type === 'Identifier' && node.name === 'module' || node.type === 'Keyword' && node.value === 'module';
2816
+ }
2817
+
2818
+ function isOfKeyword(node
2819
+ /*: ESNode | Token */
2820
+ )
2821
+ /*: implies node is (Identifier | MostTokens) */
2822
+ {
2823
+ return node.type === 'Identifier' && node.name === 'of' || node.type === 'Keyword' && node.value === 'of';
2824
+ }
2825
+
2826
+ function isSetKeyword(node
2827
+ /*: ESNode | Token */
2828
+ )
2829
+ /*: implies node is (Identifier | MostTokens) */
2830
+ {
2831
+ return node.type === 'Identifier' && node.name === 'set' || node.type === 'Keyword' && node.value === 'set';
2832
+ }
2833
+
2834
+ function isTypeKeyword(node
2835
+ /*: ESNode | Token */
2836
+ )
2837
+ /*: implies node is (Identifier | MostTokens) */
2838
+ {
2839
+ return node.type === 'Identifier' && node.name === 'type' || node.type === 'Keyword' && node.value === 'type';
2840
+ }
2841
+
2842
+ function isCommaToken(node
2843
+ /*: ESNode | Token */
2844
+ )
2845
+ /*: implies node is MostTokens */
2846
+ {
2847
+ return node.type === 'Punctuator' && node.value === ',';
2848
+ }
2849
+
2850
+ function isColonToken(node
2851
+ /*: ESNode | Token */
2852
+ )
2853
+ /*: implies node is MostTokens */
2854
+ {
2855
+ return node.type === 'Punctuator' && node.value === ':';
2856
+ }
2857
+
2858
+ function isSemicolonToken(node
2859
+ /*: ESNode | Token */
2860
+ )
2861
+ /*: implies node is MostTokens */
2862
+ {
2863
+ return node.type === 'Punctuator' && node.value === ';';
2864
+ }
2865
+
2866
+ function isDotToken(node
2867
+ /*: ESNode | Token */
2868
+ )
2869
+ /*: implies node is MostTokens */
2870
+ {
2871
+ return node.type === 'Punctuator' && node.value === '.';
2872
+ }
2873
+
2874
+ function isDotDotDotToken(node
2875
+ /*: ESNode | Token */
2876
+ )
2877
+ /*: implies node is MostTokens */
2878
+ {
2879
+ return node.type === 'Punctuator' && node.value === '...';
2880
+ }
2881
+
2882
+ function isOptionalChainToken(node
2883
+ /*: ESNode | Token */
2884
+ )
2885
+ /*: implies node is MostTokens */
2886
+ {
2887
+ return node.type === 'Punctuator' && node.value === '?.';
2888
+ }
2889
+
2890
+ function isQuestionMarkToken(node
2891
+ /*: ESNode | Token */
2892
+ )
2893
+ /*: implies node is MostTokens */
2894
+ {
2895
+ return node.type === 'Punctuator' && node.value === '?';
2896
+ }
2897
+
2898
+ function isOpeningParenthesisToken(node
2899
+ /*: ESNode | Token */
2900
+ )
2901
+ /*: implies node is MostTokens */
2902
+ {
2903
+ return node.type === 'Punctuator' && node.value === '(';
2904
+ }
2905
+
2906
+ function isClosingParenthesisToken(node
2907
+ /*: ESNode | Token */
2908
+ )
2909
+ /*: implies node is MostTokens */
2910
+ {
2911
+ return node.type === 'Punctuator' && node.value === ')';
2912
+ }
2913
+
2914
+ function isOpeningCurlyBracketToken(node
2915
+ /*: ESNode | Token */
2916
+ )
2917
+ /*: implies node is MostTokens */
2918
+ {
2919
+ return node.type === 'Punctuator' && node.value === '{';
2920
+ }
2921
+
2922
+ function isClosingCurlyBracketToken(node
2923
+ /*: ESNode | Token */
2924
+ )
2925
+ /*: implies node is MostTokens */
2926
+ {
2927
+ return node.type === 'Punctuator' && node.value === '}';
2928
+ }
2929
+
2930
+ function isOpeningAngleBracketToken(node
2931
+ /*: ESNode | Token */
2932
+ )
2933
+ /*: implies node is MostTokens */
2934
+ {
2935
+ return node.type === 'Punctuator' && node.value === '<';
2936
+ }
2937
+
2938
+ function isClosingAngleBracketToken(node
2939
+ /*: ESNode | Token */
2940
+ )
2941
+ /*: implies node is MostTokens */
2942
+ {
2943
+ return node.type === 'Punctuator' && node.value === '>';
2944
+ }