@typescript-deploys/pr-build 5.0.0-pr-52240-9 → 5.0.0-pr-49929-73
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.
- package/lib/tsc.js +487 -404
- package/lib/tsserver.js +543 -429
- package/lib/tsserverlibrary.d.ts +76 -22
- package/lib/tsserverlibrary.js +539 -429
- package/lib/typescript.d.ts +66 -18
- package/lib/typescript.js +534 -429
- package/lib/typingsInstaller.js +199 -189
- package/package.json +1 -1
package/lib/tsserver.js
CHANGED
|
@@ -1340,6 +1340,7 @@ __export(server_exports, {
|
|
|
1340
1340
|
isArgumentExpressionOfElementAccess: () => isArgumentExpressionOfElementAccess,
|
|
1341
1341
|
isArray: () => isArray,
|
|
1342
1342
|
isArrayBindingElement: () => isArrayBindingElement,
|
|
1343
|
+
isArrayBindingOrAssignmentElement: () => isArrayBindingOrAssignmentElement,
|
|
1343
1344
|
isArrayBindingOrAssignmentPattern: () => isArrayBindingOrAssignmentPattern,
|
|
1344
1345
|
isArrayBindingPattern: () => isArrayBindingPattern,
|
|
1345
1346
|
isArrayLiteralExpression: () => isArrayLiteralExpression,
|
|
@@ -1372,6 +1373,7 @@ __export(server_exports, {
|
|
|
1372
1373
|
isBindableStaticNameExpression: () => isBindableStaticNameExpression,
|
|
1373
1374
|
isBindingElement: () => isBindingElement,
|
|
1374
1375
|
isBindingName: () => isBindingName,
|
|
1376
|
+
isBindingOrAssignmentElement: () => isBindingOrAssignmentElement,
|
|
1375
1377
|
isBindingOrAssignmentPattern: () => isBindingOrAssignmentPattern,
|
|
1376
1378
|
isBindingPattern: () => isBindingPattern,
|
|
1377
1379
|
isBlock: () => isBlock,
|
|
@@ -1578,6 +1580,7 @@ __export(server_exports, {
|
|
|
1578
1580
|
isInferTypeNode: () => isInferTypeNode,
|
|
1579
1581
|
isInfinityOrNaNString: () => isInfinityOrNaNString,
|
|
1580
1582
|
isInitializedProperty: () => isInitializedProperty,
|
|
1583
|
+
isInitializedVariable: () => isInitializedVariable,
|
|
1581
1584
|
isInsideJsxElement: () => isInsideJsxElement,
|
|
1582
1585
|
isInsideJsxElementOrAttribute: () => isInsideJsxElementOrAttribute,
|
|
1583
1586
|
isInsideNodeModules: () => isInsideNodeModules,
|
|
@@ -1682,6 +1685,7 @@ __export(server_exports, {
|
|
|
1682
1685
|
isLiteralLikeElementAccess: () => isLiteralLikeElementAccess,
|
|
1683
1686
|
isLiteralNameOfPropertyDeclarationOrIndexAccess: () => isLiteralNameOfPropertyDeclarationOrIndexAccess,
|
|
1684
1687
|
isLiteralTypeLikeExpression: () => isLiteralTypeLikeExpression,
|
|
1688
|
+
isLiteralTypeLiteral: () => isLiteralTypeLiteral,
|
|
1685
1689
|
isLiteralTypeNode: () => isLiteralTypeNode,
|
|
1686
1690
|
isLocalName: () => isLocalName,
|
|
1687
1691
|
isLogicalOperator: () => isLogicalOperator,
|
|
@@ -2671,7 +2675,7 @@ __export(ts_server_exports3, {
|
|
|
2671
2675
|
|
|
2672
2676
|
// src/compiler/corePublic.ts
|
|
2673
2677
|
var versionMajorMinor = "5.0";
|
|
2674
|
-
var version = `${versionMajorMinor}.0-insiders.
|
|
2678
|
+
var version = `${versionMajorMinor}.0-insiders.20230116`;
|
|
2675
2679
|
var Comparison = /* @__PURE__ */ ((Comparison3) => {
|
|
2676
2680
|
Comparison3[Comparison3["LessThan"] = -1] = "LessThan";
|
|
2677
2681
|
Comparison3[Comparison3["EqualTo"] = 0] = "EqualTo";
|
|
@@ -12204,10 +12208,7 @@ function reduceEachTrailingCommentRange(text, pos, cb, state, initial) {
|
|
|
12204
12208
|
initial
|
|
12205
12209
|
);
|
|
12206
12210
|
}
|
|
12207
|
-
function appendCommentRange(pos, end, kind, hasTrailingNewLine, _state, comments) {
|
|
12208
|
-
if (!comments) {
|
|
12209
|
-
comments = [];
|
|
12210
|
-
}
|
|
12211
|
+
function appendCommentRange(pos, end, kind, hasTrailingNewLine, _state, comments = []) {
|
|
12211
12212
|
comments.push({ kind, pos, end, hasTrailingNewLine });
|
|
12212
12213
|
return comments;
|
|
12213
12214
|
}
|
|
@@ -13990,7 +13991,10 @@ function getOriginalNode(node, nodeTest) {
|
|
|
13990
13991
|
node = node.original;
|
|
13991
13992
|
}
|
|
13992
13993
|
}
|
|
13993
|
-
|
|
13994
|
+
if (!node || !nodeTest) {
|
|
13995
|
+
return node;
|
|
13996
|
+
}
|
|
13997
|
+
return nodeTest(node) ? node : void 0;
|
|
13994
13998
|
}
|
|
13995
13999
|
function findAncestor(node, callback) {
|
|
13996
14000
|
while (node) {
|
|
@@ -14731,6 +14735,9 @@ function isDeclarationBindingElement(bindingElement) {
|
|
|
14731
14735
|
}
|
|
14732
14736
|
return false;
|
|
14733
14737
|
}
|
|
14738
|
+
function isBindingOrAssignmentElement(node) {
|
|
14739
|
+
return isVariableDeclaration(node) || isParameter(node) || isObjectBindingOrAssignmentElement(node) || isArrayBindingOrAssignmentElement(node);
|
|
14740
|
+
}
|
|
14734
14741
|
function isBindingOrAssignmentPattern(node) {
|
|
14735
14742
|
return isObjectBindingOrAssignmentPattern(node) || isArrayBindingOrAssignmentPattern(node);
|
|
14736
14743
|
}
|
|
@@ -14760,6 +14767,24 @@ function isArrayBindingOrAssignmentPattern(node) {
|
|
|
14760
14767
|
}
|
|
14761
14768
|
return false;
|
|
14762
14769
|
}
|
|
14770
|
+
function isArrayBindingOrAssignmentElement(node) {
|
|
14771
|
+
switch (node.kind) {
|
|
14772
|
+
case 205 /* BindingElement */:
|
|
14773
|
+
case 229 /* OmittedExpression */:
|
|
14774
|
+
case 227 /* SpreadElement */:
|
|
14775
|
+
case 206 /* ArrayLiteralExpression */:
|
|
14776
|
+
case 207 /* ObjectLiteralExpression */:
|
|
14777
|
+
case 79 /* Identifier */:
|
|
14778
|
+
case 208 /* PropertyAccessExpression */:
|
|
14779
|
+
case 209 /* ElementAccessExpression */:
|
|
14780
|
+
return true;
|
|
14781
|
+
}
|
|
14782
|
+
return isAssignmentExpression(
|
|
14783
|
+
node,
|
|
14784
|
+
/*excludeCompoundAssignment*/
|
|
14785
|
+
true
|
|
14786
|
+
);
|
|
14787
|
+
}
|
|
14763
14788
|
function isPropertyAccessOrQualifiedNameOrImportTypeNode(node) {
|
|
14764
14789
|
const kind = node.kind;
|
|
14765
14790
|
return kind === 208 /* PropertyAccessExpression */ || kind === 163 /* QualifiedName */ || kind === 202 /* ImportType */;
|
|
@@ -14855,6 +14880,18 @@ function isUnaryExpressionWithWrite(expr) {
|
|
|
14855
14880
|
return false;
|
|
14856
14881
|
}
|
|
14857
14882
|
}
|
|
14883
|
+
function isLiteralTypeLiteral(node) {
|
|
14884
|
+
node = skipPartiallyEmittedExpressions(node);
|
|
14885
|
+
switch (skipPartiallyEmittedExpressions(node).kind) {
|
|
14886
|
+
case 104 /* NullKeyword */:
|
|
14887
|
+
case 110 /* TrueKeyword */:
|
|
14888
|
+
case 95 /* FalseKeyword */:
|
|
14889
|
+
case 221 /* PrefixUnaryExpression */:
|
|
14890
|
+
return true;
|
|
14891
|
+
default:
|
|
14892
|
+
return isLiteralExpression(node);
|
|
14893
|
+
}
|
|
14894
|
+
}
|
|
14858
14895
|
function isExpression(node) {
|
|
14859
14896
|
return isExpressionKind(skipPartiallyEmittedExpressions(node).kind);
|
|
14860
14897
|
}
|
|
@@ -15845,6 +15882,7 @@ function isBlockScope(node, parentNode) {
|
|
|
15845
15882
|
return false;
|
|
15846
15883
|
}
|
|
15847
15884
|
function isDeclarationWithTypeParameters(node) {
|
|
15885
|
+
Debug.type(node);
|
|
15848
15886
|
switch (node.kind) {
|
|
15849
15887
|
case 341 /* JSDocCallbackTag */:
|
|
15850
15888
|
case 349 /* JSDocTypedefTag */:
|
|
@@ -15856,6 +15894,7 @@ function isDeclarationWithTypeParameters(node) {
|
|
|
15856
15894
|
}
|
|
15857
15895
|
}
|
|
15858
15896
|
function isDeclarationWithTypeParameterChildren(node) {
|
|
15897
|
+
Debug.type(node);
|
|
15859
15898
|
switch (node.kind) {
|
|
15860
15899
|
case 176 /* CallSignature */:
|
|
15861
15900
|
case 177 /* ConstructSignature */:
|
|
@@ -19383,7 +19422,7 @@ function getInitializedVariables(node) {
|
|
|
19383
19422
|
return filter(node.declarations, isInitializedVariable);
|
|
19384
19423
|
}
|
|
19385
19424
|
function isInitializedVariable(node) {
|
|
19386
|
-
return node.initializer !== void 0;
|
|
19425
|
+
return isVariableDeclaration(node) && node.initializer !== void 0;
|
|
19387
19426
|
}
|
|
19388
19427
|
function isWatchSet(options) {
|
|
19389
19428
|
return options.watch && hasProperty(options, "watch");
|
|
@@ -19570,7 +19609,7 @@ function isObjectTypeDeclaration(node) {
|
|
|
19570
19609
|
return isClassLike(node) || isInterfaceDeclaration(node) || isTypeLiteralNode(node);
|
|
19571
19610
|
}
|
|
19572
19611
|
function isTypeNodeKind(kind) {
|
|
19573
|
-
return kind >= 179 /* FirstTypeNode */ && kind <= 202 /* LastTypeNode */ || kind === 131 /* AnyKeyword */ || kind === 157 /* UnknownKeyword */ || kind === 148 /* NumberKeyword */ || kind === 160 /* BigIntKeyword */ || kind === 149 /* ObjectKeyword */ || kind === 134 /* BooleanKeyword */ || kind === 152 /* StringKeyword */ || kind === 153 /* SymbolKeyword */ || kind === 114 /* VoidKeyword */ || kind === 155 /* UndefinedKeyword */ || kind === 144 /* NeverKeyword */ || kind === 230 /* ExpressionWithTypeArguments */ || kind === 315 /* JSDocAllType */ || kind === 316 /* JSDocUnknownType */ || kind === 317 /* JSDocNullableType */ || kind === 318 /* JSDocNonNullableType */ || kind === 319 /* JSDocOptionalType */ || kind === 320 /* JSDocFunctionType */ || kind === 321 /* JSDocVariadicType */;
|
|
19612
|
+
return kind >= 179 /* FirstTypeNode */ && kind <= 202 /* LastTypeNode */ || kind === 131 /* AnyKeyword */ || kind === 157 /* UnknownKeyword */ || kind === 148 /* NumberKeyword */ || kind === 160 /* BigIntKeyword */ || kind === 149 /* ObjectKeyword */ || kind === 134 /* BooleanKeyword */ || kind === 152 /* StringKeyword */ || kind === 153 /* SymbolKeyword */ || kind === 114 /* VoidKeyword */ || kind === 155 /* UndefinedKeyword */ || kind === 144 /* NeverKeyword */ || kind === 139 /* IntrinsicKeyword */ || kind === 230 /* ExpressionWithTypeArguments */ || kind === 315 /* JSDocAllType */ || kind === 316 /* JSDocUnknownType */ || kind === 317 /* JSDocNullableType */ || kind === 318 /* JSDocNonNullableType */ || kind === 319 /* JSDocOptionalType */ || kind === 320 /* JSDocFunctionType */ || kind === 321 /* JSDocVariadicType */;
|
|
19574
19613
|
}
|
|
19575
19614
|
function isAccessExpression(node) {
|
|
19576
19615
|
return node.kind === 208 /* PropertyAccessExpression */ || node.kind === 209 /* ElementAccessExpression */;
|
|
@@ -40056,6 +40095,7 @@ function validateSpecs(specs, errors, disallowTrailingRecursion, jsonSourceFile,
|
|
|
40056
40095
|
}
|
|
40057
40096
|
}
|
|
40058
40097
|
function specToDiagnostic(spec, disallowTrailingRecursion) {
|
|
40098
|
+
Debug.assert(typeof spec === "string");
|
|
40059
40099
|
if (disallowTrailingRecursion && invalidTrailingRecursionPattern.test(spec)) {
|
|
40060
40100
|
return [Diagnostics.File_specification_cannot_end_in_a_recursive_directory_wildcard_Asterisk_Asterisk_Colon_0, spec];
|
|
40061
40101
|
} else if (invalidDotDotAfterRecursiveWildcard(spec)) {
|
|
@@ -47415,7 +47455,7 @@ function createTypeChecker(host) {
|
|
|
47415
47455
|
if (jsxFragmentPragma) {
|
|
47416
47456
|
const chosenPragma = isArray(jsxFragmentPragma) ? jsxFragmentPragma[0] : jsxFragmentPragma;
|
|
47417
47457
|
file.localJsxFragmentFactory = parseIsolatedEntityName(chosenPragma.arguments.factory, languageVersion);
|
|
47418
|
-
visitNode(file.localJsxFragmentFactory, markAsSynthetic);
|
|
47458
|
+
visitNode(file.localJsxFragmentFactory, markAsSynthetic, isEntityName);
|
|
47419
47459
|
if (file.localJsxFragmentFactory) {
|
|
47420
47460
|
return file.localJsxFragmentNamespace = getFirstIdentifier(file.localJsxFragmentFactory).escapedText;
|
|
47421
47461
|
}
|
|
@@ -47458,7 +47498,7 @@ function createTypeChecker(host) {
|
|
|
47458
47498
|
if (jsxPragma) {
|
|
47459
47499
|
const chosenPragma = isArray(jsxPragma) ? jsxPragma[0] : jsxPragma;
|
|
47460
47500
|
file.localJsxFactory = parseIsolatedEntityName(chosenPragma.arguments.factory, languageVersion);
|
|
47461
|
-
visitNode(file.localJsxFactory, markAsSynthetic);
|
|
47501
|
+
visitNode(file.localJsxFactory, markAsSynthetic, isEntityName);
|
|
47462
47502
|
if (file.localJsxFactory) {
|
|
47463
47503
|
return file.localJsxNamespace = getFirstIdentifier(file.localJsxFactory).escapedText;
|
|
47464
47504
|
}
|
|
@@ -48969,6 +49009,7 @@ function createTypeChecker(host) {
|
|
|
48969
49009
|
return valueSymbol;
|
|
48970
49010
|
}
|
|
48971
49011
|
const result = createSymbol(valueSymbol.flags | typeSymbol.flags, valueSymbol.escapedName);
|
|
49012
|
+
Debug.assert(valueSymbol.declarations || typeSymbol.declarations);
|
|
48972
49013
|
result.declarations = deduplicate(concatenate(valueSymbol.declarations, typeSymbol.declarations), equateValues);
|
|
48973
49014
|
result.parent = valueSymbol.parent || typeSymbol.parent;
|
|
48974
49015
|
if (valueSymbol.valueDeclaration)
|
|
@@ -52608,7 +52649,7 @@ function createTypeChecker(host) {
|
|
|
52608
52649
|
}
|
|
52609
52650
|
let hadError = false;
|
|
52610
52651
|
const file = getSourceFileOfNode(existing);
|
|
52611
|
-
const transformed = visitNode(existing, visitExistingNodeTreeSymbols);
|
|
52652
|
+
const transformed = visitNode(existing, visitExistingNodeTreeSymbols, isTypeNode);
|
|
52612
52653
|
if (hadError) {
|
|
52613
52654
|
return void 0;
|
|
52614
52655
|
}
|
|
@@ -52621,16 +52662,16 @@ function createTypeChecker(host) {
|
|
|
52621
52662
|
return factory.createKeywordTypeNode(157 /* UnknownKeyword */);
|
|
52622
52663
|
}
|
|
52623
52664
|
if (isJSDocNullableType(node)) {
|
|
52624
|
-
return factory.createUnionTypeNode([visitNode(node.type, visitExistingNodeTreeSymbols), factory.createLiteralTypeNode(factory.createNull())]);
|
|
52665
|
+
return factory.createUnionTypeNode([visitNode(node.type, visitExistingNodeTreeSymbols, isTypeNode), factory.createLiteralTypeNode(factory.createNull())]);
|
|
52625
52666
|
}
|
|
52626
52667
|
if (isJSDocOptionalType(node)) {
|
|
52627
|
-
return factory.createUnionTypeNode([visitNode(node.type, visitExistingNodeTreeSymbols), factory.createKeywordTypeNode(155 /* UndefinedKeyword */)]);
|
|
52668
|
+
return factory.createUnionTypeNode([visitNode(node.type, visitExistingNodeTreeSymbols, isTypeNode), factory.createKeywordTypeNode(155 /* UndefinedKeyword */)]);
|
|
52628
52669
|
}
|
|
52629
52670
|
if (isJSDocNonNullableType(node)) {
|
|
52630
52671
|
return visitNode(node.type, visitExistingNodeTreeSymbols);
|
|
52631
52672
|
}
|
|
52632
52673
|
if (isJSDocVariadicType(node)) {
|
|
52633
|
-
return factory.createArrayTypeNode(visitNode(node.type, visitExistingNodeTreeSymbols));
|
|
52674
|
+
return factory.createArrayTypeNode(visitNode(node.type, visitExistingNodeTreeSymbols, isTypeNode));
|
|
52634
52675
|
}
|
|
52635
52676
|
if (isJSDocTypeLiteral(node)) {
|
|
52636
52677
|
return factory.createTypeLiteralNode(map(node.jsDocPropertyTags, (t) => {
|
|
@@ -52642,7 +52683,7 @@ function createTypeChecker(host) {
|
|
|
52642
52683
|
void 0,
|
|
52643
52684
|
name,
|
|
52644
52685
|
t.isBracketed || t.typeExpression && isJSDocOptionalType(t.typeExpression.type) ? factory.createToken(57 /* QuestionToken */) : void 0,
|
|
52645
|
-
overrideTypeNode || t.typeExpression && visitNode(t.typeExpression.type, visitExistingNodeTreeSymbols) || factory.createKeywordTypeNode(131 /* AnyKeyword */)
|
|
52686
|
+
overrideTypeNode || t.typeExpression && visitNode(t.typeExpression.type, visitExistingNodeTreeSymbols, isTypeNode) || factory.createKeywordTypeNode(131 /* AnyKeyword */)
|
|
52646
52687
|
);
|
|
52647
52688
|
}));
|
|
52648
52689
|
}
|
|
@@ -52661,9 +52702,9 @@ function createTypeChecker(host) {
|
|
|
52661
52702
|
"x",
|
|
52662
52703
|
/*questionToken*/
|
|
52663
52704
|
void 0,
|
|
52664
|
-
visitNode(node.typeArguments[0], visitExistingNodeTreeSymbols)
|
|
52705
|
+
visitNode(node.typeArguments[0], visitExistingNodeTreeSymbols, isTypeNode)
|
|
52665
52706
|
)],
|
|
52666
|
-
visitNode(node.typeArguments[1], visitExistingNodeTreeSymbols)
|
|
52707
|
+
visitNode(node.typeArguments[1], visitExistingNodeTreeSymbols, isTypeNode)
|
|
52667
52708
|
)]);
|
|
52668
52709
|
}
|
|
52669
52710
|
if (isJSDocFunctionType(node)) {
|
|
@@ -52672,33 +52713,33 @@ function createTypeChecker(host) {
|
|
|
52672
52713
|
return factory.createConstructorTypeNode(
|
|
52673
52714
|
/*modifiers*/
|
|
52674
52715
|
void 0,
|
|
52675
|
-
visitNodes2(node.typeParameters, visitExistingNodeTreeSymbols),
|
|
52716
|
+
visitNodes2(node.typeParameters, visitExistingNodeTreeSymbols, isTypeParameterDeclaration),
|
|
52676
52717
|
mapDefined(node.parameters, (p, i) => p.name && isIdentifier(p.name) && p.name.escapedText === "new" ? (newTypeNode = p.type, void 0) : factory.createParameterDeclaration(
|
|
52677
52718
|
/*modifiers*/
|
|
52678
52719
|
void 0,
|
|
52679
52720
|
getEffectiveDotDotDotForParameter(p),
|
|
52680
52721
|
getNameForJSDocFunctionParameter(p, i),
|
|
52681
52722
|
p.questionToken,
|
|
52682
|
-
visitNode(p.type, visitExistingNodeTreeSymbols),
|
|
52723
|
+
visitNode(p.type, visitExistingNodeTreeSymbols, isTypeNode),
|
|
52683
52724
|
/*initializer*/
|
|
52684
52725
|
void 0
|
|
52685
52726
|
)),
|
|
52686
|
-
visitNode(newTypeNode || node.type, visitExistingNodeTreeSymbols) || factory.createKeywordTypeNode(131 /* AnyKeyword */)
|
|
52727
|
+
visitNode(newTypeNode || node.type, visitExistingNodeTreeSymbols, isTypeNode) || factory.createKeywordTypeNode(131 /* AnyKeyword */)
|
|
52687
52728
|
);
|
|
52688
52729
|
} else {
|
|
52689
52730
|
return factory.createFunctionTypeNode(
|
|
52690
|
-
visitNodes2(node.typeParameters, visitExistingNodeTreeSymbols),
|
|
52731
|
+
visitNodes2(node.typeParameters, visitExistingNodeTreeSymbols, isTypeParameterDeclaration),
|
|
52691
52732
|
map(node.parameters, (p, i) => factory.createParameterDeclaration(
|
|
52692
52733
|
/*modifiers*/
|
|
52693
52734
|
void 0,
|
|
52694
52735
|
getEffectiveDotDotDotForParameter(p),
|
|
52695
52736
|
getNameForJSDocFunctionParameter(p, i),
|
|
52696
52737
|
p.questionToken,
|
|
52697
|
-
visitNode(p.type, visitExistingNodeTreeSymbols),
|
|
52738
|
+
visitNode(p.type, visitExistingNodeTreeSymbols, isTypeNode),
|
|
52698
52739
|
/*initializer*/
|
|
52699
52740
|
void 0
|
|
52700
52741
|
)),
|
|
52701
|
-
visitNode(node.type, visitExistingNodeTreeSymbols) || factory.createKeywordTypeNode(131 /* AnyKeyword */)
|
|
52742
|
+
visitNode(node.type, visitExistingNodeTreeSymbols, isTypeNode) || factory.createKeywordTypeNode(131 /* AnyKeyword */)
|
|
52702
52743
|
);
|
|
52703
52744
|
}
|
|
52704
52745
|
}
|
|
@@ -53620,7 +53661,7 @@ function createTypeChecker(host) {
|
|
|
53620
53661
|
break;
|
|
53621
53662
|
}
|
|
53622
53663
|
case 268 /* ImportEqualsDeclaration */:
|
|
53623
|
-
if (target.escapedName === "export=" /* ExportEquals */ && some(target.declarations, isJsonSourceFile)) {
|
|
53664
|
+
if (target.escapedName === "export=" /* ExportEquals */ && some(target.declarations, (d) => isSourceFile(d) && isJsonSourceFile(d))) {
|
|
53624
53665
|
serializeMaybeAliasAssignment(symbol);
|
|
53625
53666
|
break;
|
|
53626
53667
|
}
|
|
@@ -54714,13 +54755,7 @@ function createTypeChecker(host) {
|
|
|
54714
54755
|
}
|
|
54715
54756
|
const isProperty = isPropertyDeclaration(declaration) && !hasAccessorModifier(declaration) || isPropertySignature(declaration) || isJSDocPropertyTag(declaration);
|
|
54716
54757
|
const isOptional = includeOptionality && isOptionalDeclaration(declaration);
|
|
54717
|
-
|
|
54718
|
-
if (isCatchClauseVariableDeclarationOrBindingElement(declaration)) {
|
|
54719
|
-
if (declaredType) {
|
|
54720
|
-
return isTypeAny(declaredType) || declaredType === unknownType ? declaredType : errorType;
|
|
54721
|
-
}
|
|
54722
|
-
declaredType = useUnknownInCatchVariables ? unknownType : anyType;
|
|
54723
|
-
}
|
|
54758
|
+
const declaredType = tryGetTypeFromEffectiveTypeNode(declaration);
|
|
54724
54759
|
if (declaredType) {
|
|
54725
54760
|
return addOptionality(declaredType, isProperty, isOptional);
|
|
54726
54761
|
}
|
|
@@ -55299,6 +55334,14 @@ function createTypeChecker(host) {
|
|
|
55299
55334
|
}
|
|
55300
55335
|
Debug.assertIsDefined(symbol.valueDeclaration);
|
|
55301
55336
|
const declaration = symbol.valueDeclaration;
|
|
55337
|
+
if (isCatchClauseVariableDeclarationOrBindingElement(declaration)) {
|
|
55338
|
+
const typeNode = getEffectiveTypeAnnotationNode(declaration);
|
|
55339
|
+
if (typeNode === void 0) {
|
|
55340
|
+
return useUnknownInCatchVariables ? unknownType : anyType;
|
|
55341
|
+
}
|
|
55342
|
+
const type2 = getTypeOfNode(typeNode);
|
|
55343
|
+
return isTypeAny(type2) || type2 === unknownType ? type2 : errorType;
|
|
55344
|
+
}
|
|
55302
55345
|
if (isSourceFile(declaration) && isJsonSourceFile(declaration)) {
|
|
55303
55346
|
if (!declaration.statements.length) {
|
|
55304
55347
|
return emptyObjectType;
|
|
@@ -80530,10 +80573,14 @@ function createTypeChecker(host) {
|
|
|
80530
80573
|
if (catchClause) {
|
|
80531
80574
|
if (catchClause.variableDeclaration) {
|
|
80532
80575
|
const declaration = catchClause.variableDeclaration;
|
|
80533
|
-
|
|
80534
|
-
const typeNode = getEffectiveTypeAnnotationNode(declaration);
|
|
80576
|
+
const typeNode = getEffectiveTypeAnnotationNode(getRootDeclaration(declaration));
|
|
80535
80577
|
if (typeNode) {
|
|
80536
|
-
const type =
|
|
80578
|
+
const type = getTypeForVariableLikeDeclaration(
|
|
80579
|
+
declaration,
|
|
80580
|
+
/*includeOptionality*/
|
|
80581
|
+
false,
|
|
80582
|
+
0 /* Normal */
|
|
80583
|
+
);
|
|
80537
80584
|
if (type && !(type.flags & 3 /* AnyOrUnknown */)) {
|
|
80538
80585
|
grammarErrorOnFirstToken(typeNode, Diagnostics.Catch_clause_variable_type_annotation_must_be_any_or_unknown_if_specified);
|
|
80539
80586
|
}
|
|
@@ -85927,13 +85974,10 @@ var SymbolTrackerImpl = class {
|
|
|
85927
85974
|
|
|
85928
85975
|
// src/compiler/visitorPublic.ts
|
|
85929
85976
|
function visitNode(node, visitor, test, lift) {
|
|
85930
|
-
if (node === void 0
|
|
85977
|
+
if (node === void 0) {
|
|
85931
85978
|
return node;
|
|
85932
85979
|
}
|
|
85933
85980
|
const visited = visitor(node);
|
|
85934
|
-
if (visited === node) {
|
|
85935
|
-
return node;
|
|
85936
|
-
}
|
|
85937
85981
|
let visitedNode;
|
|
85938
85982
|
if (visited === void 0) {
|
|
85939
85983
|
return void 0;
|
|
@@ -85946,7 +85990,7 @@ function visitNode(node, visitor, test, lift) {
|
|
|
85946
85990
|
return visitedNode;
|
|
85947
85991
|
}
|
|
85948
85992
|
function visitNodes2(nodes, visitor, test, start2, count) {
|
|
85949
|
-
if (nodes === void 0
|
|
85993
|
+
if (nodes === void 0) {
|
|
85950
85994
|
return nodes;
|
|
85951
85995
|
}
|
|
85952
85996
|
const length2 = nodes.length;
|
|
@@ -85995,25 +86039,30 @@ function visitArrayWorker(nodes, visitor, test, start2, count) {
|
|
|
85995
86039
|
}
|
|
85996
86040
|
for (let i = 0; i < count; i++) {
|
|
85997
86041
|
const node = nodes[i + start2];
|
|
85998
|
-
const visited = node !== void 0 ? visitor(node) : void 0;
|
|
86042
|
+
const visited = node !== void 0 ? visitor ? visitor(node) : node : void 0;
|
|
85999
86043
|
if (updated !== void 0 || visited === void 0 || visited !== node) {
|
|
86000
86044
|
if (updated === void 0) {
|
|
86001
86045
|
updated = nodes.slice(0, i);
|
|
86046
|
+
Debug.assertEachNode(updated, test);
|
|
86002
86047
|
}
|
|
86003
86048
|
if (visited) {
|
|
86004
86049
|
if (isArray(visited)) {
|
|
86005
86050
|
for (const visitedNode of visited) {
|
|
86006
|
-
|
|
86051
|
+
Debug.assertNode(visitedNode, test);
|
|
86007
86052
|
updated.push(visitedNode);
|
|
86008
86053
|
}
|
|
86009
86054
|
} else {
|
|
86010
|
-
|
|
86055
|
+
Debug.assertNode(visited, test);
|
|
86011
86056
|
updated.push(visited);
|
|
86012
86057
|
}
|
|
86013
86058
|
}
|
|
86014
86059
|
}
|
|
86015
86060
|
}
|
|
86016
|
-
|
|
86061
|
+
if (updated) {
|
|
86062
|
+
return updated;
|
|
86063
|
+
}
|
|
86064
|
+
Debug.assertEachNode(nodes, test);
|
|
86065
|
+
return nodes;
|
|
86017
86066
|
}
|
|
86018
86067
|
function visitLexicalEnvironment(statements, visitor, context, start2, ensureUseStrict, nodesVisitor = visitNodes2) {
|
|
86019
86068
|
context.startLexicalEnvironment();
|
|
@@ -86027,7 +86076,7 @@ function visitParameterList(nodes, visitor, context, nodesVisitor = visitNodes2)
|
|
|
86027
86076
|
context.startLexicalEnvironment();
|
|
86028
86077
|
if (nodes) {
|
|
86029
86078
|
context.setLexicalEnvironmentFlags(1 /* InParameters */, true);
|
|
86030
|
-
updated = nodesVisitor(nodes, visitor,
|
|
86079
|
+
updated = nodesVisitor(nodes, visitor, isParameter);
|
|
86031
86080
|
if (context.getLexicalEnvironmentFlags() & 2 /* VariablesHoistedInParameters */ && getEmitScriptTarget(context.getCompilerOptions()) >= 2 /* ES2015 */) {
|
|
86032
86081
|
updated = addDefaultValueAssignmentsIfNeeded(updated, context);
|
|
86033
86082
|
}
|
|
@@ -86149,6 +86198,7 @@ function visitFunctionBody(node, visitor, context, nodeVisitor = visitNode) {
|
|
|
86149
86198
|
function visitIterationBody(body, visitor, context, nodeVisitor = visitNode) {
|
|
86150
86199
|
context.startBlockScope();
|
|
86151
86200
|
const updated = nodeVisitor(body, visitor, isStatement, context.factory.liftToBlock);
|
|
86201
|
+
Debug.assert(updated);
|
|
86152
86202
|
const declarations = context.endBlockScope();
|
|
86153
86203
|
if (some(declarations)) {
|
|
86154
86204
|
if (isBlock(updated)) {
|
|
@@ -86171,14 +86221,14 @@ var visitEachChildTable = {
|
|
|
86171
86221
|
[163 /* QualifiedName */]: function visitEachChildOfQualifiedName(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
86172
86222
|
return context.factory.updateQualifiedName(
|
|
86173
86223
|
node,
|
|
86174
|
-
nodeVisitor(node.left, visitor, isEntityName),
|
|
86175
|
-
nodeVisitor(node.right, visitor, isIdentifier)
|
|
86224
|
+
Debug.checkDefined(nodeVisitor(node.left, visitor, isEntityName)),
|
|
86225
|
+
Debug.checkDefined(nodeVisitor(node.right, visitor, isIdentifier))
|
|
86176
86226
|
);
|
|
86177
86227
|
},
|
|
86178
86228
|
[164 /* ComputedPropertyName */]: function visitEachChildOfComputedPropertyName(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
86179
86229
|
return context.factory.updateComputedPropertyName(
|
|
86180
86230
|
node,
|
|
86181
|
-
nodeVisitor(node.expression, visitor, isExpression)
|
|
86231
|
+
Debug.checkDefined(nodeVisitor(node.expression, visitor, isExpression))
|
|
86182
86232
|
);
|
|
86183
86233
|
},
|
|
86184
86234
|
// Signature elements
|
|
@@ -86186,7 +86236,7 @@ var visitEachChildTable = {
|
|
|
86186
86236
|
return context.factory.updateTypeParameterDeclaration(
|
|
86187
86237
|
node,
|
|
86188
86238
|
nodesVisitor(node.modifiers, visitor, isModifier),
|
|
86189
|
-
nodeVisitor(node.name, visitor, isIdentifier),
|
|
86239
|
+
Debug.checkDefined(nodeVisitor(node.name, visitor, isIdentifier)),
|
|
86190
86240
|
nodeVisitor(node.constraint, visitor, isTypeNode),
|
|
86191
86241
|
nodeVisitor(node.default, visitor, isTypeNode)
|
|
86192
86242
|
);
|
|
@@ -86195,9 +86245,9 @@ var visitEachChildTable = {
|
|
|
86195
86245
|
return context.factory.updateParameterDeclaration(
|
|
86196
86246
|
node,
|
|
86197
86247
|
nodesVisitor(node.modifiers, visitor, isModifierLike),
|
|
86198
|
-
nodeVisitor(node.dotDotDotToken, tokenVisitor, isDotDotDotToken),
|
|
86199
|
-
nodeVisitor(node.name, visitor, isBindingName),
|
|
86200
|
-
nodeVisitor(node.questionToken, tokenVisitor, isQuestionToken),
|
|
86248
|
+
tokenVisitor ? nodeVisitor(node.dotDotDotToken, tokenVisitor, isDotDotDotToken) : node.dotDotDotToken,
|
|
86249
|
+
Debug.checkDefined(nodeVisitor(node.name, visitor, isBindingName)),
|
|
86250
|
+
tokenVisitor ? nodeVisitor(node.questionToken, tokenVisitor, isQuestionToken) : node.questionToken,
|
|
86201
86251
|
nodeVisitor(node.type, visitor, isTypeNode),
|
|
86202
86252
|
nodeVisitor(node.initializer, visitor, isExpression)
|
|
86203
86253
|
);
|
|
@@ -86205,7 +86255,7 @@ var visitEachChildTable = {
|
|
|
86205
86255
|
[167 /* Decorator */]: function visitEachChildOfDecorator(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
86206
86256
|
return context.factory.updateDecorator(
|
|
86207
86257
|
node,
|
|
86208
|
-
nodeVisitor(node.expression, visitor, isExpression)
|
|
86258
|
+
Debug.checkDefined(nodeVisitor(node.expression, visitor, isExpression))
|
|
86209
86259
|
);
|
|
86210
86260
|
},
|
|
86211
86261
|
// Type elements
|
|
@@ -86213,19 +86263,19 @@ var visitEachChildTable = {
|
|
|
86213
86263
|
return context.factory.updatePropertySignature(
|
|
86214
86264
|
node,
|
|
86215
86265
|
nodesVisitor(node.modifiers, visitor, isModifier),
|
|
86216
|
-
nodeVisitor(node.name, visitor, isPropertyName),
|
|
86217
|
-
nodeVisitor(node.questionToken, tokenVisitor,
|
|
86266
|
+
Debug.checkDefined(nodeVisitor(node.name, visitor, isPropertyName)),
|
|
86267
|
+
tokenVisitor ? nodeVisitor(node.questionToken, tokenVisitor, isQuestionToken) : node.questionToken,
|
|
86218
86268
|
nodeVisitor(node.type, visitor, isTypeNode)
|
|
86219
86269
|
);
|
|
86220
86270
|
},
|
|
86221
86271
|
[169 /* PropertyDeclaration */]: function visitEachChildOfPropertyDeclaration(node, visitor, context, nodesVisitor, nodeVisitor, tokenVisitor) {
|
|
86222
|
-
var _a2;
|
|
86272
|
+
var _a2, _b;
|
|
86223
86273
|
return context.factory.updatePropertyDeclaration(
|
|
86224
86274
|
node,
|
|
86225
86275
|
nodesVisitor(node.modifiers, visitor, isModifierLike),
|
|
86226
|
-
nodeVisitor(node.name, visitor, isPropertyName),
|
|
86276
|
+
Debug.checkDefined(nodeVisitor(node.name, visitor, isPropertyName)),
|
|
86227
86277
|
// QuestionToken and ExclamationToken are mutually exclusive in PropertyDeclaration
|
|
86228
|
-
nodeVisitor((_a2 = node.questionToken) != null ? _a2 : node.exclamationToken, tokenVisitor, isQuestionOrExclamationToken),
|
|
86278
|
+
tokenVisitor ? nodeVisitor((_a2 = node.questionToken) != null ? _a2 : node.exclamationToken, tokenVisitor, isQuestionOrExclamationToken) : (_b = node.questionToken) != null ? _b : node.exclamationToken,
|
|
86229
86279
|
nodeVisitor(node.type, visitor, isTypeNode),
|
|
86230
86280
|
nodeVisitor(node.initializer, visitor, isExpression)
|
|
86231
86281
|
);
|
|
@@ -86234,10 +86284,10 @@ var visitEachChildTable = {
|
|
|
86234
86284
|
return context.factory.updateMethodSignature(
|
|
86235
86285
|
node,
|
|
86236
86286
|
nodesVisitor(node.modifiers, visitor, isModifier),
|
|
86237
|
-
nodeVisitor(node.name, visitor, isPropertyName),
|
|
86238
|
-
nodeVisitor(node.questionToken, tokenVisitor, isQuestionToken),
|
|
86287
|
+
Debug.checkDefined(nodeVisitor(node.name, visitor, isPropertyName)),
|
|
86288
|
+
tokenVisitor ? nodeVisitor(node.questionToken, tokenVisitor, isQuestionToken) : node.questionToken,
|
|
86239
86289
|
nodesVisitor(node.typeParameters, visitor, isTypeParameterDeclaration),
|
|
86240
|
-
nodesVisitor(node.parameters, visitor,
|
|
86290
|
+
nodesVisitor(node.parameters, visitor, isParameter),
|
|
86241
86291
|
nodeVisitor(node.type, visitor, isTypeNode)
|
|
86242
86292
|
);
|
|
86243
86293
|
},
|
|
@@ -86245,9 +86295,9 @@ var visitEachChildTable = {
|
|
|
86245
86295
|
return context.factory.updateMethodDeclaration(
|
|
86246
86296
|
node,
|
|
86247
86297
|
nodesVisitor(node.modifiers, visitor, isModifierLike),
|
|
86248
|
-
nodeVisitor(node.asteriskToken, tokenVisitor, isAsteriskToken),
|
|
86249
|
-
nodeVisitor(node.name, visitor, isPropertyName),
|
|
86250
|
-
nodeVisitor(node.questionToken, tokenVisitor, isQuestionToken),
|
|
86298
|
+
tokenVisitor ? nodeVisitor(node.asteriskToken, tokenVisitor, isAsteriskToken) : node.asteriskToken,
|
|
86299
|
+
Debug.checkDefined(nodeVisitor(node.name, visitor, isPropertyName)),
|
|
86300
|
+
tokenVisitor ? nodeVisitor(node.questionToken, tokenVisitor, isQuestionToken) : node.questionToken,
|
|
86251
86301
|
nodesVisitor(node.typeParameters, visitor, isTypeParameterDeclaration),
|
|
86252
86302
|
visitParameterList(node.parameters, visitor, context, nodesVisitor),
|
|
86253
86303
|
nodeVisitor(node.type, visitor, isTypeNode),
|
|
@@ -86266,7 +86316,7 @@ var visitEachChildTable = {
|
|
|
86266
86316
|
return context.factory.updateGetAccessorDeclaration(
|
|
86267
86317
|
node,
|
|
86268
86318
|
nodesVisitor(node.modifiers, visitor, isModifierLike),
|
|
86269
|
-
nodeVisitor(node.name, visitor, isPropertyName),
|
|
86319
|
+
Debug.checkDefined(nodeVisitor(node.name, visitor, isPropertyName)),
|
|
86270
86320
|
visitParameterList(node.parameters, visitor, context, nodesVisitor),
|
|
86271
86321
|
nodeVisitor(node.type, visitor, isTypeNode),
|
|
86272
86322
|
visitFunctionBody(node.body, visitor, context, nodeVisitor)
|
|
@@ -86276,7 +86326,7 @@ var visitEachChildTable = {
|
|
|
86276
86326
|
return context.factory.updateSetAccessorDeclaration(
|
|
86277
86327
|
node,
|
|
86278
86328
|
nodesVisitor(node.modifiers, visitor, isModifierLike),
|
|
86279
|
-
nodeVisitor(node.name, visitor, isPropertyName),
|
|
86329
|
+
Debug.checkDefined(nodeVisitor(node.name, visitor, isPropertyName)),
|
|
86280
86330
|
visitParameterList(node.parameters, visitor, context, nodesVisitor),
|
|
86281
86331
|
visitFunctionBody(node.body, visitor, context, nodeVisitor)
|
|
86282
86332
|
);
|
|
@@ -86293,7 +86343,7 @@ var visitEachChildTable = {
|
|
|
86293
86343
|
return context.factory.updateCallSignature(
|
|
86294
86344
|
node,
|
|
86295
86345
|
nodesVisitor(node.typeParameters, visitor, isTypeParameterDeclaration),
|
|
86296
|
-
nodesVisitor(node.parameters, visitor,
|
|
86346
|
+
nodesVisitor(node.parameters, visitor, isParameter),
|
|
86297
86347
|
nodeVisitor(node.type, visitor, isTypeNode)
|
|
86298
86348
|
);
|
|
86299
86349
|
},
|
|
@@ -86301,7 +86351,7 @@ var visitEachChildTable = {
|
|
|
86301
86351
|
return context.factory.updateConstructSignature(
|
|
86302
86352
|
node,
|
|
86303
86353
|
nodesVisitor(node.typeParameters, visitor, isTypeParameterDeclaration),
|
|
86304
|
-
nodesVisitor(node.parameters, visitor,
|
|
86354
|
+
nodesVisitor(node.parameters, visitor, isParameter),
|
|
86305
86355
|
nodeVisitor(node.type, visitor, isTypeNode)
|
|
86306
86356
|
);
|
|
86307
86357
|
},
|
|
@@ -86309,8 +86359,8 @@ var visitEachChildTable = {
|
|
|
86309
86359
|
return context.factory.updateIndexSignature(
|
|
86310
86360
|
node,
|
|
86311
86361
|
nodesVisitor(node.modifiers, visitor, isModifier),
|
|
86312
|
-
nodesVisitor(node.parameters, visitor,
|
|
86313
|
-
nodeVisitor(node.type, visitor, isTypeNode)
|
|
86362
|
+
nodesVisitor(node.parameters, visitor, isParameter),
|
|
86363
|
+
Debug.checkDefined(nodeVisitor(node.type, visitor, isTypeNode))
|
|
86314
86364
|
);
|
|
86315
86365
|
},
|
|
86316
86366
|
// Types
|
|
@@ -86318,14 +86368,14 @@ var visitEachChildTable = {
|
|
|
86318
86368
|
return context.factory.updateTypePredicateNode(
|
|
86319
86369
|
node,
|
|
86320
86370
|
nodeVisitor(node.assertsModifier, visitor, isAssertsKeyword),
|
|
86321
|
-
nodeVisitor(node.parameterName, visitor, isIdentifierOrThisTypeNode),
|
|
86371
|
+
Debug.checkDefined(nodeVisitor(node.parameterName, visitor, isIdentifierOrThisTypeNode)),
|
|
86322
86372
|
nodeVisitor(node.type, visitor, isTypeNode)
|
|
86323
86373
|
);
|
|
86324
86374
|
},
|
|
86325
86375
|
[180 /* TypeReference */]: function visitEachChildOfTypeReferenceNode(node, visitor, context, nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
86326
86376
|
return context.factory.updateTypeReferenceNode(
|
|
86327
86377
|
node,
|
|
86328
|
-
nodeVisitor(node.typeName, visitor, isEntityName),
|
|
86378
|
+
Debug.checkDefined(nodeVisitor(node.typeName, visitor, isEntityName)),
|
|
86329
86379
|
nodesVisitor(node.typeArguments, visitor, isTypeNode)
|
|
86330
86380
|
);
|
|
86331
86381
|
},
|
|
@@ -86333,8 +86383,8 @@ var visitEachChildTable = {
|
|
|
86333
86383
|
return context.factory.updateFunctionTypeNode(
|
|
86334
86384
|
node,
|
|
86335
86385
|
nodesVisitor(node.typeParameters, visitor, isTypeParameterDeclaration),
|
|
86336
|
-
nodesVisitor(node.parameters, visitor,
|
|
86337
|
-
nodeVisitor(node.type, visitor, isTypeNode)
|
|
86386
|
+
nodesVisitor(node.parameters, visitor, isParameter),
|
|
86387
|
+
Debug.checkDefined(nodeVisitor(node.type, visitor, isTypeNode))
|
|
86338
86388
|
);
|
|
86339
86389
|
},
|
|
86340
86390
|
[182 /* ConstructorType */]: function visitEachChildOfConstructorTypeNode(node, visitor, context, nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
@@ -86342,14 +86392,14 @@ var visitEachChildTable = {
|
|
|
86342
86392
|
node,
|
|
86343
86393
|
nodesVisitor(node.modifiers, visitor, isModifier),
|
|
86344
86394
|
nodesVisitor(node.typeParameters, visitor, isTypeParameterDeclaration),
|
|
86345
|
-
nodesVisitor(node.parameters, visitor,
|
|
86346
|
-
nodeVisitor(node.type, visitor, isTypeNode)
|
|
86395
|
+
nodesVisitor(node.parameters, visitor, isParameter),
|
|
86396
|
+
Debug.checkDefined(nodeVisitor(node.type, visitor, isTypeNode))
|
|
86347
86397
|
);
|
|
86348
86398
|
},
|
|
86349
86399
|
[183 /* TypeQuery */]: function visitEachChildOfTypeQueryNode(node, visitor, context, nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
86350
86400
|
return context.factory.updateTypeQueryNode(
|
|
86351
86401
|
node,
|
|
86352
|
-
nodeVisitor(node.exprName, visitor, isEntityName),
|
|
86402
|
+
Debug.checkDefined(nodeVisitor(node.exprName, visitor, isEntityName)),
|
|
86353
86403
|
nodesVisitor(node.typeArguments, visitor, isTypeNode)
|
|
86354
86404
|
);
|
|
86355
86405
|
},
|
|
@@ -86362,7 +86412,7 @@ var visitEachChildTable = {
|
|
|
86362
86412
|
[185 /* ArrayType */]: function visitEachChildOfArrayTypeNode(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
86363
86413
|
return context.factory.updateArrayTypeNode(
|
|
86364
86414
|
node,
|
|
86365
|
-
nodeVisitor(node.elementType, visitor, isTypeNode)
|
|
86415
|
+
Debug.checkDefined(nodeVisitor(node.elementType, visitor, isTypeNode))
|
|
86366
86416
|
);
|
|
86367
86417
|
},
|
|
86368
86418
|
[186 /* TupleType */]: function visitEachChildOfTupleTypeNode(node, visitor, context, nodesVisitor, _nodeVisitor, _tokenVisitor) {
|
|
@@ -86374,13 +86424,13 @@ var visitEachChildTable = {
|
|
|
86374
86424
|
[187 /* OptionalType */]: function visitEachChildOfOptionalTypeNode(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
86375
86425
|
return context.factory.updateOptionalTypeNode(
|
|
86376
86426
|
node,
|
|
86377
|
-
nodeVisitor(node.type, visitor, isTypeNode)
|
|
86427
|
+
Debug.checkDefined(nodeVisitor(node.type, visitor, isTypeNode))
|
|
86378
86428
|
);
|
|
86379
86429
|
},
|
|
86380
86430
|
[188 /* RestType */]: function visitEachChildOfRestTypeNode(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
86381
86431
|
return context.factory.updateRestTypeNode(
|
|
86382
86432
|
node,
|
|
86383
|
-
nodeVisitor(node.type, visitor, isTypeNode)
|
|
86433
|
+
Debug.checkDefined(nodeVisitor(node.type, visitor, isTypeNode))
|
|
86384
86434
|
);
|
|
86385
86435
|
},
|
|
86386
86436
|
[189 /* UnionType */]: function visitEachChildOfUnionTypeNode(node, visitor, context, nodesVisitor, _nodeVisitor, _tokenVisitor) {
|
|
@@ -86398,22 +86448,22 @@ var visitEachChildTable = {
|
|
|
86398
86448
|
[191 /* ConditionalType */]: function visitEachChildOfConditionalTypeNode(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
86399
86449
|
return context.factory.updateConditionalTypeNode(
|
|
86400
86450
|
node,
|
|
86401
|
-
nodeVisitor(node.checkType, visitor, isTypeNode),
|
|
86402
|
-
nodeVisitor(node.extendsType, visitor, isTypeNode),
|
|
86403
|
-
nodeVisitor(node.trueType, visitor, isTypeNode),
|
|
86404
|
-
nodeVisitor(node.falseType, visitor, isTypeNode)
|
|
86451
|
+
Debug.checkDefined(nodeVisitor(node.checkType, visitor, isTypeNode)),
|
|
86452
|
+
Debug.checkDefined(nodeVisitor(node.extendsType, visitor, isTypeNode)),
|
|
86453
|
+
Debug.checkDefined(nodeVisitor(node.trueType, visitor, isTypeNode)),
|
|
86454
|
+
Debug.checkDefined(nodeVisitor(node.falseType, visitor, isTypeNode))
|
|
86405
86455
|
);
|
|
86406
86456
|
},
|
|
86407
86457
|
[192 /* InferType */]: function visitEachChildOfInferTypeNode(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
86408
86458
|
return context.factory.updateInferTypeNode(
|
|
86409
86459
|
node,
|
|
86410
|
-
nodeVisitor(node.typeParameter, visitor, isTypeParameterDeclaration)
|
|
86460
|
+
Debug.checkDefined(nodeVisitor(node.typeParameter, visitor, isTypeParameterDeclaration))
|
|
86411
86461
|
);
|
|
86412
86462
|
},
|
|
86413
86463
|
[202 /* ImportType */]: function visitEachChildOfImportTypeNode(node, visitor, context, nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
86414
86464
|
return context.factory.updateImportTypeNode(
|
|
86415
86465
|
node,
|
|
86416
|
-
nodeVisitor(node.argument, visitor, isTypeNode),
|
|
86466
|
+
Debug.checkDefined(nodeVisitor(node.argument, visitor, isTypeNode)),
|
|
86417
86467
|
nodeVisitor(node.assertions, visitor, isImportTypeAssertionContainer),
|
|
86418
86468
|
nodeVisitor(node.qualifier, visitor, isEntityName),
|
|
86419
86469
|
nodesVisitor(node.typeArguments, visitor, isTypeNode),
|
|
@@ -86423,45 +86473,45 @@ var visitEachChildTable = {
|
|
|
86423
86473
|
[298 /* ImportTypeAssertionContainer */]: function visitEachChildOfImportTypeAssertionContainer(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
86424
86474
|
return context.factory.updateImportTypeAssertionContainer(
|
|
86425
86475
|
node,
|
|
86426
|
-
nodeVisitor(node.assertClause, visitor, isAssertClause),
|
|
86476
|
+
Debug.checkDefined(nodeVisitor(node.assertClause, visitor, isAssertClause)),
|
|
86427
86477
|
node.multiLine
|
|
86428
86478
|
);
|
|
86429
86479
|
},
|
|
86430
86480
|
[199 /* NamedTupleMember */]: function visitEachChildOfNamedTupleMember(node, visitor, context, _nodesVisitor, nodeVisitor, tokenVisitor) {
|
|
86431
86481
|
return context.factory.updateNamedTupleMember(
|
|
86432
86482
|
node,
|
|
86433
|
-
nodeVisitor(node.dotDotDotToken, tokenVisitor, isDotDotDotToken),
|
|
86434
|
-
nodeVisitor(node.name, visitor, isIdentifier),
|
|
86435
|
-
nodeVisitor(node.questionToken, tokenVisitor, isQuestionToken),
|
|
86436
|
-
nodeVisitor(node.type, visitor, isTypeNode)
|
|
86483
|
+
tokenVisitor ? nodeVisitor(node.dotDotDotToken, tokenVisitor, isDotDotDotToken) : node.dotDotDotToken,
|
|
86484
|
+
Debug.checkDefined(nodeVisitor(node.name, visitor, isIdentifier)),
|
|
86485
|
+
tokenVisitor ? nodeVisitor(node.questionToken, tokenVisitor, isQuestionToken) : node.questionToken,
|
|
86486
|
+
Debug.checkDefined(nodeVisitor(node.type, visitor, isTypeNode))
|
|
86437
86487
|
);
|
|
86438
86488
|
},
|
|
86439
86489
|
[193 /* ParenthesizedType */]: function visitEachChildOfParenthesizedType(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
86440
86490
|
return context.factory.updateParenthesizedType(
|
|
86441
86491
|
node,
|
|
86442
|
-
nodeVisitor(node.type, visitor, isTypeNode)
|
|
86492
|
+
Debug.checkDefined(nodeVisitor(node.type, visitor, isTypeNode))
|
|
86443
86493
|
);
|
|
86444
86494
|
},
|
|
86445
86495
|
[195 /* TypeOperator */]: function visitEachChildOfTypeOperatorNode(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
86446
86496
|
return context.factory.updateTypeOperatorNode(
|
|
86447
86497
|
node,
|
|
86448
|
-
nodeVisitor(node.type, visitor, isTypeNode)
|
|
86498
|
+
Debug.checkDefined(nodeVisitor(node.type, visitor, isTypeNode))
|
|
86449
86499
|
);
|
|
86450
86500
|
},
|
|
86451
86501
|
[196 /* IndexedAccessType */]: function visitEachChildOfIndexedAccessType(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
86452
86502
|
return context.factory.updateIndexedAccessTypeNode(
|
|
86453
86503
|
node,
|
|
86454
|
-
nodeVisitor(node.objectType, visitor, isTypeNode),
|
|
86455
|
-
nodeVisitor(node.indexType, visitor, isTypeNode)
|
|
86504
|
+
Debug.checkDefined(nodeVisitor(node.objectType, visitor, isTypeNode)),
|
|
86505
|
+
Debug.checkDefined(nodeVisitor(node.indexType, visitor, isTypeNode))
|
|
86456
86506
|
);
|
|
86457
86507
|
},
|
|
86458
86508
|
[197 /* MappedType */]: function visitEachChildOfMappedType(node, visitor, context, nodesVisitor, nodeVisitor, tokenVisitor) {
|
|
86459
86509
|
return context.factory.updateMappedTypeNode(
|
|
86460
86510
|
node,
|
|
86461
|
-
nodeVisitor(node.readonlyToken, tokenVisitor, isReadonlyKeywordOrPlusOrMinusToken),
|
|
86462
|
-
nodeVisitor(node.typeParameter, visitor, isTypeParameterDeclaration),
|
|
86511
|
+
tokenVisitor ? nodeVisitor(node.readonlyToken, tokenVisitor, isReadonlyKeywordOrPlusOrMinusToken) : node.readonlyToken,
|
|
86512
|
+
Debug.checkDefined(nodeVisitor(node.typeParameter, visitor, isTypeParameterDeclaration)),
|
|
86463
86513
|
nodeVisitor(node.nameType, visitor, isTypeNode),
|
|
86464
|
-
nodeVisitor(node.questionToken, tokenVisitor, isQuestionOrPlusOrMinusToken),
|
|
86514
|
+
tokenVisitor ? nodeVisitor(node.questionToken, tokenVisitor, isQuestionOrPlusOrMinusToken) : node.questionToken,
|
|
86465
86515
|
nodeVisitor(node.type, visitor, isTypeNode),
|
|
86466
86516
|
nodesVisitor(node.members, visitor, isTypeElement)
|
|
86467
86517
|
);
|
|
@@ -86469,21 +86519,21 @@ var visitEachChildTable = {
|
|
|
86469
86519
|
[198 /* LiteralType */]: function visitEachChildOfLiteralTypeNode(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
86470
86520
|
return context.factory.updateLiteralTypeNode(
|
|
86471
86521
|
node,
|
|
86472
|
-
nodeVisitor(node.literal, visitor,
|
|
86522
|
+
Debug.checkDefined(nodeVisitor(node.literal, visitor, isLiteralTypeLiteral))
|
|
86473
86523
|
);
|
|
86474
86524
|
},
|
|
86475
86525
|
[200 /* TemplateLiteralType */]: function visitEachChildOfTemplateLiteralType(node, visitor, context, nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
86476
86526
|
return context.factory.updateTemplateLiteralType(
|
|
86477
86527
|
node,
|
|
86478
|
-
nodeVisitor(node.head, visitor, isTemplateHead),
|
|
86528
|
+
Debug.checkDefined(nodeVisitor(node.head, visitor, isTemplateHead)),
|
|
86479
86529
|
nodesVisitor(node.templateSpans, visitor, isTemplateLiteralTypeSpan)
|
|
86480
86530
|
);
|
|
86481
86531
|
},
|
|
86482
86532
|
[201 /* TemplateLiteralTypeSpan */]: function visitEachChildOfTemplateLiteralTypeSpan(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
86483
86533
|
return context.factory.updateTemplateLiteralTypeSpan(
|
|
86484
86534
|
node,
|
|
86485
|
-
nodeVisitor(node.type, visitor, isTypeNode),
|
|
86486
|
-
nodeVisitor(node.literal, visitor, isTemplateMiddleOrTemplateTail)
|
|
86535
|
+
Debug.checkDefined(nodeVisitor(node.type, visitor, isTypeNode)),
|
|
86536
|
+
Debug.checkDefined(nodeVisitor(node.literal, visitor, isTemplateMiddleOrTemplateTail))
|
|
86487
86537
|
);
|
|
86488
86538
|
},
|
|
86489
86539
|
// Binding patterns
|
|
@@ -86502,9 +86552,9 @@ var visitEachChildTable = {
|
|
|
86502
86552
|
[205 /* BindingElement */]: function visitEachChildOfBindingElement(node, visitor, context, _nodesVisitor, nodeVisitor, tokenVisitor) {
|
|
86503
86553
|
return context.factory.updateBindingElement(
|
|
86504
86554
|
node,
|
|
86505
|
-
nodeVisitor(node.dotDotDotToken, tokenVisitor, isDotDotDotToken),
|
|
86555
|
+
tokenVisitor ? nodeVisitor(node.dotDotDotToken, tokenVisitor, isDotDotDotToken) : node.dotDotDotToken,
|
|
86506
86556
|
nodeVisitor(node.propertyName, visitor, isPropertyName),
|
|
86507
|
-
nodeVisitor(node.name, visitor, isBindingName),
|
|
86557
|
+
Debug.checkDefined(nodeVisitor(node.name, visitor, isBindingName)),
|
|
86508
86558
|
nodeVisitor(node.initializer, visitor, isExpression)
|
|
86509
86559
|
);
|
|
86510
86560
|
},
|
|
@@ -86524,37 +86574,37 @@ var visitEachChildTable = {
|
|
|
86524
86574
|
[208 /* PropertyAccessExpression */]: function visitEachChildOfPropertyAccessExpression(node, visitor, context, _nodesVisitor, nodeVisitor, tokenVisitor) {
|
|
86525
86575
|
return isPropertyAccessChain(node) ? context.factory.updatePropertyAccessChain(
|
|
86526
86576
|
node,
|
|
86527
|
-
nodeVisitor(node.expression, visitor, isExpression),
|
|
86528
|
-
nodeVisitor(node.questionDotToken, tokenVisitor, isQuestionDotToken),
|
|
86529
|
-
nodeVisitor(node.name, visitor, isMemberName)
|
|
86577
|
+
Debug.checkDefined(nodeVisitor(node.expression, visitor, isExpression)),
|
|
86578
|
+
tokenVisitor ? nodeVisitor(node.questionDotToken, tokenVisitor, isQuestionDotToken) : node.questionDotToken,
|
|
86579
|
+
Debug.checkDefined(nodeVisitor(node.name, visitor, isMemberName))
|
|
86530
86580
|
) : context.factory.updatePropertyAccessExpression(
|
|
86531
86581
|
node,
|
|
86532
|
-
nodeVisitor(node.expression, visitor, isExpression),
|
|
86533
|
-
nodeVisitor(node.name, visitor, isMemberName)
|
|
86582
|
+
Debug.checkDefined(nodeVisitor(node.expression, visitor, isExpression)),
|
|
86583
|
+
Debug.checkDefined(nodeVisitor(node.name, visitor, isMemberName))
|
|
86534
86584
|
);
|
|
86535
86585
|
},
|
|
86536
86586
|
[209 /* ElementAccessExpression */]: function visitEachChildOfElementAccessExpression(node, visitor, context, _nodesVisitor, nodeVisitor, tokenVisitor) {
|
|
86537
86587
|
return isElementAccessChain(node) ? context.factory.updateElementAccessChain(
|
|
86538
86588
|
node,
|
|
86539
|
-
nodeVisitor(node.expression, visitor, isExpression),
|
|
86540
|
-
nodeVisitor(node.questionDotToken, tokenVisitor, isQuestionDotToken),
|
|
86541
|
-
nodeVisitor(node.argumentExpression, visitor, isExpression)
|
|
86589
|
+
Debug.checkDefined(nodeVisitor(node.expression, visitor, isExpression)),
|
|
86590
|
+
tokenVisitor ? nodeVisitor(node.questionDotToken, tokenVisitor, isQuestionDotToken) : node.questionDotToken,
|
|
86591
|
+
Debug.checkDefined(nodeVisitor(node.argumentExpression, visitor, isExpression))
|
|
86542
86592
|
) : context.factory.updateElementAccessExpression(
|
|
86543
86593
|
node,
|
|
86544
|
-
nodeVisitor(node.expression, visitor, isExpression),
|
|
86545
|
-
nodeVisitor(node.argumentExpression, visitor, isExpression)
|
|
86594
|
+
Debug.checkDefined(nodeVisitor(node.expression, visitor, isExpression)),
|
|
86595
|
+
Debug.checkDefined(nodeVisitor(node.argumentExpression, visitor, isExpression))
|
|
86546
86596
|
);
|
|
86547
86597
|
},
|
|
86548
86598
|
[210 /* CallExpression */]: function visitEachChildOfCallExpression(node, visitor, context, nodesVisitor, nodeVisitor, tokenVisitor) {
|
|
86549
86599
|
return isCallChain(node) ? context.factory.updateCallChain(
|
|
86550
86600
|
node,
|
|
86551
|
-
nodeVisitor(node.expression, visitor, isExpression),
|
|
86552
|
-
nodeVisitor(node.questionDotToken, tokenVisitor, isQuestionDotToken),
|
|
86601
|
+
Debug.checkDefined(nodeVisitor(node.expression, visitor, isExpression)),
|
|
86602
|
+
tokenVisitor ? nodeVisitor(node.questionDotToken, tokenVisitor, isQuestionDotToken) : node.questionDotToken,
|
|
86553
86603
|
nodesVisitor(node.typeArguments, visitor, isTypeNode),
|
|
86554
86604
|
nodesVisitor(node.arguments, visitor, isExpression)
|
|
86555
86605
|
) : context.factory.updateCallExpression(
|
|
86556
86606
|
node,
|
|
86557
|
-
nodeVisitor(node.expression, visitor, isExpression),
|
|
86607
|
+
Debug.checkDefined(nodeVisitor(node.expression, visitor, isExpression)),
|
|
86558
86608
|
nodesVisitor(node.typeArguments, visitor, isTypeNode),
|
|
86559
86609
|
nodesVisitor(node.arguments, visitor, isExpression)
|
|
86560
86610
|
);
|
|
@@ -86562,7 +86612,7 @@ var visitEachChildTable = {
|
|
|
86562
86612
|
[211 /* NewExpression */]: function visitEachChildOfNewExpression(node, visitor, context, nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
86563
86613
|
return context.factory.updateNewExpression(
|
|
86564
86614
|
node,
|
|
86565
|
-
nodeVisitor(node.expression, visitor, isExpression),
|
|
86615
|
+
Debug.checkDefined(nodeVisitor(node.expression, visitor, isExpression)),
|
|
86566
86616
|
nodesVisitor(node.typeArguments, visitor, isTypeNode),
|
|
86567
86617
|
nodesVisitor(node.arguments, visitor, isExpression)
|
|
86568
86618
|
);
|
|
@@ -86570,29 +86620,29 @@ var visitEachChildTable = {
|
|
|
86570
86620
|
[212 /* TaggedTemplateExpression */]: function visitEachChildOfTaggedTemplateExpression(node, visitor, context, nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
86571
86621
|
return context.factory.updateTaggedTemplateExpression(
|
|
86572
86622
|
node,
|
|
86573
|
-
nodeVisitor(node.tag, visitor, isExpression),
|
|
86623
|
+
Debug.checkDefined(nodeVisitor(node.tag, visitor, isExpression)),
|
|
86574
86624
|
nodesVisitor(node.typeArguments, visitor, isTypeNode),
|
|
86575
|
-
nodeVisitor(node.template, visitor, isTemplateLiteral)
|
|
86625
|
+
Debug.checkDefined(nodeVisitor(node.template, visitor, isTemplateLiteral))
|
|
86576
86626
|
);
|
|
86577
86627
|
},
|
|
86578
86628
|
[213 /* TypeAssertionExpression */]: function visitEachChildOfTypeAssertionExpression(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
86579
86629
|
return context.factory.updateTypeAssertion(
|
|
86580
86630
|
node,
|
|
86581
|
-
nodeVisitor(node.type, visitor, isTypeNode),
|
|
86582
|
-
nodeVisitor(node.expression, visitor, isExpression)
|
|
86631
|
+
Debug.checkDefined(nodeVisitor(node.type, visitor, isTypeNode)),
|
|
86632
|
+
Debug.checkDefined(nodeVisitor(node.expression, visitor, isExpression))
|
|
86583
86633
|
);
|
|
86584
86634
|
},
|
|
86585
86635
|
[214 /* ParenthesizedExpression */]: function visitEachChildOfParenthesizedExpression(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
86586
86636
|
return context.factory.updateParenthesizedExpression(
|
|
86587
86637
|
node,
|
|
86588
|
-
nodeVisitor(node.expression, visitor, isExpression)
|
|
86638
|
+
Debug.checkDefined(nodeVisitor(node.expression, visitor, isExpression))
|
|
86589
86639
|
);
|
|
86590
86640
|
},
|
|
86591
86641
|
[215 /* FunctionExpression */]: function visitEachChildOfFunctionExpression(node, visitor, context, nodesVisitor, nodeVisitor, tokenVisitor) {
|
|
86592
86642
|
return context.factory.updateFunctionExpression(
|
|
86593
86643
|
node,
|
|
86594
86644
|
nodesVisitor(node.modifiers, visitor, isModifier),
|
|
86595
|
-
nodeVisitor(node.asteriskToken, tokenVisitor, isAsteriskToken),
|
|
86645
|
+
tokenVisitor ? nodeVisitor(node.asteriskToken, tokenVisitor, isAsteriskToken) : node.asteriskToken,
|
|
86596
86646
|
nodeVisitor(node.name, visitor, isIdentifier),
|
|
86597
86647
|
nodesVisitor(node.typeParameters, visitor, isTypeParameterDeclaration),
|
|
86598
86648
|
visitParameterList(node.parameters, visitor, context, nodesVisitor),
|
|
@@ -86607,82 +86657,82 @@ var visitEachChildTable = {
|
|
|
86607
86657
|
nodesVisitor(node.typeParameters, visitor, isTypeParameterDeclaration),
|
|
86608
86658
|
visitParameterList(node.parameters, visitor, context, nodesVisitor),
|
|
86609
86659
|
nodeVisitor(node.type, visitor, isTypeNode),
|
|
86610
|
-
nodeVisitor(node.equalsGreaterThanToken, tokenVisitor, isEqualsGreaterThanToken),
|
|
86660
|
+
tokenVisitor ? Debug.checkDefined(nodeVisitor(node.equalsGreaterThanToken, tokenVisitor, isEqualsGreaterThanToken)) : node.equalsGreaterThanToken,
|
|
86611
86661
|
visitFunctionBody(node.body, visitor, context, nodeVisitor)
|
|
86612
86662
|
);
|
|
86613
86663
|
},
|
|
86614
86664
|
[217 /* DeleteExpression */]: function visitEachChildOfDeleteExpression(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
86615
86665
|
return context.factory.updateDeleteExpression(
|
|
86616
86666
|
node,
|
|
86617
|
-
nodeVisitor(node.expression, visitor, isExpression)
|
|
86667
|
+
Debug.checkDefined(nodeVisitor(node.expression, visitor, isExpression))
|
|
86618
86668
|
);
|
|
86619
86669
|
},
|
|
86620
86670
|
[218 /* TypeOfExpression */]: function visitEachChildOfTypeOfExpression(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
86621
86671
|
return context.factory.updateTypeOfExpression(
|
|
86622
86672
|
node,
|
|
86623
|
-
nodeVisitor(node.expression, visitor, isExpression)
|
|
86673
|
+
Debug.checkDefined(nodeVisitor(node.expression, visitor, isExpression))
|
|
86624
86674
|
);
|
|
86625
86675
|
},
|
|
86626
86676
|
[219 /* VoidExpression */]: function visitEachChildOfVoidExpression(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
86627
86677
|
return context.factory.updateVoidExpression(
|
|
86628
86678
|
node,
|
|
86629
|
-
nodeVisitor(node.expression, visitor, isExpression)
|
|
86679
|
+
Debug.checkDefined(nodeVisitor(node.expression, visitor, isExpression))
|
|
86630
86680
|
);
|
|
86631
86681
|
},
|
|
86632
86682
|
[220 /* AwaitExpression */]: function visitEachChildOfAwaitExpression(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
86633
86683
|
return context.factory.updateAwaitExpression(
|
|
86634
86684
|
node,
|
|
86635
|
-
nodeVisitor(node.expression, visitor, isExpression)
|
|
86685
|
+
Debug.checkDefined(nodeVisitor(node.expression, visitor, isExpression))
|
|
86636
86686
|
);
|
|
86637
86687
|
},
|
|
86638
86688
|
[221 /* PrefixUnaryExpression */]: function visitEachChildOfPrefixUnaryExpression(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
86639
86689
|
return context.factory.updatePrefixUnaryExpression(
|
|
86640
86690
|
node,
|
|
86641
|
-
nodeVisitor(node.operand, visitor, isExpression)
|
|
86691
|
+
Debug.checkDefined(nodeVisitor(node.operand, visitor, isExpression))
|
|
86642
86692
|
);
|
|
86643
86693
|
},
|
|
86644
86694
|
[222 /* PostfixUnaryExpression */]: function visitEachChildOfPostfixUnaryExpression(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
86645
86695
|
return context.factory.updatePostfixUnaryExpression(
|
|
86646
86696
|
node,
|
|
86647
|
-
nodeVisitor(node.operand, visitor, isExpression)
|
|
86697
|
+
Debug.checkDefined(nodeVisitor(node.operand, visitor, isExpression))
|
|
86648
86698
|
);
|
|
86649
86699
|
},
|
|
86650
86700
|
[223 /* BinaryExpression */]: function visitEachChildOfBinaryExpression(node, visitor, context, _nodesVisitor, nodeVisitor, tokenVisitor) {
|
|
86651
86701
|
return context.factory.updateBinaryExpression(
|
|
86652
86702
|
node,
|
|
86653
|
-
nodeVisitor(node.left, visitor, isExpression),
|
|
86654
|
-
nodeVisitor(node.operatorToken, tokenVisitor, isBinaryOperatorToken),
|
|
86655
|
-
nodeVisitor(node.right, visitor, isExpression)
|
|
86703
|
+
Debug.checkDefined(nodeVisitor(node.left, visitor, isExpression)),
|
|
86704
|
+
tokenVisitor ? Debug.checkDefined(nodeVisitor(node.operatorToken, tokenVisitor, isBinaryOperatorToken)) : node.operatorToken,
|
|
86705
|
+
Debug.checkDefined(nodeVisitor(node.right, visitor, isExpression))
|
|
86656
86706
|
);
|
|
86657
86707
|
},
|
|
86658
86708
|
[224 /* ConditionalExpression */]: function visitEachChildOfConditionalExpression(node, visitor, context, _nodesVisitor, nodeVisitor, tokenVisitor) {
|
|
86659
86709
|
return context.factory.updateConditionalExpression(
|
|
86660
86710
|
node,
|
|
86661
|
-
nodeVisitor(node.condition, visitor, isExpression),
|
|
86662
|
-
nodeVisitor(node.questionToken, tokenVisitor, isQuestionToken),
|
|
86663
|
-
nodeVisitor(node.whenTrue, visitor, isExpression),
|
|
86664
|
-
nodeVisitor(node.colonToken, tokenVisitor, isColonToken),
|
|
86665
|
-
nodeVisitor(node.whenFalse, visitor, isExpression)
|
|
86711
|
+
Debug.checkDefined(nodeVisitor(node.condition, visitor, isExpression)),
|
|
86712
|
+
tokenVisitor ? Debug.checkDefined(nodeVisitor(node.questionToken, tokenVisitor, isQuestionToken)) : node.questionToken,
|
|
86713
|
+
Debug.checkDefined(nodeVisitor(node.whenTrue, visitor, isExpression)),
|
|
86714
|
+
tokenVisitor ? Debug.checkDefined(nodeVisitor(node.colonToken, tokenVisitor, isColonToken)) : node.colonToken,
|
|
86715
|
+
Debug.checkDefined(nodeVisitor(node.whenFalse, visitor, isExpression))
|
|
86666
86716
|
);
|
|
86667
86717
|
},
|
|
86668
86718
|
[225 /* TemplateExpression */]: function visitEachChildOfTemplateExpression(node, visitor, context, nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
86669
86719
|
return context.factory.updateTemplateExpression(
|
|
86670
86720
|
node,
|
|
86671
|
-
nodeVisitor(node.head, visitor, isTemplateHead),
|
|
86721
|
+
Debug.checkDefined(nodeVisitor(node.head, visitor, isTemplateHead)),
|
|
86672
86722
|
nodesVisitor(node.templateSpans, visitor, isTemplateSpan)
|
|
86673
86723
|
);
|
|
86674
86724
|
},
|
|
86675
86725
|
[226 /* YieldExpression */]: function visitEachChildOfYieldExpression(node, visitor, context, _nodesVisitor, nodeVisitor, tokenVisitor) {
|
|
86676
86726
|
return context.factory.updateYieldExpression(
|
|
86677
86727
|
node,
|
|
86678
|
-
nodeVisitor(node.asteriskToken, tokenVisitor, isAsteriskToken),
|
|
86728
|
+
tokenVisitor ? nodeVisitor(node.asteriskToken, tokenVisitor, isAsteriskToken) : node.asteriskToken,
|
|
86679
86729
|
nodeVisitor(node.expression, visitor, isExpression)
|
|
86680
86730
|
);
|
|
86681
86731
|
},
|
|
86682
86732
|
[227 /* SpreadElement */]: function visitEachChildOfSpreadElement(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
86683
86733
|
return context.factory.updateSpreadElement(
|
|
86684
86734
|
node,
|
|
86685
|
-
nodeVisitor(node.expression, visitor, isExpression)
|
|
86735
|
+
Debug.checkDefined(nodeVisitor(node.expression, visitor, isExpression))
|
|
86686
86736
|
);
|
|
86687
86737
|
},
|
|
86688
86738
|
[228 /* ClassExpression */]: function visitEachChildOfClassExpression(node, visitor, context, nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
@@ -86698,45 +86748,45 @@ var visitEachChildTable = {
|
|
|
86698
86748
|
[230 /* ExpressionWithTypeArguments */]: function visitEachChildOfExpressionWithTypeArguments(node, visitor, context, nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
86699
86749
|
return context.factory.updateExpressionWithTypeArguments(
|
|
86700
86750
|
node,
|
|
86701
|
-
nodeVisitor(node.expression, visitor, isExpression),
|
|
86751
|
+
Debug.checkDefined(nodeVisitor(node.expression, visitor, isExpression)),
|
|
86702
86752
|
nodesVisitor(node.typeArguments, visitor, isTypeNode)
|
|
86703
86753
|
);
|
|
86704
86754
|
},
|
|
86705
86755
|
[231 /* AsExpression */]: function visitEachChildOfAsExpression(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
86706
86756
|
return context.factory.updateAsExpression(
|
|
86707
86757
|
node,
|
|
86708
|
-
nodeVisitor(node.expression, visitor, isExpression),
|
|
86709
|
-
nodeVisitor(node.type, visitor, isTypeNode)
|
|
86758
|
+
Debug.checkDefined(nodeVisitor(node.expression, visitor, isExpression)),
|
|
86759
|
+
Debug.checkDefined(nodeVisitor(node.type, visitor, isTypeNode))
|
|
86710
86760
|
);
|
|
86711
86761
|
},
|
|
86712
86762
|
[235 /* SatisfiesExpression */]: function visitEachChildOfSatisfiesExpression(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
86713
86763
|
return context.factory.updateSatisfiesExpression(
|
|
86714
86764
|
node,
|
|
86715
|
-
nodeVisitor(node.expression, visitor, isExpression),
|
|
86716
|
-
nodeVisitor(node.type, visitor, isTypeNode)
|
|
86765
|
+
Debug.checkDefined(nodeVisitor(node.expression, visitor, isExpression)),
|
|
86766
|
+
Debug.checkDefined(nodeVisitor(node.type, visitor, isTypeNode))
|
|
86717
86767
|
);
|
|
86718
86768
|
},
|
|
86719
86769
|
[232 /* NonNullExpression */]: function visitEachChildOfNonNullExpression(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
86720
86770
|
return isOptionalChain(node) ? context.factory.updateNonNullChain(
|
|
86721
86771
|
node,
|
|
86722
|
-
nodeVisitor(node.expression, visitor, isExpression)
|
|
86772
|
+
Debug.checkDefined(nodeVisitor(node.expression, visitor, isExpression))
|
|
86723
86773
|
) : context.factory.updateNonNullExpression(
|
|
86724
86774
|
node,
|
|
86725
|
-
nodeVisitor(node.expression, visitor, isExpression)
|
|
86775
|
+
Debug.checkDefined(nodeVisitor(node.expression, visitor, isExpression))
|
|
86726
86776
|
);
|
|
86727
86777
|
},
|
|
86728
86778
|
[233 /* MetaProperty */]: function visitEachChildOfMetaProperty(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
86729
86779
|
return context.factory.updateMetaProperty(
|
|
86730
86780
|
node,
|
|
86731
|
-
nodeVisitor(node.name, visitor, isIdentifier)
|
|
86781
|
+
Debug.checkDefined(nodeVisitor(node.name, visitor, isIdentifier))
|
|
86732
86782
|
);
|
|
86733
86783
|
},
|
|
86734
86784
|
// Misc
|
|
86735
86785
|
[236 /* TemplateSpan */]: function visitEachChildOfTemplateSpan(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
86736
86786
|
return context.factory.updateTemplateSpan(
|
|
86737
86787
|
node,
|
|
86738
|
-
nodeVisitor(node.expression, visitor, isExpression),
|
|
86739
|
-
nodeVisitor(node.literal, visitor, isTemplateMiddleOrTemplateTail)
|
|
86788
|
+
Debug.checkDefined(nodeVisitor(node.expression, visitor, isExpression)),
|
|
86789
|
+
Debug.checkDefined(nodeVisitor(node.literal, visitor, isTemplateMiddleOrTemplateTail))
|
|
86740
86790
|
);
|
|
86741
86791
|
},
|
|
86742
86792
|
// Element
|
|
@@ -86750,20 +86800,20 @@ var visitEachChildTable = {
|
|
|
86750
86800
|
return context.factory.updateVariableStatement(
|
|
86751
86801
|
node,
|
|
86752
86802
|
nodesVisitor(node.modifiers, visitor, isModifier),
|
|
86753
|
-
nodeVisitor(node.declarationList, visitor, isVariableDeclarationList)
|
|
86803
|
+
Debug.checkDefined(nodeVisitor(node.declarationList, visitor, isVariableDeclarationList))
|
|
86754
86804
|
);
|
|
86755
86805
|
},
|
|
86756
86806
|
[241 /* ExpressionStatement */]: function visitEachChildOfExpressionStatement(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
86757
86807
|
return context.factory.updateExpressionStatement(
|
|
86758
86808
|
node,
|
|
86759
|
-
nodeVisitor(node.expression, visitor, isExpression)
|
|
86809
|
+
Debug.checkDefined(nodeVisitor(node.expression, visitor, isExpression))
|
|
86760
86810
|
);
|
|
86761
86811
|
},
|
|
86762
86812
|
[242 /* IfStatement */]: function visitEachChildOfIfStatement(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
86763
86813
|
return context.factory.updateIfStatement(
|
|
86764
86814
|
node,
|
|
86765
|
-
nodeVisitor(node.expression, visitor, isExpression),
|
|
86766
|
-
nodeVisitor(node.thenStatement, visitor, isStatement, context.factory.liftToBlock),
|
|
86815
|
+
Debug.checkDefined(nodeVisitor(node.expression, visitor, isExpression)),
|
|
86816
|
+
Debug.checkDefined(nodeVisitor(node.thenStatement, visitor, isStatement, context.factory.liftToBlock)),
|
|
86767
86817
|
nodeVisitor(node.elseStatement, visitor, isStatement, context.factory.liftToBlock)
|
|
86768
86818
|
);
|
|
86769
86819
|
},
|
|
@@ -86771,13 +86821,13 @@ var visitEachChildTable = {
|
|
|
86771
86821
|
return context.factory.updateDoStatement(
|
|
86772
86822
|
node,
|
|
86773
86823
|
visitIterationBody(node.statement, visitor, context, nodeVisitor),
|
|
86774
|
-
nodeVisitor(node.expression, visitor, isExpression)
|
|
86824
|
+
Debug.checkDefined(nodeVisitor(node.expression, visitor, isExpression))
|
|
86775
86825
|
);
|
|
86776
86826
|
},
|
|
86777
86827
|
[244 /* WhileStatement */]: function visitEachChildOfWhileStatement(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
86778
86828
|
return context.factory.updateWhileStatement(
|
|
86779
86829
|
node,
|
|
86780
|
-
nodeVisitor(node.expression, visitor, isExpression),
|
|
86830
|
+
Debug.checkDefined(nodeVisitor(node.expression, visitor, isExpression)),
|
|
86781
86831
|
visitIterationBody(node.statement, visitor, context, nodeVisitor)
|
|
86782
86832
|
);
|
|
86783
86833
|
},
|
|
@@ -86793,17 +86843,17 @@ var visitEachChildTable = {
|
|
|
86793
86843
|
[246 /* ForInStatement */]: function visitEachChildOfForInStatement(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
86794
86844
|
return context.factory.updateForInStatement(
|
|
86795
86845
|
node,
|
|
86796
|
-
nodeVisitor(node.initializer, visitor, isForInitializer),
|
|
86797
|
-
nodeVisitor(node.expression, visitor, isExpression),
|
|
86846
|
+
Debug.checkDefined(nodeVisitor(node.initializer, visitor, isForInitializer)),
|
|
86847
|
+
Debug.checkDefined(nodeVisitor(node.expression, visitor, isExpression)),
|
|
86798
86848
|
visitIterationBody(node.statement, visitor, context, nodeVisitor)
|
|
86799
86849
|
);
|
|
86800
86850
|
},
|
|
86801
86851
|
[247 /* ForOfStatement */]: function visitEachChildOfForOfStatement(node, visitor, context, _nodesVisitor, nodeVisitor, tokenVisitor) {
|
|
86802
86852
|
return context.factory.updateForOfStatement(
|
|
86803
86853
|
node,
|
|
86804
|
-
nodeVisitor(node.awaitModifier, tokenVisitor, isAwaitKeyword),
|
|
86805
|
-
nodeVisitor(node.initializer, visitor, isForInitializer),
|
|
86806
|
-
nodeVisitor(node.expression, visitor, isExpression),
|
|
86854
|
+
tokenVisitor ? nodeVisitor(node.awaitModifier, tokenVisitor, isAwaitKeyword) : node.awaitModifier,
|
|
86855
|
+
Debug.checkDefined(nodeVisitor(node.initializer, visitor, isForInitializer)),
|
|
86856
|
+
Debug.checkDefined(nodeVisitor(node.expression, visitor, isExpression)),
|
|
86807
86857
|
visitIterationBody(node.statement, visitor, context, nodeVisitor)
|
|
86808
86858
|
);
|
|
86809
86859
|
},
|
|
@@ -86828,34 +86878,34 @@ var visitEachChildTable = {
|
|
|
86828
86878
|
[251 /* WithStatement */]: function visitEachChildOfWithStatement(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
86829
86879
|
return context.factory.updateWithStatement(
|
|
86830
86880
|
node,
|
|
86831
|
-
nodeVisitor(node.expression, visitor, isExpression),
|
|
86832
|
-
nodeVisitor(node.statement, visitor, isStatement, context.factory.liftToBlock)
|
|
86881
|
+
Debug.checkDefined(nodeVisitor(node.expression, visitor, isExpression)),
|
|
86882
|
+
Debug.checkDefined(nodeVisitor(node.statement, visitor, isStatement, context.factory.liftToBlock))
|
|
86833
86883
|
);
|
|
86834
86884
|
},
|
|
86835
86885
|
[252 /* SwitchStatement */]: function visitEachChildOfSwitchStatement(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
86836
86886
|
return context.factory.updateSwitchStatement(
|
|
86837
86887
|
node,
|
|
86838
|
-
nodeVisitor(node.expression, visitor, isExpression),
|
|
86839
|
-
nodeVisitor(node.caseBlock, visitor, isCaseBlock)
|
|
86888
|
+
Debug.checkDefined(nodeVisitor(node.expression, visitor, isExpression)),
|
|
86889
|
+
Debug.checkDefined(nodeVisitor(node.caseBlock, visitor, isCaseBlock))
|
|
86840
86890
|
);
|
|
86841
86891
|
},
|
|
86842
86892
|
[253 /* LabeledStatement */]: function visitEachChildOfLabeledStatement(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
86843
86893
|
return context.factory.updateLabeledStatement(
|
|
86844
86894
|
node,
|
|
86845
|
-
nodeVisitor(node.label, visitor, isIdentifier),
|
|
86846
|
-
nodeVisitor(node.statement, visitor, isStatement, context.factory.liftToBlock)
|
|
86895
|
+
Debug.checkDefined(nodeVisitor(node.label, visitor, isIdentifier)),
|
|
86896
|
+
Debug.checkDefined(nodeVisitor(node.statement, visitor, isStatement, context.factory.liftToBlock))
|
|
86847
86897
|
);
|
|
86848
86898
|
},
|
|
86849
86899
|
[254 /* ThrowStatement */]: function visitEachChildOfThrowStatement(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
86850
86900
|
return context.factory.updateThrowStatement(
|
|
86851
86901
|
node,
|
|
86852
|
-
nodeVisitor(node.expression, visitor, isExpression)
|
|
86902
|
+
Debug.checkDefined(nodeVisitor(node.expression, visitor, isExpression))
|
|
86853
86903
|
);
|
|
86854
86904
|
},
|
|
86855
86905
|
[255 /* TryStatement */]: function visitEachChildOfTryStatement(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
86856
86906
|
return context.factory.updateTryStatement(
|
|
86857
86907
|
node,
|
|
86858
|
-
nodeVisitor(node.tryBlock, visitor, isBlock),
|
|
86908
|
+
Debug.checkDefined(nodeVisitor(node.tryBlock, visitor, isBlock)),
|
|
86859
86909
|
nodeVisitor(node.catchClause, visitor, isCatchClause),
|
|
86860
86910
|
nodeVisitor(node.finallyBlock, visitor, isBlock)
|
|
86861
86911
|
);
|
|
@@ -86863,8 +86913,8 @@ var visitEachChildTable = {
|
|
|
86863
86913
|
[257 /* VariableDeclaration */]: function visitEachChildOfVariableDeclaration(node, visitor, context, _nodesVisitor, nodeVisitor, tokenVisitor) {
|
|
86864
86914
|
return context.factory.updateVariableDeclaration(
|
|
86865
86915
|
node,
|
|
86866
|
-
nodeVisitor(node.name, visitor, isBindingName),
|
|
86867
|
-
nodeVisitor(node.exclamationToken, tokenVisitor, isExclamationToken),
|
|
86916
|
+
Debug.checkDefined(nodeVisitor(node.name, visitor, isBindingName)),
|
|
86917
|
+
tokenVisitor ? nodeVisitor(node.exclamationToken, tokenVisitor, isExclamationToken) : node.exclamationToken,
|
|
86868
86918
|
nodeVisitor(node.type, visitor, isTypeNode),
|
|
86869
86919
|
nodeVisitor(node.initializer, visitor, isExpression)
|
|
86870
86920
|
);
|
|
@@ -86879,7 +86929,7 @@ var visitEachChildTable = {
|
|
|
86879
86929
|
return context.factory.updateFunctionDeclaration(
|
|
86880
86930
|
node,
|
|
86881
86931
|
nodesVisitor(node.modifiers, visitor, isModifier),
|
|
86882
|
-
nodeVisitor(node.asteriskToken, tokenVisitor, isAsteriskToken),
|
|
86932
|
+
tokenVisitor ? nodeVisitor(node.asteriskToken, tokenVisitor, isAsteriskToken) : node.asteriskToken,
|
|
86883
86933
|
nodeVisitor(node.name, visitor, isIdentifier),
|
|
86884
86934
|
nodesVisitor(node.typeParameters, visitor, isTypeParameterDeclaration),
|
|
86885
86935
|
visitParameterList(node.parameters, visitor, context, nodesVisitor),
|
|
@@ -86901,7 +86951,7 @@ var visitEachChildTable = {
|
|
|
86901
86951
|
return context.factory.updateInterfaceDeclaration(
|
|
86902
86952
|
node,
|
|
86903
86953
|
nodesVisitor(node.modifiers, visitor, isModifier),
|
|
86904
|
-
nodeVisitor(node.name, visitor, isIdentifier),
|
|
86954
|
+
Debug.checkDefined(nodeVisitor(node.name, visitor, isIdentifier)),
|
|
86905
86955
|
nodesVisitor(node.typeParameters, visitor, isTypeParameterDeclaration),
|
|
86906
86956
|
nodesVisitor(node.heritageClauses, visitor, isHeritageClause),
|
|
86907
86957
|
nodesVisitor(node.members, visitor, isTypeElement)
|
|
@@ -86911,16 +86961,16 @@ var visitEachChildTable = {
|
|
|
86911
86961
|
return context.factory.updateTypeAliasDeclaration(
|
|
86912
86962
|
node,
|
|
86913
86963
|
nodesVisitor(node.modifiers, visitor, isModifier),
|
|
86914
|
-
nodeVisitor(node.name, visitor, isIdentifier),
|
|
86964
|
+
Debug.checkDefined(nodeVisitor(node.name, visitor, isIdentifier)),
|
|
86915
86965
|
nodesVisitor(node.typeParameters, visitor, isTypeParameterDeclaration),
|
|
86916
|
-
nodeVisitor(node.type, visitor, isTypeNode)
|
|
86966
|
+
Debug.checkDefined(nodeVisitor(node.type, visitor, isTypeNode))
|
|
86917
86967
|
);
|
|
86918
86968
|
},
|
|
86919
86969
|
[263 /* EnumDeclaration */]: function visitEachChildOfEnumDeclaration(node, visitor, context, nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
86920
86970
|
return context.factory.updateEnumDeclaration(
|
|
86921
86971
|
node,
|
|
86922
86972
|
nodesVisitor(node.modifiers, visitor, isModifier),
|
|
86923
|
-
nodeVisitor(node.name, visitor, isIdentifier),
|
|
86973
|
+
Debug.checkDefined(nodeVisitor(node.name, visitor, isIdentifier)),
|
|
86924
86974
|
nodesVisitor(node.members, visitor, isEnumMember)
|
|
86925
86975
|
);
|
|
86926
86976
|
},
|
|
@@ -86928,7 +86978,7 @@ var visitEachChildTable = {
|
|
|
86928
86978
|
return context.factory.updateModuleDeclaration(
|
|
86929
86979
|
node,
|
|
86930
86980
|
nodesVisitor(node.modifiers, visitor, isModifier),
|
|
86931
|
-
nodeVisitor(node.name, visitor, isModuleName),
|
|
86981
|
+
Debug.checkDefined(nodeVisitor(node.name, visitor, isModuleName)),
|
|
86932
86982
|
nodeVisitor(node.body, visitor, isModuleBody)
|
|
86933
86983
|
);
|
|
86934
86984
|
},
|
|
@@ -86947,7 +86997,7 @@ var visitEachChildTable = {
|
|
|
86947
86997
|
[267 /* NamespaceExportDeclaration */]: function visitEachChildOfNamespaceExportDeclaration(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
86948
86998
|
return context.factory.updateNamespaceExportDeclaration(
|
|
86949
86999
|
node,
|
|
86950
|
-
nodeVisitor(node.name, visitor, isIdentifier)
|
|
87000
|
+
Debug.checkDefined(nodeVisitor(node.name, visitor, isIdentifier))
|
|
86951
87001
|
);
|
|
86952
87002
|
},
|
|
86953
87003
|
[268 /* ImportEqualsDeclaration */]: function visitEachChildOfImportEqualsDeclaration(node, visitor, context, nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
@@ -86955,8 +87005,8 @@ var visitEachChildTable = {
|
|
|
86955
87005
|
node,
|
|
86956
87006
|
nodesVisitor(node.modifiers, visitor, isModifier),
|
|
86957
87007
|
node.isTypeOnly,
|
|
86958
|
-
nodeVisitor(node.name, visitor, isIdentifier),
|
|
86959
|
-
nodeVisitor(node.moduleReference, visitor, isModuleReference)
|
|
87008
|
+
Debug.checkDefined(nodeVisitor(node.name, visitor, isIdentifier)),
|
|
87009
|
+
Debug.checkDefined(nodeVisitor(node.moduleReference, visitor, isModuleReference))
|
|
86960
87010
|
);
|
|
86961
87011
|
},
|
|
86962
87012
|
[269 /* ImportDeclaration */]: function visitEachChildOfImportDeclaration(node, visitor, context, nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
@@ -86964,7 +87014,7 @@ var visitEachChildTable = {
|
|
|
86964
87014
|
node,
|
|
86965
87015
|
nodesVisitor(node.modifiers, visitor, isModifier),
|
|
86966
87016
|
nodeVisitor(node.importClause, visitor, isImportClause),
|
|
86967
|
-
nodeVisitor(node.moduleSpecifier, visitor, isExpression),
|
|
87017
|
+
Debug.checkDefined(nodeVisitor(node.moduleSpecifier, visitor, isExpression)),
|
|
86968
87018
|
nodeVisitor(node.assertClause, visitor, isAssertClause)
|
|
86969
87019
|
);
|
|
86970
87020
|
},
|
|
@@ -86978,8 +87028,8 @@ var visitEachChildTable = {
|
|
|
86978
87028
|
[297 /* AssertEntry */]: function visitEachChildOfAssertEntry(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
86979
87029
|
return context.factory.updateAssertEntry(
|
|
86980
87030
|
node,
|
|
86981
|
-
nodeVisitor(node.name, visitor, isAssertionKey),
|
|
86982
|
-
nodeVisitor(node.value, visitor, isExpression)
|
|
87031
|
+
Debug.checkDefined(nodeVisitor(node.name, visitor, isAssertionKey)),
|
|
87032
|
+
Debug.checkDefined(nodeVisitor(node.value, visitor, isExpression))
|
|
86983
87033
|
);
|
|
86984
87034
|
},
|
|
86985
87035
|
[270 /* ImportClause */]: function visitEachChildOfImportClause(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
@@ -86993,13 +87043,13 @@ var visitEachChildTable = {
|
|
|
86993
87043
|
[271 /* NamespaceImport */]: function visitEachChildOfNamespaceImport(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
86994
87044
|
return context.factory.updateNamespaceImport(
|
|
86995
87045
|
node,
|
|
86996
|
-
nodeVisitor(node.name, visitor, isIdentifier)
|
|
87046
|
+
Debug.checkDefined(nodeVisitor(node.name, visitor, isIdentifier))
|
|
86997
87047
|
);
|
|
86998
87048
|
},
|
|
86999
87049
|
[277 /* NamespaceExport */]: function visitEachChildOfNamespaceExport(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
87000
87050
|
return context.factory.updateNamespaceExport(
|
|
87001
87051
|
node,
|
|
87002
|
-
nodeVisitor(node.name, visitor, isIdentifier)
|
|
87052
|
+
Debug.checkDefined(nodeVisitor(node.name, visitor, isIdentifier))
|
|
87003
87053
|
);
|
|
87004
87054
|
},
|
|
87005
87055
|
[272 /* NamedImports */]: function visitEachChildOfNamedImports(node, visitor, context, nodesVisitor, _nodeVisitor, _tokenVisitor) {
|
|
@@ -87013,14 +87063,14 @@ var visitEachChildTable = {
|
|
|
87013
87063
|
node,
|
|
87014
87064
|
node.isTypeOnly,
|
|
87015
87065
|
nodeVisitor(node.propertyName, visitor, isIdentifier),
|
|
87016
|
-
nodeVisitor(node.name, visitor, isIdentifier)
|
|
87066
|
+
Debug.checkDefined(nodeVisitor(node.name, visitor, isIdentifier))
|
|
87017
87067
|
);
|
|
87018
87068
|
},
|
|
87019
87069
|
[274 /* ExportAssignment */]: function visitEachChildOfExportAssignment(node, visitor, context, nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
87020
87070
|
return context.factory.updateExportAssignment(
|
|
87021
87071
|
node,
|
|
87022
87072
|
nodesVisitor(node.modifiers, visitor, isModifier),
|
|
87023
|
-
nodeVisitor(node.expression, visitor, isExpression)
|
|
87073
|
+
Debug.checkDefined(nodeVisitor(node.expression, visitor, isExpression))
|
|
87024
87074
|
);
|
|
87025
87075
|
},
|
|
87026
87076
|
[275 /* ExportDeclaration */]: function visitEachChildOfExportDeclaration(node, visitor, context, nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
@@ -87044,59 +87094,59 @@ var visitEachChildTable = {
|
|
|
87044
87094
|
node,
|
|
87045
87095
|
node.isTypeOnly,
|
|
87046
87096
|
nodeVisitor(node.propertyName, visitor, isIdentifier),
|
|
87047
|
-
nodeVisitor(node.name, visitor, isIdentifier)
|
|
87097
|
+
Debug.checkDefined(nodeVisitor(node.name, visitor, isIdentifier))
|
|
87048
87098
|
);
|
|
87049
87099
|
},
|
|
87050
87100
|
// Module references
|
|
87051
87101
|
[280 /* ExternalModuleReference */]: function visitEachChildOfExternalModuleReference(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
87052
87102
|
return context.factory.updateExternalModuleReference(
|
|
87053
87103
|
node,
|
|
87054
|
-
nodeVisitor(node.expression, visitor, isExpression)
|
|
87104
|
+
Debug.checkDefined(nodeVisitor(node.expression, visitor, isExpression))
|
|
87055
87105
|
);
|
|
87056
87106
|
},
|
|
87057
87107
|
// JSX
|
|
87058
87108
|
[281 /* JsxElement */]: function visitEachChildOfJsxElement(node, visitor, context, nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
87059
87109
|
return context.factory.updateJsxElement(
|
|
87060
87110
|
node,
|
|
87061
|
-
nodeVisitor(node.openingElement, visitor, isJsxOpeningElement),
|
|
87111
|
+
Debug.checkDefined(nodeVisitor(node.openingElement, visitor, isJsxOpeningElement)),
|
|
87062
87112
|
nodesVisitor(node.children, visitor, isJsxChild),
|
|
87063
|
-
nodeVisitor(node.closingElement, visitor, isJsxClosingElement)
|
|
87113
|
+
Debug.checkDefined(nodeVisitor(node.closingElement, visitor, isJsxClosingElement))
|
|
87064
87114
|
);
|
|
87065
87115
|
},
|
|
87066
87116
|
[282 /* JsxSelfClosingElement */]: function visitEachChildOfJsxSelfClosingElement(node, visitor, context, nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
87067
87117
|
return context.factory.updateJsxSelfClosingElement(
|
|
87068
87118
|
node,
|
|
87069
|
-
nodeVisitor(node.tagName, visitor, isJsxTagNameExpression),
|
|
87119
|
+
Debug.checkDefined(nodeVisitor(node.tagName, visitor, isJsxTagNameExpression)),
|
|
87070
87120
|
nodesVisitor(node.typeArguments, visitor, isTypeNode),
|
|
87071
|
-
nodeVisitor(node.attributes, visitor, isJsxAttributes)
|
|
87121
|
+
Debug.checkDefined(nodeVisitor(node.attributes, visitor, isJsxAttributes))
|
|
87072
87122
|
);
|
|
87073
87123
|
},
|
|
87074
87124
|
[283 /* JsxOpeningElement */]: function visitEachChildOfJsxOpeningElement(node, visitor, context, nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
87075
87125
|
return context.factory.updateJsxOpeningElement(
|
|
87076
87126
|
node,
|
|
87077
|
-
nodeVisitor(node.tagName, visitor, isJsxTagNameExpression),
|
|
87127
|
+
Debug.checkDefined(nodeVisitor(node.tagName, visitor, isJsxTagNameExpression)),
|
|
87078
87128
|
nodesVisitor(node.typeArguments, visitor, isTypeNode),
|
|
87079
|
-
nodeVisitor(node.attributes, visitor, isJsxAttributes)
|
|
87129
|
+
Debug.checkDefined(nodeVisitor(node.attributes, visitor, isJsxAttributes))
|
|
87080
87130
|
);
|
|
87081
87131
|
},
|
|
87082
87132
|
[284 /* JsxClosingElement */]: function visitEachChildOfJsxClosingElement(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
87083
87133
|
return context.factory.updateJsxClosingElement(
|
|
87084
87134
|
node,
|
|
87085
|
-
nodeVisitor(node.tagName, visitor, isJsxTagNameExpression)
|
|
87135
|
+
Debug.checkDefined(nodeVisitor(node.tagName, visitor, isJsxTagNameExpression))
|
|
87086
87136
|
);
|
|
87087
87137
|
},
|
|
87088
87138
|
[285 /* JsxFragment */]: function visitEachChildOfJsxFragment(node, visitor, context, nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
87089
87139
|
return context.factory.updateJsxFragment(
|
|
87090
87140
|
node,
|
|
87091
|
-
nodeVisitor(node.openingFragment, visitor, isJsxOpeningFragment),
|
|
87141
|
+
Debug.checkDefined(nodeVisitor(node.openingFragment, visitor, isJsxOpeningFragment)),
|
|
87092
87142
|
nodesVisitor(node.children, visitor, isJsxChild),
|
|
87093
|
-
nodeVisitor(node.closingFragment, visitor, isJsxClosingFragment)
|
|
87143
|
+
Debug.checkDefined(nodeVisitor(node.closingFragment, visitor, isJsxClosingFragment))
|
|
87094
87144
|
);
|
|
87095
87145
|
},
|
|
87096
87146
|
[288 /* JsxAttribute */]: function visitEachChildOfJsxAttribute(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
87097
87147
|
return context.factory.updateJsxAttribute(
|
|
87098
87148
|
node,
|
|
87099
|
-
nodeVisitor(node.name, visitor, isIdentifier),
|
|
87149
|
+
Debug.checkDefined(nodeVisitor(node.name, visitor, isIdentifier)),
|
|
87100
87150
|
nodeVisitor(node.initializer, visitor, isStringLiteralOrJsxExpression)
|
|
87101
87151
|
);
|
|
87102
87152
|
},
|
|
@@ -87109,20 +87159,20 @@ var visitEachChildTable = {
|
|
|
87109
87159
|
[290 /* JsxSpreadAttribute */]: function visitEachChildOfJsxSpreadAttribute(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
87110
87160
|
return context.factory.updateJsxSpreadAttribute(
|
|
87111
87161
|
node,
|
|
87112
|
-
nodeVisitor(node.expression, visitor, isExpression)
|
|
87162
|
+
Debug.checkDefined(nodeVisitor(node.expression, visitor, isExpression))
|
|
87113
87163
|
);
|
|
87114
87164
|
},
|
|
87115
87165
|
[291 /* JsxExpression */]: function visitEachChildOfJsxExpression(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
87116
87166
|
return context.factory.updateJsxExpression(
|
|
87117
87167
|
node,
|
|
87118
|
-
nodeVisitor(node.expression, visitor, isExpression)
|
|
87168
|
+
Debug.checkDefined(nodeVisitor(node.expression, visitor, isExpression))
|
|
87119
87169
|
);
|
|
87120
87170
|
},
|
|
87121
87171
|
// Clauses
|
|
87122
87172
|
[292 /* CaseClause */]: function visitEachChildOfCaseClause(node, visitor, context, nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
87123
87173
|
return context.factory.updateCaseClause(
|
|
87124
87174
|
node,
|
|
87125
|
-
nodeVisitor(node.expression, visitor, isExpression),
|
|
87175
|
+
Debug.checkDefined(nodeVisitor(node.expression, visitor, isExpression)),
|
|
87126
87176
|
nodesVisitor(node.statements, visitor, isStatement)
|
|
87127
87177
|
);
|
|
87128
87178
|
},
|
|
@@ -87142,35 +87192,35 @@ var visitEachChildTable = {
|
|
|
87142
87192
|
return context.factory.updateCatchClause(
|
|
87143
87193
|
node,
|
|
87144
87194
|
nodeVisitor(node.variableDeclaration, visitor, isVariableDeclaration),
|
|
87145
|
-
nodeVisitor(node.block, visitor, isBlock)
|
|
87195
|
+
Debug.checkDefined(nodeVisitor(node.block, visitor, isBlock))
|
|
87146
87196
|
);
|
|
87147
87197
|
},
|
|
87148
87198
|
// Property assignments
|
|
87149
87199
|
[299 /* PropertyAssignment */]: function visitEachChildOfPropertyAssignment(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
87150
87200
|
return context.factory.updatePropertyAssignment(
|
|
87151
87201
|
node,
|
|
87152
|
-
nodeVisitor(node.name, visitor, isPropertyName),
|
|
87153
|
-
nodeVisitor(node.initializer, visitor, isExpression)
|
|
87202
|
+
Debug.checkDefined(nodeVisitor(node.name, visitor, isPropertyName)),
|
|
87203
|
+
Debug.checkDefined(nodeVisitor(node.initializer, visitor, isExpression))
|
|
87154
87204
|
);
|
|
87155
87205
|
},
|
|
87156
87206
|
[300 /* ShorthandPropertyAssignment */]: function visitEachChildOfShorthandPropertyAssignment(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
87157
87207
|
return context.factory.updateShorthandPropertyAssignment(
|
|
87158
87208
|
node,
|
|
87159
|
-
nodeVisitor(node.name, visitor, isIdentifier),
|
|
87209
|
+
Debug.checkDefined(nodeVisitor(node.name, visitor, isIdentifier)),
|
|
87160
87210
|
nodeVisitor(node.objectAssignmentInitializer, visitor, isExpression)
|
|
87161
87211
|
);
|
|
87162
87212
|
},
|
|
87163
87213
|
[301 /* SpreadAssignment */]: function visitEachChildOfSpreadAssignment(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
87164
87214
|
return context.factory.updateSpreadAssignment(
|
|
87165
87215
|
node,
|
|
87166
|
-
nodeVisitor(node.expression, visitor, isExpression)
|
|
87216
|
+
Debug.checkDefined(nodeVisitor(node.expression, visitor, isExpression))
|
|
87167
87217
|
);
|
|
87168
87218
|
},
|
|
87169
87219
|
// Enum
|
|
87170
87220
|
[302 /* EnumMember */]: function visitEachChildOfEnumMember(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
87171
87221
|
return context.factory.updateEnumMember(
|
|
87172
87222
|
node,
|
|
87173
|
-
nodeVisitor(node.name, visitor, isPropertyName),
|
|
87223
|
+
Debug.checkDefined(nodeVisitor(node.name, visitor, isPropertyName)),
|
|
87174
87224
|
nodeVisitor(node.initializer, visitor, isExpression)
|
|
87175
87225
|
);
|
|
87176
87226
|
},
|
|
@@ -87185,7 +87235,7 @@ var visitEachChildTable = {
|
|
|
87185
87235
|
[355 /* PartiallyEmittedExpression */]: function visitEachChildOfPartiallyEmittedExpression(node, visitor, context, _nodesVisitor, nodeVisitor, _tokenVisitor) {
|
|
87186
87236
|
return context.factory.updatePartiallyEmittedExpression(
|
|
87187
87237
|
node,
|
|
87188
|
-
nodeVisitor(node.expression, visitor, isExpression)
|
|
87238
|
+
Debug.checkDefined(nodeVisitor(node.expression, visitor, isExpression))
|
|
87189
87239
|
);
|
|
87190
87240
|
},
|
|
87191
87241
|
[356 /* CommaListExpression */]: function visitEachChildOfCommaListExpression(node, visitor, context, nodesVisitor, _nodeVisitor, _tokenVisitor) {
|
|
@@ -88137,7 +88187,7 @@ function flattenDestructuringAssignment(node, visitor, context, level, needsValu
|
|
|
88137
88187
|
location = node = value;
|
|
88138
88188
|
value = node.right;
|
|
88139
88189
|
} else {
|
|
88140
|
-
return visitNode(value, visitor, isExpression);
|
|
88190
|
+
return Debug.checkDefined(visitNode(value, visitor, isExpression));
|
|
88141
88191
|
}
|
|
88142
88192
|
}
|
|
88143
88193
|
}
|
|
@@ -88156,6 +88206,7 @@ function flattenDestructuringAssignment(node, visitor, context, level, needsValu
|
|
|
88156
88206
|
};
|
|
88157
88207
|
if (value) {
|
|
88158
88208
|
value = visitNode(value, visitor, isExpression);
|
|
88209
|
+
Debug.assert(value);
|
|
88159
88210
|
if (isIdentifier(value) && bindingOrAssignmentElementAssignsToName(node, value.escapedText) || bindingOrAssignmentElementContainsNonLiteralComputedName(node)) {
|
|
88160
88211
|
value = ensureIdentifier(
|
|
88161
88212
|
flattenContext,
|
|
@@ -88197,7 +88248,7 @@ function flattenDestructuringAssignment(node, visitor, context, level, needsValu
|
|
|
88197
88248
|
function emitBindingOrAssignment(target, value2, location2, original) {
|
|
88198
88249
|
Debug.assertNode(target, createAssignmentCallback ? isIdentifier : isExpression);
|
|
88199
88250
|
const expression = createAssignmentCallback ? createAssignmentCallback(target, value2, location2) : setTextRange(
|
|
88200
|
-
context.factory.createAssignment(visitNode(target, visitor, isExpression), value2),
|
|
88251
|
+
context.factory.createAssignment(Debug.checkDefined(visitNode(target, visitor, isExpression)), value2),
|
|
88201
88252
|
location2
|
|
88202
88253
|
);
|
|
88203
88254
|
expression.original = original;
|
|
@@ -88254,7 +88305,7 @@ function flattenDestructuringBinding(node, visitor, context, level, rval, hoistT
|
|
|
88254
88305
|
if (initializer && (isIdentifier(initializer) && bindingOrAssignmentElementAssignsToName(node, initializer.escapedText) || bindingOrAssignmentElementContainsNonLiteralComputedName(node))) {
|
|
88255
88306
|
initializer = ensureIdentifier(
|
|
88256
88307
|
flattenContext,
|
|
88257
|
-
visitNode(initializer, flattenContext.visitor),
|
|
88308
|
+
Debug.checkDefined(visitNode(initializer, flattenContext.visitor, isExpression)),
|
|
88258
88309
|
/*reuseIdentifierExpressions*/
|
|
88259
88310
|
false,
|
|
88260
88311
|
initializer
|
|
@@ -88375,7 +88426,7 @@ function flattenObjectBindingOrAssignmentPattern(flattenContext, parent2, patter
|
|
|
88375
88426
|
if (!getRestIndicatorOfBindingOrAssignmentElement(element)) {
|
|
88376
88427
|
const propertyName = getPropertyNameOfBindingOrAssignmentElement(element);
|
|
88377
88428
|
if (flattenContext.level >= 1 /* ObjectRest */ && !(element.transformFlags & (32768 /* ContainsRestOrSpread */ | 65536 /* ContainsObjectRestOrSpread */)) && !(getTargetOfBindingOrAssignmentElement(element).transformFlags & (32768 /* ContainsRestOrSpread */ | 65536 /* ContainsObjectRestOrSpread */)) && !isComputedPropertyName(propertyName)) {
|
|
88378
|
-
bindingElements = append(bindingElements, visitNode(element, flattenContext.visitor));
|
|
88429
|
+
bindingElements = append(bindingElements, visitNode(element, flattenContext.visitor, isBindingOrAssignmentElement));
|
|
88379
88430
|
} else {
|
|
88380
88431
|
if (bindingElements) {
|
|
88381
88432
|
flattenContext.emitBindingOrAssignment(flattenContext.createObjectBindingOrAssignmentPattern(bindingElements), value, location, pattern);
|
|
@@ -88513,7 +88564,7 @@ function createDestructuringPropertyAccess(flattenContext, value, propertyName)
|
|
|
88513
88564
|
if (isComputedPropertyName(propertyName)) {
|
|
88514
88565
|
const argumentExpression = ensureIdentifier(
|
|
88515
88566
|
flattenContext,
|
|
88516
|
-
visitNode(propertyName.expression, flattenContext.visitor),
|
|
88567
|
+
Debug.checkDefined(visitNode(propertyName.expression, flattenContext.visitor, isExpression)),
|
|
88517
88568
|
/*reuseIdentifierExpressions*/
|
|
88518
88569
|
false,
|
|
88519
88570
|
/*location*/
|
|
@@ -88556,6 +88607,7 @@ function makeArrayBindingPattern(factory2, elements) {
|
|
|
88556
88607
|
return factory2.createArrayBindingPattern(elements);
|
|
88557
88608
|
}
|
|
88558
88609
|
function makeArrayAssignmentPattern(factory2, elements) {
|
|
88610
|
+
Debug.assertEachNode(elements, isArrayBindingOrAssignmentElement);
|
|
88559
88611
|
return factory2.createArrayLiteralExpression(map(elements, factory2.converters.convertToArrayAssignmentElement));
|
|
88560
88612
|
}
|
|
88561
88613
|
function makeObjectBindingPattern(factory2, elements) {
|
|
@@ -88563,6 +88615,7 @@ function makeObjectBindingPattern(factory2, elements) {
|
|
|
88563
88615
|
return factory2.createObjectBindingPattern(elements);
|
|
88564
88616
|
}
|
|
88565
88617
|
function makeObjectAssignmentPattern(factory2, elements) {
|
|
88618
|
+
Debug.assertEachNode(elements, isObjectBindingOrAssignmentElement);
|
|
88566
88619
|
return factory2.createObjectLiteralExpression(map(elements, factory2.converters.convertToObjectAssignmentElement));
|
|
88567
88620
|
}
|
|
88568
88621
|
function makeBindingElement(factory2, name) {
|
|
@@ -88586,6 +88639,7 @@ var ProcessLevel = /* @__PURE__ */ ((ProcessLevel2) => {
|
|
|
88586
88639
|
})(ProcessLevel || {});
|
|
88587
88640
|
function processTaggedTemplateExpression(context, node, visitor, currentSourceFile, recordTaggedTemplateString, level) {
|
|
88588
88641
|
const tag = visitNode(node.tag, visitor, isExpression);
|
|
88642
|
+
Debug.assert(tag);
|
|
88589
88643
|
const templateArguments = [void 0];
|
|
88590
88644
|
const cookedStrings = [];
|
|
88591
88645
|
const rawStrings = [];
|
|
@@ -88602,7 +88656,7 @@ function processTaggedTemplateExpression(context, node, visitor, currentSourceFi
|
|
|
88602
88656
|
for (const templateSpan of template.templateSpans) {
|
|
88603
88657
|
cookedStrings.push(createTemplateCooked(templateSpan.literal));
|
|
88604
88658
|
rawStrings.push(getRawLiteral(templateSpan.literal, currentSourceFile));
|
|
88605
|
-
templateArguments.push(visitNode(templateSpan.expression, visitor, isExpression));
|
|
88659
|
+
templateArguments.push(Debug.checkDefined(visitNode(templateSpan.expression, visitor, isExpression)));
|
|
88606
88660
|
}
|
|
88607
88661
|
}
|
|
88608
88662
|
const helperCall = context.getEmitHelperFactory().createTemplateObjectHelper(
|
|
@@ -88975,7 +89029,7 @@ function transformTypeScript(context) {
|
|
|
88975
89029
|
function visitObjectLiteralExpression(node) {
|
|
88976
89030
|
return factory2.updateObjectLiteralExpression(
|
|
88977
89031
|
node,
|
|
88978
|
-
visitNodes2(node.properties, getObjectLiteralElementVisitor(node),
|
|
89032
|
+
visitNodes2(node.properties, getObjectLiteralElementVisitor(node), isObjectLiteralElementLike)
|
|
88979
89033
|
);
|
|
88980
89034
|
}
|
|
88981
89035
|
function getClassFacts(node, staticProperties) {
|
|
@@ -89173,6 +89227,7 @@ function transformTypeScript(context) {
|
|
|
89173
89227
|
const decorators = [];
|
|
89174
89228
|
for (const parameterDecorator of parameterDecorators) {
|
|
89175
89229
|
const expression = visitNode(parameterDecorator.expression, visitor, isExpression);
|
|
89230
|
+
Debug.assert(expression);
|
|
89176
89231
|
const helper = emitHelpers().createParamHelper(expression, parameterOffset);
|
|
89177
89232
|
setTextRange(helper, parameterDecorator.expression);
|
|
89178
89233
|
setEmitFlags(helper, 3072 /* NoComments */);
|
|
@@ -89296,6 +89351,7 @@ function transformTypeScript(context) {
|
|
|
89296
89351
|
const name = member.name;
|
|
89297
89352
|
if (isComputedPropertyName(name) && (!hasStaticModifier(member) && currentClassHasParameterProperties || hasDecorators(member))) {
|
|
89298
89353
|
const expression = visitNode(name.expression, visitor, isExpression);
|
|
89354
|
+
Debug.assert(expression);
|
|
89299
89355
|
const innerExpression = skipPartiallyEmittedExpressions(expression);
|
|
89300
89356
|
if (!isSimpleInlineableExpression(innerExpression)) {
|
|
89301
89357
|
const generatedName = factory2.getGeneratedNameForNode(name);
|
|
@@ -89303,7 +89359,7 @@ function transformTypeScript(context) {
|
|
|
89303
89359
|
return factory2.updateComputedPropertyName(name, factory2.createAssignment(generatedName, expression));
|
|
89304
89360
|
}
|
|
89305
89361
|
}
|
|
89306
|
-
return visitNode(name, visitor, isPropertyName);
|
|
89362
|
+
return Debug.checkDefined(visitNode(name, visitor, isPropertyName));
|
|
89307
89363
|
}
|
|
89308
89364
|
function visitHeritageClause(node) {
|
|
89309
89365
|
if (node.token === 117 /* ImplementsKeyword */) {
|
|
@@ -89314,7 +89370,7 @@ function transformTypeScript(context) {
|
|
|
89314
89370
|
function visitExpressionWithTypeArguments(node) {
|
|
89315
89371
|
return factory2.updateExpressionWithTypeArguments(
|
|
89316
89372
|
node,
|
|
89317
|
-
visitNode(node.expression, visitor, isLeftHandSideExpression),
|
|
89373
|
+
Debug.checkDefined(visitNode(node.expression, visitor, isLeftHandSideExpression)),
|
|
89318
89374
|
/*typeArguments*/
|
|
89319
89375
|
void 0
|
|
89320
89376
|
);
|
|
@@ -89333,7 +89389,7 @@ function transformTypeScript(context) {
|
|
|
89333
89389
|
return factory2.updatePropertyDeclaration(
|
|
89334
89390
|
node,
|
|
89335
89391
|
concatenate(decorators, factory2.createModifiersFromModifierFlags(2 /* Ambient */)),
|
|
89336
|
-
visitNode(node.name, visitor, isPropertyName),
|
|
89392
|
+
Debug.checkDefined(visitNode(node.name, visitor, isPropertyName)),
|
|
89337
89393
|
/*questionOrExclamationToken*/
|
|
89338
89394
|
void 0,
|
|
89339
89395
|
/*type*/
|
|
@@ -89350,7 +89406,7 @@ function transformTypeScript(context) {
|
|
|
89350
89406
|
void 0,
|
|
89351
89407
|
/*type*/
|
|
89352
89408
|
void 0,
|
|
89353
|
-
visitNode(node.initializer, visitor)
|
|
89409
|
+
visitNode(node.initializer, visitor, isExpression)
|
|
89354
89410
|
);
|
|
89355
89411
|
}
|
|
89356
89412
|
function visitConstructor(node) {
|
|
@@ -89569,7 +89625,7 @@ function transformTypeScript(context) {
|
|
|
89569
89625
|
elideNodes(factory2, node.modifiers),
|
|
89570
89626
|
// preserve positions, if available
|
|
89571
89627
|
node.dotDotDotToken,
|
|
89572
|
-
visitNode(node.name, visitor, isBindingName),
|
|
89628
|
+
Debug.checkDefined(visitNode(node.name, visitor, isBindingName)),
|
|
89573
89629
|
/*questionToken*/
|
|
89574
89630
|
void 0,
|
|
89575
89631
|
/*type*/
|
|
@@ -89618,7 +89674,7 @@ function transformTypeScript(context) {
|
|
|
89618
89674
|
return setTextRange(
|
|
89619
89675
|
factory2.createAssignment(
|
|
89620
89676
|
getNamespaceMemberNameWithSourceMapsAndWithoutComments(name),
|
|
89621
|
-
visitNode(node.initializer, visitor, isExpression)
|
|
89677
|
+
Debug.checkDefined(visitNode(node.initializer, visitor, isExpression))
|
|
89622
89678
|
),
|
|
89623
89679
|
/*location*/
|
|
89624
89680
|
node
|
|
@@ -89628,7 +89684,7 @@ function transformTypeScript(context) {
|
|
|
89628
89684
|
function visitVariableDeclaration(node) {
|
|
89629
89685
|
const updated = factory2.updateVariableDeclaration(
|
|
89630
89686
|
node,
|
|
89631
|
-
visitNode(node.name, visitor, isBindingName),
|
|
89687
|
+
Debug.checkDefined(visitNode(node.name, visitor, isBindingName)),
|
|
89632
89688
|
/*exclamationToken*/
|
|
89633
89689
|
void 0,
|
|
89634
89690
|
/*type*/
|
|
@@ -89644,26 +89700,30 @@ function transformTypeScript(context) {
|
|
|
89644
89700
|
const innerExpression = skipOuterExpressions(node.expression, ~6 /* Assertions */);
|
|
89645
89701
|
if (isAssertionExpression(innerExpression)) {
|
|
89646
89702
|
const expression = visitNode(node.expression, visitor, isExpression);
|
|
89703
|
+
Debug.assert(expression);
|
|
89647
89704
|
return factory2.createPartiallyEmittedExpression(expression, node);
|
|
89648
89705
|
}
|
|
89649
89706
|
return visitEachChild(node, visitor, context);
|
|
89650
89707
|
}
|
|
89651
89708
|
function visitAssertionExpression(node) {
|
|
89652
89709
|
const expression = visitNode(node.expression, visitor, isExpression);
|
|
89710
|
+
Debug.assert(expression);
|
|
89653
89711
|
return factory2.createPartiallyEmittedExpression(expression, node);
|
|
89654
89712
|
}
|
|
89655
89713
|
function visitNonNullExpression(node) {
|
|
89656
89714
|
const expression = visitNode(node.expression, visitor, isLeftHandSideExpression);
|
|
89715
|
+
Debug.assert(expression);
|
|
89657
89716
|
return factory2.createPartiallyEmittedExpression(expression, node);
|
|
89658
89717
|
}
|
|
89659
89718
|
function visitSatisfiesExpression(node) {
|
|
89660
89719
|
const expression = visitNode(node.expression, visitor, isExpression);
|
|
89720
|
+
Debug.assert(expression);
|
|
89661
89721
|
return factory2.createPartiallyEmittedExpression(expression, node);
|
|
89662
89722
|
}
|
|
89663
89723
|
function visitCallExpression(node) {
|
|
89664
89724
|
return factory2.updateCallExpression(
|
|
89665
89725
|
node,
|
|
89666
|
-
visitNode(node.expression, visitor, isExpression),
|
|
89726
|
+
Debug.checkDefined(visitNode(node.expression, visitor, isExpression)),
|
|
89667
89727
|
/*typeArguments*/
|
|
89668
89728
|
void 0,
|
|
89669
89729
|
visitNodes2(node.arguments, visitor, isExpression)
|
|
@@ -89672,7 +89732,7 @@ function transformTypeScript(context) {
|
|
|
89672
89732
|
function visitNewExpression(node) {
|
|
89673
89733
|
return factory2.updateNewExpression(
|
|
89674
89734
|
node,
|
|
89675
|
-
visitNode(node.expression, visitor, isExpression),
|
|
89735
|
+
Debug.checkDefined(visitNode(node.expression, visitor, isExpression)),
|
|
89676
89736
|
/*typeArguments*/
|
|
89677
89737
|
void 0,
|
|
89678
89738
|
visitNodes2(node.arguments, visitor, isExpression)
|
|
@@ -89681,28 +89741,28 @@ function transformTypeScript(context) {
|
|
|
89681
89741
|
function visitTaggedTemplateExpression(node) {
|
|
89682
89742
|
return factory2.updateTaggedTemplateExpression(
|
|
89683
89743
|
node,
|
|
89684
|
-
visitNode(node.tag, visitor, isExpression),
|
|
89744
|
+
Debug.checkDefined(visitNode(node.tag, visitor, isExpression)),
|
|
89685
89745
|
/*typeArguments*/
|
|
89686
89746
|
void 0,
|
|
89687
|
-
visitNode(node.template, visitor,
|
|
89747
|
+
Debug.checkDefined(visitNode(node.template, visitor, isTemplateLiteral))
|
|
89688
89748
|
);
|
|
89689
89749
|
}
|
|
89690
89750
|
function visitJsxSelfClosingElement(node) {
|
|
89691
89751
|
return factory2.updateJsxSelfClosingElement(
|
|
89692
89752
|
node,
|
|
89693
|
-
visitNode(node.tagName, visitor, isJsxTagNameExpression),
|
|
89753
|
+
Debug.checkDefined(visitNode(node.tagName, visitor, isJsxTagNameExpression)),
|
|
89694
89754
|
/*typeArguments*/
|
|
89695
89755
|
void 0,
|
|
89696
|
-
visitNode(node.attributes, visitor, isJsxAttributes)
|
|
89756
|
+
Debug.checkDefined(visitNode(node.attributes, visitor, isJsxAttributes))
|
|
89697
89757
|
);
|
|
89698
89758
|
}
|
|
89699
89759
|
function visitJsxJsxOpeningElement(node) {
|
|
89700
89760
|
return factory2.updateJsxOpeningElement(
|
|
89701
89761
|
node,
|
|
89702
|
-
visitNode(node.tagName, visitor, isJsxTagNameExpression),
|
|
89762
|
+
Debug.checkDefined(visitNode(node.tagName, visitor, isJsxTagNameExpression)),
|
|
89703
89763
|
/*typeArguments*/
|
|
89704
89764
|
void 0,
|
|
89705
|
-
visitNode(node.attributes, visitor, isJsxAttributes)
|
|
89765
|
+
Debug.checkDefined(visitNode(node.attributes, visitor, isJsxAttributes))
|
|
89706
89766
|
);
|
|
89707
89767
|
}
|
|
89708
89768
|
function shouldEmitEnumDeclaration(node) {
|
|
@@ -89848,7 +89908,7 @@ function transformTypeScript(context) {
|
|
|
89848
89908
|
} else {
|
|
89849
89909
|
enableSubstitutionForNonQualifiedEnumMembers();
|
|
89850
89910
|
if (member.initializer) {
|
|
89851
|
-
return visitNode(member.initializer, visitor, isExpression);
|
|
89911
|
+
return Debug.checkDefined(visitNode(member.initializer, visitor, isExpression));
|
|
89852
89912
|
} else {
|
|
89853
89913
|
return factory2.createVoidZero();
|
|
89854
89914
|
}
|
|
@@ -90129,7 +90189,7 @@ function transformTypeScript(context) {
|
|
|
90129
90189
|
return allowEmpty || some(elements) ? factory2.updateNamedExports(node, elements) : void 0;
|
|
90130
90190
|
}
|
|
90131
90191
|
function visitNamespaceExports(node) {
|
|
90132
|
-
return factory2.updateNamespaceExport(node, visitNode(node.name, visitor, isIdentifier));
|
|
90192
|
+
return factory2.updateNamespaceExport(node, Debug.checkDefined(visitNode(node.name, visitor, isIdentifier)));
|
|
90133
90193
|
}
|
|
90134
90194
|
function visitNamedExportBindings(node, allowEmpty) {
|
|
90135
90195
|
return isNamespaceExport(node) ? visitNamespaceExports(node) : visitNamedExports(node, allowEmpty);
|
|
@@ -90607,6 +90667,7 @@ function transformClassFields(context) {
|
|
|
90607
90667
|
const info = accessPrivateIdentifier(node.left);
|
|
90608
90668
|
if (info) {
|
|
90609
90669
|
const receiver = visitNode(node.right, visitor, isExpression);
|
|
90670
|
+
Debug.assert(receiver);
|
|
90610
90671
|
return setOriginalNode(
|
|
90611
90672
|
context.getEmitHelperFactory().createClassPrivateFieldInHelper(info.brandCheckIdentifier, receiver),
|
|
90612
90673
|
node
|
|
@@ -90624,6 +90685,7 @@ function transformClassFields(context) {
|
|
|
90624
90685
|
}
|
|
90625
90686
|
function visitComputedPropertyName(node) {
|
|
90626
90687
|
let expression = visitNode(node.expression, visitor, isExpression);
|
|
90688
|
+
Debug.assert(expression);
|
|
90627
90689
|
if (some(pendingExpressions)) {
|
|
90628
90690
|
if (isParenthesizedExpression(expression)) {
|
|
90629
90691
|
expression = factory2.updateParenthesizedExpression(expression, factory2.inlineExpressions([...pendingExpressions, expression.expression]));
|
|
@@ -90705,6 +90767,7 @@ function transformClassFields(context) {
|
|
|
90705
90767
|
const temp = factory2.createTempVariable(hoistVariableDeclaration);
|
|
90706
90768
|
setSourceMapRange(temp, name.expression);
|
|
90707
90769
|
const expression = visitNode(name.expression, visitor, isExpression);
|
|
90770
|
+
Debug.assert(expression);
|
|
90708
90771
|
const assignment = factory2.createAssignment(temp, expression);
|
|
90709
90772
|
setSourceMapRange(assignment, name.expression);
|
|
90710
90773
|
getterName = factory2.updateComputedPropertyName(name, factory2.inlineExpressions([assignment, temp]));
|
|
@@ -90787,7 +90850,7 @@ function transformClassFields(context) {
|
|
|
90787
90850
|
return transformFieldInitializer(node);
|
|
90788
90851
|
}
|
|
90789
90852
|
function createPrivateIdentifierAccess(info, receiver) {
|
|
90790
|
-
return createPrivateIdentifierAccessHelper(info, visitNode(receiver, visitor, isExpression));
|
|
90853
|
+
return createPrivateIdentifierAccessHelper(info, Debug.checkDefined(visitNode(receiver, visitor, isExpression)));
|
|
90791
90854
|
}
|
|
90792
90855
|
function createPrivateIdentifierAccessHelper(info, receiver) {
|
|
90793
90856
|
setCommentRange(receiver, moveRangePos(receiver, -1));
|
|
@@ -90857,7 +90920,7 @@ function transformClassFields(context) {
|
|
|
90857
90920
|
if (classConstructor && superClassReference) {
|
|
90858
90921
|
const superProperty = factory2.createReflectGetCall(
|
|
90859
90922
|
superClassReference,
|
|
90860
|
-
visitNode(node.argumentExpression, visitor, isExpression),
|
|
90923
|
+
Debug.checkDefined(visitNode(node.argumentExpression, visitor, isExpression)),
|
|
90861
90924
|
classConstructor
|
|
90862
90925
|
);
|
|
90863
90926
|
setOriginalNode(superProperty, node.expression);
|
|
@@ -90874,6 +90937,7 @@ function transformClassFields(context) {
|
|
|
90874
90937
|
let info;
|
|
90875
90938
|
if (info = accessPrivateIdentifier(operand.name)) {
|
|
90876
90939
|
const receiver = visitNode(operand.expression, visitor, isExpression);
|
|
90940
|
+
Debug.assert(receiver);
|
|
90877
90941
|
const { readExpression, initializeExpression } = createCopiableReceiverExpr(receiver);
|
|
90878
90942
|
let expression = createPrivateIdentifierAccess(info, readExpression);
|
|
90879
90943
|
const temp = isPrefixUnaryExpression(node) || valueIsDiscarded ? void 0 : factory2.createTempVariable(hoistVariableDeclaration);
|
|
@@ -90910,7 +90974,7 @@ function transformClassFields(context) {
|
|
|
90910
90974
|
getterName = setterName = operand.argumentExpression;
|
|
90911
90975
|
} else {
|
|
90912
90976
|
getterName = factory2.createTempVariable(hoistVariableDeclaration);
|
|
90913
|
-
setterName = factory2.createAssignment(getterName, visitNode(operand.argumentExpression, visitor, isExpression));
|
|
90977
|
+
setterName = factory2.createAssignment(getterName, Debug.checkDefined(visitNode(operand.argumentExpression, visitor, isExpression)));
|
|
90914
90978
|
}
|
|
90915
90979
|
}
|
|
90916
90980
|
if (setterName && getterName) {
|
|
@@ -90944,7 +91008,7 @@ function transformClassFields(context) {
|
|
|
90944
91008
|
function visitExpressionStatement(node) {
|
|
90945
91009
|
return factory2.updateExpressionStatement(
|
|
90946
91010
|
node,
|
|
90947
|
-
visitNode(node.expression, discardedValueVisitor, isExpression)
|
|
91011
|
+
Debug.checkDefined(visitNode(node.expression, discardedValueVisitor, isExpression))
|
|
90948
91012
|
);
|
|
90949
91013
|
}
|
|
90950
91014
|
function createCopiableReceiverExpr(receiver) {
|
|
@@ -90962,25 +91026,25 @@ function transformClassFields(context) {
|
|
|
90962
91026
|
if (isCallChain(node)) {
|
|
90963
91027
|
return factory2.updateCallChain(
|
|
90964
91028
|
node,
|
|
90965
|
-
factory2.createPropertyAccessChain(visitNode(target, visitor), node.questionDotToken, "call"),
|
|
91029
|
+
factory2.createPropertyAccessChain(Debug.checkDefined(visitNode(target, visitor, isExpression)), node.questionDotToken, "call"),
|
|
90966
91030
|
/*questionDotToken*/
|
|
90967
91031
|
void 0,
|
|
90968
91032
|
/*typeArguments*/
|
|
90969
91033
|
void 0,
|
|
90970
|
-
[visitNode(thisArg, visitor, isExpression), ...visitNodes2(node.arguments, visitor, isExpression)]
|
|
91034
|
+
[Debug.checkDefined(visitNode(thisArg, visitor, isExpression)), ...visitNodes2(node.arguments, visitor, isExpression)]
|
|
90971
91035
|
);
|
|
90972
91036
|
}
|
|
90973
91037
|
return factory2.updateCallExpression(
|
|
90974
91038
|
node,
|
|
90975
|
-
factory2.createPropertyAccessExpression(visitNode(target, visitor), "call"),
|
|
91039
|
+
factory2.createPropertyAccessExpression(Debug.checkDefined(visitNode(target, visitor, isExpression)), "call"),
|
|
90976
91040
|
/*typeArguments*/
|
|
90977
91041
|
void 0,
|
|
90978
|
-
[visitNode(thisArg, visitor, isExpression), ...visitNodes2(node.arguments, visitor, isExpression)]
|
|
91042
|
+
[Debug.checkDefined(visitNode(thisArg, visitor, isExpression)), ...visitNodes2(node.arguments, visitor, isExpression)]
|
|
90979
91043
|
);
|
|
90980
91044
|
}
|
|
90981
91045
|
if (shouldTransformSuperInStaticInitializers && isSuperProperty(node.expression) && currentStaticPropertyDeclarationOrStaticBlock && (currentClassLexicalEnvironment == null ? void 0 : currentClassLexicalEnvironment.classConstructor)) {
|
|
90982
91046
|
const invocation = factory2.createFunctionCallCall(
|
|
90983
|
-
visitNode(node.expression, visitor, isExpression),
|
|
91047
|
+
Debug.checkDefined(visitNode(node.expression, visitor, isExpression)),
|
|
90984
91048
|
currentClassLexicalEnvironment.classConstructor,
|
|
90985
91049
|
visitNodes2(node.arguments, visitor, isExpression)
|
|
90986
91050
|
);
|
|
@@ -90996,19 +91060,19 @@ function transformClassFields(context) {
|
|
|
90996
91060
|
return factory2.updateTaggedTemplateExpression(
|
|
90997
91061
|
node,
|
|
90998
91062
|
factory2.createCallExpression(
|
|
90999
|
-
factory2.createPropertyAccessExpression(visitNode(target, visitor), "bind"),
|
|
91063
|
+
factory2.createPropertyAccessExpression(Debug.checkDefined(visitNode(target, visitor, isExpression)), "bind"),
|
|
91000
91064
|
/*typeArguments*/
|
|
91001
91065
|
void 0,
|
|
91002
|
-
[visitNode(thisArg, visitor, isExpression)]
|
|
91066
|
+
[Debug.checkDefined(visitNode(thisArg, visitor, isExpression))]
|
|
91003
91067
|
),
|
|
91004
91068
|
/*typeArguments*/
|
|
91005
91069
|
void 0,
|
|
91006
|
-
visitNode(node.template, visitor, isTemplateLiteral)
|
|
91070
|
+
Debug.checkDefined(visitNode(node.template, visitor, isTemplateLiteral))
|
|
91007
91071
|
);
|
|
91008
91072
|
}
|
|
91009
91073
|
if (shouldTransformSuperInStaticInitializers && isSuperProperty(node.tag) && currentStaticPropertyDeclarationOrStaticBlock && (currentClassLexicalEnvironment == null ? void 0 : currentClassLexicalEnvironment.classConstructor)) {
|
|
91010
91074
|
const invocation = factory2.createFunctionBindCall(
|
|
91011
|
-
visitNode(node.tag, visitor, isExpression),
|
|
91075
|
+
Debug.checkDefined(visitNode(node.tag, visitor, isExpression)),
|
|
91012
91076
|
currentClassLexicalEnvironment.classConstructor,
|
|
91013
91077
|
[]
|
|
91014
91078
|
);
|
|
@@ -91019,7 +91083,7 @@ function transformClassFields(context) {
|
|
|
91019
91083
|
invocation,
|
|
91020
91084
|
/*typeArguments*/
|
|
91021
91085
|
void 0,
|
|
91022
|
-
visitNode(node.template, visitor, isTemplateLiteral)
|
|
91086
|
+
Debug.checkDefined(visitNode(node.template, visitor, isTemplateLiteral))
|
|
91023
91087
|
);
|
|
91024
91088
|
}
|
|
91025
91089
|
return visitEachChild(node, visitor, context);
|
|
@@ -91049,9 +91113,9 @@ function transformClassFields(context) {
|
|
|
91049
91113
|
pendingExpressions = void 0;
|
|
91050
91114
|
node = factory2.updateBinaryExpression(
|
|
91051
91115
|
node,
|
|
91052
|
-
visitNode(node.left, assignmentTargetVisitor),
|
|
91116
|
+
Debug.checkDefined(visitNode(node.left, assignmentTargetVisitor, isExpression)),
|
|
91053
91117
|
node.operatorToken,
|
|
91054
|
-
visitNode(node.right, visitor)
|
|
91118
|
+
Debug.checkDefined(visitNode(node.right, visitor, isExpression))
|
|
91055
91119
|
);
|
|
91056
91120
|
const expr = some(pendingExpressions) ? factory2.inlineExpressions(compact([...pendingExpressions, node])) : node;
|
|
91057
91121
|
pendingExpressions = savedPendingExpressions;
|
|
@@ -91076,7 +91140,7 @@ function transformClassFields(context) {
|
|
|
91076
91140
|
node,
|
|
91077
91141
|
visitInvalidSuperProperty(node.left),
|
|
91078
91142
|
node.operatorToken,
|
|
91079
|
-
visitNode(node.right, visitor, isExpression)
|
|
91143
|
+
Debug.checkDefined(visitNode(node.right, visitor, isExpression))
|
|
91080
91144
|
);
|
|
91081
91145
|
}
|
|
91082
91146
|
if (classConstructor && superClassReference) {
|
|
@@ -91096,6 +91160,7 @@ function transformClassFields(context) {
|
|
|
91096
91160
|
);
|
|
91097
91161
|
setOriginalNode(superPropertyGet, node.left);
|
|
91098
91162
|
setTextRange(superPropertyGet, node.left);
|
|
91163
|
+
Debug.assert(expression);
|
|
91099
91164
|
expression = factory2.createBinaryExpression(
|
|
91100
91165
|
superPropertyGet,
|
|
91101
91166
|
getNonAssignmentOperatorForCompoundAssignment(node.operatorToken.kind),
|
|
@@ -91105,9 +91170,11 @@ function transformClassFields(context) {
|
|
|
91105
91170
|
}
|
|
91106
91171
|
const temp = valueIsDiscarded ? void 0 : factory2.createTempVariable(hoistVariableDeclaration);
|
|
91107
91172
|
if (temp) {
|
|
91173
|
+
Debug.assert(expression);
|
|
91108
91174
|
expression = factory2.createAssignment(temp, expression);
|
|
91109
91175
|
setTextRange(temp, node);
|
|
91110
91176
|
}
|
|
91177
|
+
Debug.assert(expression);
|
|
91111
91178
|
expression = factory2.createReflectSetCall(
|
|
91112
91179
|
superClassReference,
|
|
91113
91180
|
setterName,
|
|
@@ -91131,8 +91198,8 @@ function transformClassFields(context) {
|
|
|
91131
91198
|
return visitEachChild(node, visitor, context);
|
|
91132
91199
|
}
|
|
91133
91200
|
function createPrivateIdentifierAssignment(info, receiver, right, operator) {
|
|
91134
|
-
receiver = visitNode(receiver, visitor, isExpression);
|
|
91135
|
-
right = visitNode(right, visitor, isExpression);
|
|
91201
|
+
receiver = Debug.checkDefined(visitNode(receiver, visitor, isExpression));
|
|
91202
|
+
right = Debug.checkDefined(visitNode(right, visitor, isExpression));
|
|
91136
91203
|
if (isCompoundAssignment(operator)) {
|
|
91137
91204
|
const { readExpression, initializeExpression } = createCopiableReceiverExpr(receiver);
|
|
91138
91205
|
receiver = initializeExpression || readExpression;
|
|
@@ -91235,7 +91302,7 @@ function transformClassFields(context) {
|
|
|
91235
91302
|
node,
|
|
91236
91303
|
factory2.createAssignment(
|
|
91237
91304
|
temp,
|
|
91238
|
-
visitNode(node.expression, visitor, isExpression)
|
|
91305
|
+
Debug.checkDefined(visitNode(node.expression, visitor, isExpression))
|
|
91239
91306
|
),
|
|
91240
91307
|
/*typeArguments*/
|
|
91241
91308
|
void 0
|
|
@@ -91797,7 +91864,7 @@ function transformClassFields(context) {
|
|
|
91797
91864
|
) : factory2.updateElementAccessExpression(
|
|
91798
91865
|
node,
|
|
91799
91866
|
factory2.createVoidZero(),
|
|
91800
|
-
visitNode(node.argumentExpression, visitor, isExpression)
|
|
91867
|
+
Debug.checkDefined(visitNode(node.argumentExpression, visitor, isExpression))
|
|
91801
91868
|
);
|
|
91802
91869
|
}
|
|
91803
91870
|
function onEmitNode(hint, node, emitCallback) {
|
|
@@ -91914,6 +91981,7 @@ function transformClassFields(context) {
|
|
|
91914
91981
|
function getPropertyNameExpressionIfNeeded(name, shouldHoist) {
|
|
91915
91982
|
if (isComputedPropertyName(name)) {
|
|
91916
91983
|
const expression = visitNode(name.expression, visitor, isExpression);
|
|
91984
|
+
Debug.assert(expression);
|
|
91917
91985
|
const innerExpression = skipPartiallyEmittedExpressions(expression);
|
|
91918
91986
|
const inlinable = isSimpleInlineableExpression(innerExpression);
|
|
91919
91987
|
const alreadyTransformed = isAssignmentExpression(innerExpression) && isGeneratedIdentifier(innerExpression.left);
|
|
@@ -92135,7 +92203,7 @@ function transformClassFields(context) {
|
|
|
92135
92203
|
/*reservedInNestedScopes*/
|
|
92136
92204
|
true
|
|
92137
92205
|
);
|
|
92138
|
-
getPendingExpressions().push(factory2.createBinaryExpression(receiver, 63 /* EqualsToken */, visitNode(node.expression, visitor, isExpression)));
|
|
92206
|
+
getPendingExpressions().push(factory2.createBinaryExpression(receiver, 63 /* EqualsToken */, Debug.checkDefined(visitNode(node.expression, visitor, isExpression))));
|
|
92139
92207
|
}
|
|
92140
92208
|
return factory2.createAssignmentTargetWrapper(
|
|
92141
92209
|
parameter,
|
|
@@ -92148,6 +92216,7 @@ function transformClassFields(context) {
|
|
|
92148
92216
|
);
|
|
92149
92217
|
}
|
|
92150
92218
|
function visitArrayAssignmentTarget(node) {
|
|
92219
|
+
Debug.assertNode(node, isBindingOrAssignmentElement);
|
|
92151
92220
|
const target = getTargetOfBindingOrAssignmentElement(node);
|
|
92152
92221
|
if (target) {
|
|
92153
92222
|
let wrapped;
|
|
@@ -92182,7 +92251,7 @@ function transformClassFields(context) {
|
|
|
92182
92251
|
node,
|
|
92183
92252
|
wrapped,
|
|
92184
92253
|
node.operatorToken,
|
|
92185
|
-
visitNode(node.right, visitor, isExpression)
|
|
92254
|
+
Debug.checkDefined(visitNode(node.right, visitor, isExpression))
|
|
92186
92255
|
);
|
|
92187
92256
|
} else if (isSpreadElement(node)) {
|
|
92188
92257
|
return factory2.updateSpreadElement(node, wrapped);
|
|
@@ -92228,14 +92297,14 @@ function transformClassFields(context) {
|
|
|
92228
92297
|
const initializer = getInitializerOfBindingOrAssignmentElement(node);
|
|
92229
92298
|
return factory2.updatePropertyAssignment(
|
|
92230
92299
|
node,
|
|
92231
|
-
visitNode(node.name, visitor, isPropertyName),
|
|
92232
|
-
wrapped ? initializer ? factory2.createAssignment(wrapped, visitNode(initializer, visitor)) : wrapped : visitNode(node.initializer, assignmentTargetVisitor, isExpression)
|
|
92300
|
+
Debug.checkDefined(visitNode(node.name, visitor, isPropertyName)),
|
|
92301
|
+
wrapped ? initializer ? factory2.createAssignment(wrapped, Debug.checkDefined(visitNode(initializer, visitor, isExpression))) : wrapped : Debug.checkDefined(visitNode(node.initializer, assignmentTargetVisitor, isExpression))
|
|
92233
92302
|
);
|
|
92234
92303
|
}
|
|
92235
92304
|
if (isSpreadAssignment(node)) {
|
|
92236
92305
|
return factory2.updateSpreadAssignment(
|
|
92237
92306
|
node,
|
|
92238
|
-
wrapped || visitNode(node.expression, assignmentTargetVisitor, isExpression)
|
|
92307
|
+
wrapped || Debug.checkDefined(visitNode(node.expression, assignmentTargetVisitor, isExpression))
|
|
92239
92308
|
);
|
|
92240
92309
|
}
|
|
92241
92310
|
Debug.assert(wrapped === void 0, "Should not have generated a wrapped target");
|
|
@@ -92849,7 +92918,7 @@ function transformLegacyDecorators(context) {
|
|
|
92849
92918
|
return factory2.updateConstructorDeclaration(
|
|
92850
92919
|
node,
|
|
92851
92920
|
visitNodes2(node.modifiers, modifierVisitor, isModifier),
|
|
92852
|
-
visitNodes2(node.parameters, visitor,
|
|
92921
|
+
visitNodes2(node.parameters, visitor, isParameter),
|
|
92853
92922
|
visitNode(node.body, visitor, isBlock)
|
|
92854
92923
|
);
|
|
92855
92924
|
}
|
|
@@ -92865,12 +92934,12 @@ function transformLegacyDecorators(context) {
|
|
|
92865
92934
|
node,
|
|
92866
92935
|
visitNodes2(node.modifiers, modifierVisitor, isModifier),
|
|
92867
92936
|
node.asteriskToken,
|
|
92868
|
-
visitNode(node.name, visitor, isPropertyName),
|
|
92937
|
+
Debug.checkDefined(visitNode(node.name, visitor, isPropertyName)),
|
|
92869
92938
|
/*questionToken*/
|
|
92870
92939
|
void 0,
|
|
92871
92940
|
/*typeParameters*/
|
|
92872
92941
|
void 0,
|
|
92873
|
-
visitNodes2(node.parameters, visitor,
|
|
92942
|
+
visitNodes2(node.parameters, visitor, isParameter),
|
|
92874
92943
|
/*type*/
|
|
92875
92944
|
void 0,
|
|
92876
92945
|
visitNode(node.body, visitor, isBlock)
|
|
@@ -92880,8 +92949,8 @@ function transformLegacyDecorators(context) {
|
|
|
92880
92949
|
return finishClassElement(factory2.updateGetAccessorDeclaration(
|
|
92881
92950
|
node,
|
|
92882
92951
|
visitNodes2(node.modifiers, modifierVisitor, isModifier),
|
|
92883
|
-
visitNode(node.name, visitor, isPropertyName),
|
|
92884
|
-
visitNodes2(node.parameters, visitor,
|
|
92952
|
+
Debug.checkDefined(visitNode(node.name, visitor, isPropertyName)),
|
|
92953
|
+
visitNodes2(node.parameters, visitor, isParameter),
|
|
92885
92954
|
/*type*/
|
|
92886
92955
|
void 0,
|
|
92887
92956
|
visitNode(node.body, visitor, isBlock)
|
|
@@ -92891,8 +92960,8 @@ function transformLegacyDecorators(context) {
|
|
|
92891
92960
|
return finishClassElement(factory2.updateSetAccessorDeclaration(
|
|
92892
92961
|
node,
|
|
92893
92962
|
visitNodes2(node.modifiers, modifierVisitor, isModifier),
|
|
92894
|
-
visitNode(node.name, visitor, isPropertyName),
|
|
92895
|
-
visitNodes2(node.parameters, visitor,
|
|
92963
|
+
Debug.checkDefined(visitNode(node.name, visitor, isPropertyName)),
|
|
92964
|
+
visitNodes2(node.parameters, visitor, isParameter),
|
|
92896
92965
|
visitNode(node.body, visitor, isBlock)
|
|
92897
92966
|
), node);
|
|
92898
92967
|
}
|
|
@@ -92903,7 +92972,7 @@ function transformLegacyDecorators(context) {
|
|
|
92903
92972
|
return finishClassElement(factory2.updatePropertyDeclaration(
|
|
92904
92973
|
node,
|
|
92905
92974
|
visitNodes2(node.modifiers, modifierVisitor, isModifier),
|
|
92906
|
-
visitNode(node.name, visitor, isPropertyName),
|
|
92975
|
+
Debug.checkDefined(visitNode(node.name, visitor, isPropertyName)),
|
|
92907
92976
|
/*questionOrExclamationToken*/
|
|
92908
92977
|
void 0,
|
|
92909
92978
|
/*type*/
|
|
@@ -92916,7 +92985,7 @@ function transformLegacyDecorators(context) {
|
|
|
92916
92985
|
node,
|
|
92917
92986
|
elideNodes(factory2, node.modifiers),
|
|
92918
92987
|
node.dotDotDotToken,
|
|
92919
|
-
visitNode(node.name, visitor, isBindingName),
|
|
92988
|
+
Debug.checkDefined(visitNode(node.name, visitor, isBindingName)),
|
|
92920
92989
|
/*questionToken*/
|
|
92921
92990
|
void 0,
|
|
92922
92991
|
/*type*/
|
|
@@ -93013,7 +93082,7 @@ function transformLegacyDecorators(context) {
|
|
|
93013
93082
|
return expression;
|
|
93014
93083
|
}
|
|
93015
93084
|
function transformDecorator(decorator) {
|
|
93016
|
-
return visitNode(decorator.expression, visitor, isExpression);
|
|
93085
|
+
return Debug.checkDefined(visitNode(decorator.expression, visitor, isExpression));
|
|
93017
93086
|
}
|
|
93018
93087
|
function transformDecoratorsOfParameter(decorators, parameterOffset) {
|
|
93019
93088
|
let expressions;
|
|
@@ -93279,21 +93348,21 @@ function transformES2017(context) {
|
|
|
93279
93348
|
node.initializer,
|
|
93280
93349
|
/*hasReceiver*/
|
|
93281
93350
|
true
|
|
93282
|
-
) : visitNode(node.initializer, visitor, isForInitializer),
|
|
93283
|
-
visitNode(node.expression, visitor, isExpression),
|
|
93351
|
+
) : Debug.checkDefined(visitNode(node.initializer, visitor, isForInitializer)),
|
|
93352
|
+
Debug.checkDefined(visitNode(node.expression, visitor, isExpression)),
|
|
93284
93353
|
visitIterationBody(node.statement, asyncBodyVisitor, context)
|
|
93285
93354
|
);
|
|
93286
93355
|
}
|
|
93287
93356
|
function visitForOfStatementInAsyncBody(node) {
|
|
93288
93357
|
return factory2.updateForOfStatement(
|
|
93289
93358
|
node,
|
|
93290
|
-
visitNode(node.awaitModifier, visitor,
|
|
93359
|
+
visitNode(node.awaitModifier, visitor, isAwaitKeyword),
|
|
93291
93360
|
isVariableDeclarationListWithCollidingName(node.initializer) ? visitVariableDeclarationListWithCollidingNames(
|
|
93292
93361
|
node.initializer,
|
|
93293
93362
|
/*hasReceiver*/
|
|
93294
93363
|
true
|
|
93295
|
-
) : visitNode(node.initializer, visitor, isForInitializer),
|
|
93296
|
-
visitNode(node.expression, visitor, isExpression),
|
|
93364
|
+
) : Debug.checkDefined(visitNode(node.initializer, visitor, isForInitializer)),
|
|
93365
|
+
Debug.checkDefined(visitNode(node.expression, visitor, isExpression)),
|
|
93297
93366
|
visitIterationBody(node.statement, asyncBodyVisitor, context)
|
|
93298
93367
|
);
|
|
93299
93368
|
}
|
|
@@ -93330,7 +93399,7 @@ function transformES2017(context) {
|
|
|
93330
93399
|
function visitConstructorDeclaration(node) {
|
|
93331
93400
|
return factory2.updateConstructorDeclaration(
|
|
93332
93401
|
node,
|
|
93333
|
-
visitNodes2(node.modifiers, visitor,
|
|
93402
|
+
visitNodes2(node.modifiers, visitor, isModifier),
|
|
93334
93403
|
visitParameterList(node.parameters, visitor, context),
|
|
93335
93404
|
transformMethodBody(node)
|
|
93336
93405
|
);
|
|
@@ -93388,7 +93457,7 @@ function transformES2017(context) {
|
|
|
93388
93457
|
function visitFunctionExpression(node) {
|
|
93389
93458
|
return factory2.updateFunctionExpression(
|
|
93390
93459
|
node,
|
|
93391
|
-
visitNodes2(node.modifiers, visitor,
|
|
93460
|
+
visitNodes2(node.modifiers, visitor, isModifier),
|
|
93392
93461
|
node.asteriskToken,
|
|
93393
93462
|
node.name,
|
|
93394
93463
|
/*typeParameters*/
|
|
@@ -93402,7 +93471,7 @@ function transformES2017(context) {
|
|
|
93402
93471
|
function visitArrowFunction(node) {
|
|
93403
93472
|
return factory2.updateArrowFunction(
|
|
93404
93473
|
node,
|
|
93405
|
-
visitNodes2(node.modifiers, visitor,
|
|
93474
|
+
visitNodes2(node.modifiers, visitor, isModifier),
|
|
93406
93475
|
/*typeParameters*/
|
|
93407
93476
|
void 0,
|
|
93408
93477
|
visitParameterList(node.parameters, visitor, context),
|
|
@@ -93459,7 +93528,7 @@ function transformES2017(context) {
|
|
|
93459
93528
|
),
|
|
93460
93529
|
node
|
|
93461
93530
|
);
|
|
93462
|
-
return visitNode(converted, visitor, isExpression);
|
|
93531
|
+
return Debug.checkDefined(visitNode(converted, visitor, isExpression));
|
|
93463
93532
|
}
|
|
93464
93533
|
function collidesWithParameterName({ name }) {
|
|
93465
93534
|
if (isIdentifier(name)) {
|
|
@@ -93591,7 +93660,7 @@ function transformES2017(context) {
|
|
|
93591
93660
|
if (isBlock(body)) {
|
|
93592
93661
|
return factory2.updateBlock(body, visitNodes2(body.statements, asyncBodyVisitor, isStatement, start2));
|
|
93593
93662
|
} else {
|
|
93594
|
-
return factory2.converters.convertToFunctionBlock(visitNode(body, asyncBodyVisitor, isConciseBody));
|
|
93663
|
+
return factory2.converters.convertToFunctionBlock(Debug.checkDefined(visitNode(body, asyncBodyVisitor, isConciseBody)));
|
|
93595
93664
|
}
|
|
93596
93665
|
}
|
|
93597
93666
|
function getPromiseConstructor(type) {
|
|
@@ -94704,7 +94773,7 @@ function transformES2018(context) {
|
|
|
94704
94773
|
/*questionToken*/
|
|
94705
94774
|
void 0,
|
|
94706
94775
|
visitor,
|
|
94707
|
-
|
|
94776
|
+
isQuestionToken
|
|
94708
94777
|
),
|
|
94709
94778
|
/*typeParameters*/
|
|
94710
94779
|
void 0,
|
|
@@ -95832,7 +95901,7 @@ function transformJsx(context) {
|
|
|
95832
95901
|
return element;
|
|
95833
95902
|
}
|
|
95834
95903
|
function transformJsxSpreadAttributeToSpreadAssignment(node) {
|
|
95835
|
-
return factory2.createSpreadAssignment(visitNode(node.expression, visitor, isExpression));
|
|
95904
|
+
return factory2.createSpreadAssignment(Debug.checkDefined(visitNode(node.expression, visitor, isExpression)));
|
|
95836
95905
|
}
|
|
95837
95906
|
function transformJsxAttributesToObjectProps(attrs, children) {
|
|
95838
95907
|
const target = getEmitScriptTarget(compilerOptions);
|
|
@@ -95862,7 +95931,7 @@ function transformJsx(context) {
|
|
|
95862
95931
|
return singleOrUndefined(expressions) || emitHelpers().createAssignHelper(expressions);
|
|
95863
95932
|
}
|
|
95864
95933
|
function transformJsxSpreadAttributeToExpression(node) {
|
|
95865
|
-
return visitNode(node.expression, visitor, isExpression);
|
|
95934
|
+
return Debug.checkDefined(visitNode(node.expression, visitor, isExpression));
|
|
95866
95935
|
}
|
|
95867
95936
|
function transformJsxAttributeToObjectLiteralElement(node) {
|
|
95868
95937
|
const name = getAttributeName(node);
|
|
@@ -95882,7 +95951,7 @@ function transformJsx(context) {
|
|
|
95882
95951
|
if (node.expression === void 0) {
|
|
95883
95952
|
return factory2.createTrue();
|
|
95884
95953
|
}
|
|
95885
|
-
return visitNode(node.expression, visitor, isExpression);
|
|
95954
|
+
return Debug.checkDefined(visitNode(node.expression, visitor, isExpression));
|
|
95886
95955
|
}
|
|
95887
95956
|
if (isJsxElement(node)) {
|
|
95888
95957
|
return visitJsxElement(
|
|
@@ -96627,7 +96696,7 @@ function transformES2015(context) {
|
|
|
96627
96696
|
[
|
|
96628
96697
|
factory2.createPropertyAssignment(
|
|
96629
96698
|
factory2.createIdentifier("value"),
|
|
96630
|
-
node.expression ? visitNode(node.expression, visitor, isExpression) : factory2.createVoidZero()
|
|
96699
|
+
node.expression ? Debug.checkDefined(visitNode(node.expression, visitor, isExpression)) : factory2.createVoidZero()
|
|
96631
96700
|
)
|
|
96632
96701
|
]
|
|
96633
96702
|
)
|
|
@@ -96798,7 +96867,7 @@ function transformES2015(context) {
|
|
|
96798
96867
|
outer,
|
|
96799
96868
|
/*typeArguments*/
|
|
96800
96869
|
void 0,
|
|
96801
|
-
extendsClauseElement ? [visitNode(extendsClauseElement.expression, visitor, isExpression)] : []
|
|
96870
|
+
extendsClauseElement ? [Debug.checkDefined(visitNode(extendsClauseElement.expression, visitor, isExpression))] : []
|
|
96802
96871
|
)
|
|
96803
96872
|
);
|
|
96804
96873
|
addSyntheticLeadingComment(result, 3 /* MultiLineCommentTrivia */, "* @class ");
|
|
@@ -97140,7 +97209,7 @@ function transformES2015(context) {
|
|
|
97140
97209
|
factory2.createExpressionStatement(
|
|
97141
97210
|
factory2.createAssignment(
|
|
97142
97211
|
factory2.getGeneratedNameForNode(parameter),
|
|
97143
|
-
visitNode(initializer, visitor, isExpression)
|
|
97212
|
+
Debug.checkDefined(visitNode(initializer, visitor, isExpression))
|
|
97144
97213
|
)
|
|
97145
97214
|
),
|
|
97146
97215
|
2097152 /* CustomPrologue */
|
|
@@ -97151,7 +97220,7 @@ function transformES2015(context) {
|
|
|
97151
97220
|
return false;
|
|
97152
97221
|
}
|
|
97153
97222
|
function insertDefaultValueAssignmentForInitializer(statements, parameter, name, initializer) {
|
|
97154
|
-
initializer = visitNode(initializer, visitor, isExpression);
|
|
97223
|
+
initializer = Debug.checkDefined(visitNode(initializer, visitor, isExpression));
|
|
97155
97224
|
const statement = factory2.createIfStatement(
|
|
97156
97225
|
factory2.createTypeCheck(factory2.cloneNode(name), "undefined"),
|
|
97157
97226
|
setEmitFlags(
|
|
@@ -97427,6 +97496,7 @@ function transformES2015(context) {
|
|
|
97427
97496
|
container
|
|
97428
97497
|
);
|
|
97429
97498
|
const propertyName = visitNode(member.name, visitor, isPropertyName);
|
|
97499
|
+
Debug.assert(propertyName);
|
|
97430
97500
|
let e;
|
|
97431
97501
|
if (!isPrivateIdentifier(propertyName) && getUseDefineForClassFields(context.getCompilerOptions())) {
|
|
97432
97502
|
const name = isComputedPropertyName(propertyName) ? propertyName.expression : isIdentifier(propertyName) ? factory2.createStringLiteral(unescapeLeadingUnderscores(propertyName.escapedText)) : propertyName;
|
|
@@ -97470,6 +97540,7 @@ function transformES2015(context) {
|
|
|
97470
97540
|
setEmitFlags(target, 3072 /* NoComments */ | 64 /* NoTrailingSourceMap */);
|
|
97471
97541
|
setSourceMapRange(target, firstAccessor.name);
|
|
97472
97542
|
const visitedAccessorName = visitNode(firstAccessor.name, visitor, isPropertyName);
|
|
97543
|
+
Debug.assert(visitedAccessorName);
|
|
97473
97544
|
if (isPrivateIdentifier(visitedAccessorName)) {
|
|
97474
97545
|
return Debug.failBadSyntaxKind(visitedAccessorName, "Encountered unhandled private identifier while transforming ES2015.");
|
|
97475
97546
|
}
|
|
@@ -97742,9 +97813,9 @@ function transformES2015(context) {
|
|
|
97742
97813
|
if (node.operatorToken.kind === 27 /* CommaToken */) {
|
|
97743
97814
|
return factory2.updateBinaryExpression(
|
|
97744
97815
|
node,
|
|
97745
|
-
visitNode(node.left, visitorWithUnusedExpressionResult, isExpression),
|
|
97816
|
+
Debug.checkDefined(visitNode(node.left, visitorWithUnusedExpressionResult, isExpression)),
|
|
97746
97817
|
node.operatorToken,
|
|
97747
|
-
visitNode(node.right, expressionResultIsUnused2 ? visitorWithUnusedExpressionResult : visitor, isExpression)
|
|
97818
|
+
Debug.checkDefined(visitNode(node.right, expressionResultIsUnused2 ? visitorWithUnusedExpressionResult : visitor, isExpression))
|
|
97748
97819
|
);
|
|
97749
97820
|
}
|
|
97750
97821
|
return visitEachChild(node, visitor, context);
|
|
@@ -97759,6 +97830,7 @@ function transformES2015(context) {
|
|
|
97759
97830
|
const visited = visitNode(element, i < node.elements.length - 1 ? visitorWithUnusedExpressionResult : visitor, isExpression);
|
|
97760
97831
|
if (result || visited !== element) {
|
|
97761
97832
|
result || (result = node.elements.slice(0, i));
|
|
97833
|
+
Debug.assert(visited);
|
|
97762
97834
|
result.push(visited);
|
|
97763
97835
|
}
|
|
97764
97836
|
}
|
|
@@ -97785,7 +97857,7 @@ function transformES2015(context) {
|
|
|
97785
97857
|
0 /* All */
|
|
97786
97858
|
);
|
|
97787
97859
|
} else {
|
|
97788
|
-
assignment = factory2.createBinaryExpression(decl.name, 63 /* EqualsToken */, visitNode(decl.initializer, visitor, isExpression));
|
|
97860
|
+
assignment = factory2.createBinaryExpression(decl.name, 63 /* EqualsToken */, Debug.checkDefined(visitNode(decl.initializer, visitor, isExpression)));
|
|
97789
97861
|
setTextRange(assignment, decl);
|
|
97790
97862
|
}
|
|
97791
97863
|
assignments = append(assignments, assignment);
|
|
@@ -97807,7 +97879,7 @@ function transformES2015(context) {
|
|
|
97807
97879
|
if (node.flags & 3 /* BlockScoped */) {
|
|
97808
97880
|
enableSubstitutionsForBlockScopedBindings();
|
|
97809
97881
|
}
|
|
97810
|
-
const declarations =
|
|
97882
|
+
const declarations = visitNodes2(node.declarations, node.flags & 1 /* Let */ ? visitVariableDeclarationInLetDeclarationList : visitVariableDeclaration, isVariableDeclaration);
|
|
97811
97883
|
const declarationList = factory2.createVariableDeclarationList(declarations);
|
|
97812
97884
|
setOriginalNode(declarationList, node);
|
|
97813
97885
|
setTextRange(declarationList, node);
|
|
@@ -97891,7 +97963,7 @@ function transformES2015(context) {
|
|
|
97891
97963
|
statement,
|
|
97892
97964
|
/*outermostLabeledStatement*/
|
|
97893
97965
|
node
|
|
97894
|
-
) : factory2.restoreEnclosingLabel(visitNode(statement, visitor, isStatement, factory2.liftToBlock), node, convertedLoopState && resetLabel);
|
|
97966
|
+
) : factory2.restoreEnclosingLabel(Debug.checkDefined(visitNode(statement, visitor, isStatement, factory2.liftToBlock)), node, convertedLoopState && resetLabel);
|
|
97895
97967
|
}
|
|
97896
97968
|
function visitIterationStatement(node, outermostLabeledStatement) {
|
|
97897
97969
|
switch (node.kind) {
|
|
@@ -97934,7 +98006,7 @@ function transformES2015(context) {
|
|
|
97934
98006
|
visitNode(node.initializer, visitorWithUnusedExpressionResult, isForInitializer),
|
|
97935
98007
|
visitNode(node.condition, visitor, isExpression),
|
|
97936
98008
|
visitNode(node.incrementor, visitorWithUnusedExpressionResult, isExpression),
|
|
97937
|
-
visitNode(node.statement, visitor, isStatement, factory2.liftToBlock)
|
|
98009
|
+
Debug.checkDefined(visitNode(node.statement, visitor, isStatement, factory2.liftToBlock))
|
|
97938
98010
|
);
|
|
97939
98011
|
}
|
|
97940
98012
|
function visitForInStatement(node, outermostLabeledStatement) {
|
|
@@ -98020,13 +98092,14 @@ function transformES2015(context) {
|
|
|
98020
98092
|
)));
|
|
98021
98093
|
} else {
|
|
98022
98094
|
setTextRangeEnd(assignment, initializer.end);
|
|
98023
|
-
statements.push(setTextRange(factory2.createExpressionStatement(visitNode(assignment, visitor, isExpression)), moveRangeEnd(initializer, -1)));
|
|
98095
|
+
statements.push(setTextRange(factory2.createExpressionStatement(Debug.checkDefined(visitNode(assignment, visitor, isExpression))), moveRangeEnd(initializer, -1)));
|
|
98024
98096
|
}
|
|
98025
98097
|
}
|
|
98026
98098
|
if (convertedLoopBodyStatements) {
|
|
98027
98099
|
return createSyntheticBlockForConvertedStatements(addRange(statements, convertedLoopBodyStatements));
|
|
98028
98100
|
} else {
|
|
98029
98101
|
const statement = visitNode(node.statement, visitor, isStatement, factory2.liftToBlock);
|
|
98102
|
+
Debug.assert(statement);
|
|
98030
98103
|
if (isBlock(statement)) {
|
|
98031
98104
|
return factory2.updateBlock(statement, setTextRange(factory2.createNodeArray(concatenate(statements, statement.statements)), statement.statements));
|
|
98032
98105
|
} else {
|
|
@@ -98047,6 +98120,7 @@ function transformES2015(context) {
|
|
|
98047
98120
|
}
|
|
98048
98121
|
function convertForOfStatementForArray(node, outermostLabeledStatement, convertedLoopBodyStatements) {
|
|
98049
98122
|
const expression = visitNode(node.expression, visitor, isExpression);
|
|
98123
|
+
Debug.assert(expression);
|
|
98050
98124
|
const counter = factory2.createLoopVariable();
|
|
98051
98125
|
const rhsReference = isIdentifier(expression) ? factory2.getGeneratedNameForNode(expression) : factory2.createTempVariable(
|
|
98052
98126
|
/*recordTempVariable*/
|
|
@@ -98106,6 +98180,7 @@ function transformES2015(context) {
|
|
|
98106
98180
|
}
|
|
98107
98181
|
function convertForOfStatementForIterable(node, outermostLabeledStatement, convertedLoopBodyStatements, ancestorFacts) {
|
|
98108
98182
|
const expression = visitNode(node.expression, visitor, isExpression);
|
|
98183
|
+
Debug.assert(expression);
|
|
98109
98184
|
const iterator = isIdentifier(expression) ? factory2.getGeneratedNameForNode(expression) : factory2.createTempVariable(
|
|
98110
98185
|
/*recordTempVariable*/
|
|
98111
98186
|
void 0
|
|
@@ -98363,7 +98438,7 @@ function transformES2015(context) {
|
|
|
98363
98438
|
loop = factory2.restoreEnclosingLabel(clone2, outermostLabeledStatement, convertedLoopState && resetLabel);
|
|
98364
98439
|
}
|
|
98365
98440
|
} else {
|
|
98366
|
-
const clone2 = convertIterationStatementCore(node, initializerFunction, visitNode(node.statement, visitor, isStatement, factory2.liftToBlock));
|
|
98441
|
+
const clone2 = convertIterationStatementCore(node, initializerFunction, Debug.checkDefined(visitNode(node.statement, visitor, isStatement, factory2.liftToBlock)));
|
|
98367
98442
|
loop = factory2.restoreEnclosingLabel(clone2, outermostLabeledStatement, convertedLoopState && resetLabel);
|
|
98368
98443
|
}
|
|
98369
98444
|
statements.push(loop);
|
|
@@ -98401,16 +98476,16 @@ function transformES2015(context) {
|
|
|
98401
98476
|
node,
|
|
98402
98477
|
/*awaitModifier*/
|
|
98403
98478
|
void 0,
|
|
98404
|
-
visitNode(node.initializer, visitor, isForInitializer),
|
|
98405
|
-
visitNode(node.expression, visitor, isExpression),
|
|
98479
|
+
Debug.checkDefined(visitNode(node.initializer, visitor, isForInitializer)),
|
|
98480
|
+
Debug.checkDefined(visitNode(node.expression, visitor, isExpression)),
|
|
98406
98481
|
convertedLoopBody
|
|
98407
98482
|
);
|
|
98408
98483
|
}
|
|
98409
98484
|
function convertForInStatement(node, convertedLoopBody) {
|
|
98410
98485
|
return factory2.updateForInStatement(
|
|
98411
98486
|
node,
|
|
98412
|
-
visitNode(node.initializer, visitor, isForInitializer),
|
|
98413
|
-
visitNode(node.expression, visitor, isExpression),
|
|
98487
|
+
Debug.checkDefined(visitNode(node.initializer, visitor, isForInitializer)),
|
|
98488
|
+
Debug.checkDefined(visitNode(node.expression, visitor, isExpression)),
|
|
98414
98489
|
convertedLoopBody
|
|
98415
98490
|
);
|
|
98416
98491
|
}
|
|
@@ -98418,13 +98493,13 @@ function transformES2015(context) {
|
|
|
98418
98493
|
return factory2.updateDoStatement(
|
|
98419
98494
|
node,
|
|
98420
98495
|
convertedLoopBody,
|
|
98421
|
-
visitNode(node.expression, visitor, isExpression)
|
|
98496
|
+
Debug.checkDefined(visitNode(node.expression, visitor, isExpression))
|
|
98422
98497
|
);
|
|
98423
98498
|
}
|
|
98424
98499
|
function convertWhileStatement(node, convertedLoopBody) {
|
|
98425
98500
|
return factory2.updateWhileStatement(
|
|
98426
98501
|
node,
|
|
98427
|
-
visitNode(node.expression, visitor, isExpression),
|
|
98502
|
+
Debug.checkDefined(visitNode(node.expression, visitor, isExpression)),
|
|
98428
98503
|
convertedLoopBody
|
|
98429
98504
|
);
|
|
98430
98505
|
}
|
|
@@ -98586,7 +98661,7 @@ function transformES2015(context) {
|
|
|
98586
98661
|
void 0,
|
|
98587
98662
|
/*type*/
|
|
98588
98663
|
void 0,
|
|
98589
|
-
visitNode(
|
|
98664
|
+
Debug.checkDefined(visitNode(
|
|
98590
98665
|
factory2.createBlock(
|
|
98591
98666
|
statements,
|
|
98592
98667
|
/*multiLine*/
|
|
@@ -98594,7 +98669,7 @@ function transformES2015(context) {
|
|
|
98594
98669
|
),
|
|
98595
98670
|
visitor,
|
|
98596
98671
|
isBlock
|
|
98597
|
-
)
|
|
98672
|
+
))
|
|
98598
98673
|
),
|
|
98599
98674
|
emitFlags
|
|
98600
98675
|
)
|
|
@@ -98617,7 +98692,7 @@ function transformES2015(context) {
|
|
|
98617
98692
|
if (node.incrementor) {
|
|
98618
98693
|
statements.push(factory2.createIfStatement(
|
|
98619
98694
|
currentState.conditionVariable,
|
|
98620
|
-
factory2.createExpressionStatement(visitNode(node.incrementor, visitor, isExpression)),
|
|
98695
|
+
factory2.createExpressionStatement(Debug.checkDefined(visitNode(node.incrementor, visitor, isExpression))),
|
|
98621
98696
|
factory2.createExpressionStatement(factory2.createAssignment(currentState.conditionVariable, factory2.createTrue()))
|
|
98622
98697
|
));
|
|
98623
98698
|
} else {
|
|
@@ -98628,11 +98703,12 @@ function transformES2015(context) {
|
|
|
98628
98703
|
}
|
|
98629
98704
|
if (shouldConvertConditionOfForStatement(node)) {
|
|
98630
98705
|
statements.push(factory2.createIfStatement(
|
|
98631
|
-
factory2.createPrefixUnaryExpression(53 /* ExclamationToken */, visitNode(node.condition, visitor, isExpression)),
|
|
98632
|
-
visitNode(factory2.createBreakStatement(), visitor, isStatement)
|
|
98706
|
+
factory2.createPrefixUnaryExpression(53 /* ExclamationToken */, Debug.checkDefined(visitNode(node.condition, visitor, isExpression))),
|
|
98707
|
+
Debug.checkDefined(visitNode(factory2.createBreakStatement(), visitor, isStatement))
|
|
98633
98708
|
));
|
|
98634
98709
|
}
|
|
98635
98710
|
}
|
|
98711
|
+
Debug.assert(statement);
|
|
98636
98712
|
if (isBlock(statement)) {
|
|
98637
98713
|
addRange(statements, statement.statements);
|
|
98638
98714
|
} else {
|
|
@@ -98900,9 +98976,9 @@ function transformES2015(context) {
|
|
|
98900
98976
|
createMemberAccessForPropertyName(
|
|
98901
98977
|
factory2,
|
|
98902
98978
|
receiver,
|
|
98903
|
-
visitNode(property.name, visitor, isPropertyName)
|
|
98979
|
+
Debug.checkDefined(visitNode(property.name, visitor, isPropertyName))
|
|
98904
98980
|
),
|
|
98905
|
-
visitNode(property.initializer, visitor, isExpression)
|
|
98981
|
+
Debug.checkDefined(visitNode(property.initializer, visitor, isExpression))
|
|
98906
98982
|
);
|
|
98907
98983
|
setTextRange(expression, property);
|
|
98908
98984
|
if (startsOnNewLine) {
|
|
@@ -98915,7 +98991,7 @@ function transformES2015(context) {
|
|
|
98915
98991
|
createMemberAccessForPropertyName(
|
|
98916
98992
|
factory2,
|
|
98917
98993
|
receiver,
|
|
98918
|
-
visitNode(property.name, visitor, isPropertyName)
|
|
98994
|
+
Debug.checkDefined(visitNode(property.name, visitor, isPropertyName))
|
|
98919
98995
|
),
|
|
98920
98996
|
factory2.cloneNode(property.name)
|
|
98921
98997
|
);
|
|
@@ -98930,7 +99006,7 @@ function transformES2015(context) {
|
|
|
98930
99006
|
createMemberAccessForPropertyName(
|
|
98931
99007
|
factory2,
|
|
98932
99008
|
receiver,
|
|
98933
|
-
visitNode(method.name, visitor, isPropertyName)
|
|
99009
|
+
Debug.checkDefined(visitNode(method.name, visitor, isPropertyName))
|
|
98934
99010
|
),
|
|
98935
99011
|
transformFunctionLikeToExpression(
|
|
98936
99012
|
method,
|
|
@@ -99064,7 +99140,7 @@ function transformES2015(context) {
|
|
|
99064
99140
|
}
|
|
99065
99141
|
return factory2.updateCallExpression(
|
|
99066
99142
|
node,
|
|
99067
|
-
visitNode(node.expression, callExpressionVisitor, isExpression),
|
|
99143
|
+
Debug.checkDefined(visitNode(node.expression, callExpressionVisitor, isExpression)),
|
|
99068
99144
|
/*typeArguments*/
|
|
99069
99145
|
void 0,
|
|
99070
99146
|
visitNodes2(node.arguments, visitor, isExpression)
|
|
@@ -99176,8 +99252,8 @@ function transformES2015(context) {
|
|
|
99176
99252
|
let resultingCall;
|
|
99177
99253
|
if (node.transformFlags & 32768 /* ContainsRestOrSpread */) {
|
|
99178
99254
|
resultingCall = factory2.createFunctionApplyCall(
|
|
99179
|
-
visitNode(target, callExpressionVisitor, isExpression),
|
|
99180
|
-
node.expression.kind === 106 /* SuperKeyword */ ? thisArg : visitNode(thisArg, visitor, isExpression),
|
|
99255
|
+
Debug.checkDefined(visitNode(target, callExpressionVisitor, isExpression)),
|
|
99256
|
+
node.expression.kind === 106 /* SuperKeyword */ ? thisArg : Debug.checkDefined(visitNode(thisArg, visitor, isExpression)),
|
|
99181
99257
|
transformAndSpreadElements(
|
|
99182
99258
|
node.arguments,
|
|
99183
99259
|
/*isArgumentList*/
|
|
@@ -99191,8 +99267,8 @@ function transformES2015(context) {
|
|
|
99191
99267
|
} else {
|
|
99192
99268
|
resultingCall = setTextRange(
|
|
99193
99269
|
factory2.createFunctionCallCall(
|
|
99194
|
-
visitNode(target, callExpressionVisitor, isExpression),
|
|
99195
|
-
node.expression.kind === 106 /* SuperKeyword */ ? thisArg : visitNode(thisArg, visitor, isExpression),
|
|
99270
|
+
Debug.checkDefined(visitNode(target, callExpressionVisitor, isExpression)),
|
|
99271
|
+
node.expression.kind === 106 /* SuperKeyword */ ? thisArg : Debug.checkDefined(visitNode(thisArg, visitor, isExpression)),
|
|
99196
99272
|
visitNodes2(node.arguments, visitor, isExpression)
|
|
99197
99273
|
),
|
|
99198
99274
|
node
|
|
@@ -99214,7 +99290,7 @@ function transformES2015(context) {
|
|
|
99214
99290
|
const { target, thisArg } = factory2.createCallBinding(factory2.createPropertyAccessExpression(node.expression, "bind"), hoistVariableDeclaration);
|
|
99215
99291
|
return factory2.createNewExpression(
|
|
99216
99292
|
factory2.createFunctionApplyCall(
|
|
99217
|
-
visitNode(target, visitor, isExpression),
|
|
99293
|
+
Debug.checkDefined(visitNode(target, visitor, isExpression)),
|
|
99218
99294
|
thisArg,
|
|
99219
99295
|
transformAndSpreadElements(
|
|
99220
99296
|
factory2.createNodeArray([factory2.createVoidZero(), ...node.arguments]),
|
|
@@ -99271,7 +99347,9 @@ function transformES2015(context) {
|
|
|
99271
99347
|
return map(chunk, visitExpressionOfSpread);
|
|
99272
99348
|
}
|
|
99273
99349
|
function visitExpressionOfSpread(node) {
|
|
99350
|
+
Debug.assertNode(node, isSpreadElement);
|
|
99274
99351
|
let expression = visitNode(node.expression, visitor, isExpression);
|
|
99352
|
+
Debug.assert(expression);
|
|
99275
99353
|
const isCallToReadHelper = isCallToHelper(expression, "___read");
|
|
99276
99354
|
let kind = isCallToReadHelper || isPackedArrayLiteral(expression) ? 2 /* PackedSpread */ : 1 /* UnpackedSpread */;
|
|
99277
99355
|
if (compilerOptions.downlevelIteration && kind === 1 /* UnpackedSpread */ && !isArrayLiteralExpression(expression) && !isCallToReadHelper) {
|
|
@@ -99322,7 +99400,7 @@ function transformES2015(context) {
|
|
|
99322
99400
|
function visitTemplateExpression(node) {
|
|
99323
99401
|
let expression = factory2.createStringLiteral(node.head.text);
|
|
99324
99402
|
for (const span of node.templateSpans) {
|
|
99325
|
-
const args = [visitNode(span.expression, visitor, isExpression)];
|
|
99403
|
+
const args = [Debug.checkDefined(visitNode(span.expression, visitor, isExpression))];
|
|
99326
99404
|
if (span.literal.text.length > 0) {
|
|
99327
99405
|
args.push(factory2.createStringLiteral(span.literal.text));
|
|
99328
99406
|
}
|
|
@@ -99888,19 +99966,19 @@ function transformGenerators(context) {
|
|
|
99888
99966
|
case 208 /* PropertyAccessExpression */:
|
|
99889
99967
|
target = factory2.updatePropertyAccessExpression(
|
|
99890
99968
|
left,
|
|
99891
|
-
cacheExpression(visitNode(left.expression, visitor, isLeftHandSideExpression)),
|
|
99969
|
+
cacheExpression(Debug.checkDefined(visitNode(left.expression, visitor, isLeftHandSideExpression))),
|
|
99892
99970
|
left.name
|
|
99893
99971
|
);
|
|
99894
99972
|
break;
|
|
99895
99973
|
case 209 /* ElementAccessExpression */:
|
|
99896
99974
|
target = factory2.updateElementAccessExpression(
|
|
99897
99975
|
left,
|
|
99898
|
-
cacheExpression(visitNode(left.expression, visitor, isLeftHandSideExpression)),
|
|
99899
|
-
cacheExpression(visitNode(left.argumentExpression, visitor, isExpression))
|
|
99976
|
+
cacheExpression(Debug.checkDefined(visitNode(left.expression, visitor, isLeftHandSideExpression))),
|
|
99977
|
+
cacheExpression(Debug.checkDefined(visitNode(left.argumentExpression, visitor, isExpression)))
|
|
99900
99978
|
);
|
|
99901
99979
|
break;
|
|
99902
99980
|
default:
|
|
99903
|
-
target = visitNode(left, visitor, isExpression);
|
|
99981
|
+
target = Debug.checkDefined(visitNode(left, visitor, isExpression));
|
|
99904
99982
|
break;
|
|
99905
99983
|
}
|
|
99906
99984
|
const operator = node.operatorToken.kind;
|
|
@@ -99912,7 +99990,7 @@ function transformGenerators(context) {
|
|
|
99912
99990
|
factory2.createBinaryExpression(
|
|
99913
99991
|
cacheExpression(target),
|
|
99914
99992
|
getNonAssignmentOperatorForCompoundAssignment(operator),
|
|
99915
|
-
visitNode(right, visitor, isExpression)
|
|
99993
|
+
Debug.checkDefined(visitNode(right, visitor, isExpression))
|
|
99916
99994
|
),
|
|
99917
99995
|
node
|
|
99918
99996
|
)
|
|
@@ -99920,7 +99998,7 @@ function transformGenerators(context) {
|
|
|
99920
99998
|
node
|
|
99921
99999
|
);
|
|
99922
100000
|
} else {
|
|
99923
|
-
return factory2.updateBinaryExpression(node, target, node.operatorToken, visitNode(right, visitor, isExpression));
|
|
100001
|
+
return factory2.updateBinaryExpression(node, target, node.operatorToken, Debug.checkDefined(visitNode(right, visitor, isExpression)));
|
|
99924
100002
|
}
|
|
99925
100003
|
}
|
|
99926
100004
|
return visitEachChild(node, visitor, context);
|
|
@@ -99934,9 +100012,9 @@ function transformGenerators(context) {
|
|
|
99934
100012
|
}
|
|
99935
100013
|
return factory2.updateBinaryExpression(
|
|
99936
100014
|
node,
|
|
99937
|
-
cacheExpression(visitNode(node.left, visitor, isExpression)),
|
|
100015
|
+
cacheExpression(Debug.checkDefined(visitNode(node.left, visitor, isExpression))),
|
|
99938
100016
|
node.operatorToken,
|
|
99939
|
-
visitNode(node.right, visitor, isExpression)
|
|
100017
|
+
Debug.checkDefined(visitNode(node.right, visitor, isExpression))
|
|
99940
100018
|
);
|
|
99941
100019
|
}
|
|
99942
100020
|
return visitEachChild(node, visitor, context);
|
|
@@ -99955,7 +100033,7 @@ function transformGenerators(context) {
|
|
|
99955
100033
|
emitWorker(1 /* Statement */, [factory2.createExpressionStatement(factory2.inlineExpressions(pendingExpressions))]);
|
|
99956
100034
|
pendingExpressions = [];
|
|
99957
100035
|
}
|
|
99958
|
-
pendingExpressions.push(visitNode(node2, visitor, isExpression));
|
|
100036
|
+
pendingExpressions.push(Debug.checkDefined(visitNode(node2, visitor, isExpression)));
|
|
99959
100037
|
}
|
|
99960
100038
|
}
|
|
99961
100039
|
}
|
|
@@ -99969,7 +100047,7 @@ function transformGenerators(context) {
|
|
|
99969
100047
|
emitWorker(1 /* Statement */, [factory2.createExpressionStatement(factory2.inlineExpressions(pendingExpressions))]);
|
|
99970
100048
|
pendingExpressions = [];
|
|
99971
100049
|
}
|
|
99972
|
-
pendingExpressions.push(visitNode(elem, visitor, isExpression));
|
|
100050
|
+
pendingExpressions.push(Debug.checkDefined(visitNode(elem, visitor, isExpression)));
|
|
99973
100051
|
}
|
|
99974
100052
|
}
|
|
99975
100053
|
return factory2.inlineExpressions(pendingExpressions);
|
|
@@ -99979,7 +100057,7 @@ function transformGenerators(context) {
|
|
|
99979
100057
|
const resultLocal = declareLocal();
|
|
99980
100058
|
emitAssignment(
|
|
99981
100059
|
resultLocal,
|
|
99982
|
-
visitNode(node.left, visitor, isExpression),
|
|
100060
|
+
Debug.checkDefined(visitNode(node.left, visitor, isExpression)),
|
|
99983
100061
|
/*location*/
|
|
99984
100062
|
node.left
|
|
99985
100063
|
);
|
|
@@ -100000,7 +100078,7 @@ function transformGenerators(context) {
|
|
|
100000
100078
|
}
|
|
100001
100079
|
emitAssignment(
|
|
100002
100080
|
resultLocal,
|
|
100003
|
-
visitNode(node.right, visitor, isExpression),
|
|
100081
|
+
Debug.checkDefined(visitNode(node.right, visitor, isExpression)),
|
|
100004
100082
|
/*location*/
|
|
100005
100083
|
node.right
|
|
100006
100084
|
);
|
|
@@ -100014,13 +100092,13 @@ function transformGenerators(context) {
|
|
|
100014
100092
|
const resultLocal = declareLocal();
|
|
100015
100093
|
emitBreakWhenFalse(
|
|
100016
100094
|
whenFalseLabel,
|
|
100017
|
-
visitNode(node.condition, visitor, isExpression),
|
|
100095
|
+
Debug.checkDefined(visitNode(node.condition, visitor, isExpression)),
|
|
100018
100096
|
/*location*/
|
|
100019
100097
|
node.condition
|
|
100020
100098
|
);
|
|
100021
100099
|
emitAssignment(
|
|
100022
100100
|
resultLocal,
|
|
100023
|
-
visitNode(node.whenTrue, visitor, isExpression),
|
|
100101
|
+
Debug.checkDefined(visitNode(node.whenTrue, visitor, isExpression)),
|
|
100024
100102
|
/*location*/
|
|
100025
100103
|
node.whenTrue
|
|
100026
100104
|
);
|
|
@@ -100028,7 +100106,7 @@ function transformGenerators(context) {
|
|
|
100028
100106
|
markLabel(whenFalseLabel);
|
|
100029
100107
|
emitAssignment(
|
|
100030
100108
|
resultLocal,
|
|
100031
|
-
visitNode(node.whenFalse, visitor, isExpression),
|
|
100109
|
+
Debug.checkDefined(visitNode(node.whenFalse, visitor, isExpression)),
|
|
100032
100110
|
/*location*/
|
|
100033
100111
|
node.whenFalse
|
|
100034
100112
|
);
|
|
@@ -100108,7 +100186,7 @@ function transformGenerators(context) {
|
|
|
100108
100186
|
leadingElement = void 0;
|
|
100109
100187
|
expressions2 = [];
|
|
100110
100188
|
}
|
|
100111
|
-
expressions2.push(visitNode(element, visitor, isExpression));
|
|
100189
|
+
expressions2.push(Debug.checkDefined(visitNode(element, visitor, isExpression)));
|
|
100112
100190
|
return expressions2;
|
|
100113
100191
|
}
|
|
100114
100192
|
}
|
|
@@ -100147,8 +100225,8 @@ function transformGenerators(context) {
|
|
|
100147
100225
|
if (containsYield(node.argumentExpression)) {
|
|
100148
100226
|
return factory2.updateElementAccessExpression(
|
|
100149
100227
|
node,
|
|
100150
|
-
cacheExpression(visitNode(node.expression, visitor, isLeftHandSideExpression)),
|
|
100151
|
-
visitNode(node.argumentExpression, visitor, isExpression)
|
|
100228
|
+
cacheExpression(Debug.checkDefined(visitNode(node.expression, visitor, isLeftHandSideExpression))),
|
|
100229
|
+
Debug.checkDefined(visitNode(node.argumentExpression, visitor, isExpression))
|
|
100152
100230
|
);
|
|
100153
100231
|
}
|
|
100154
100232
|
return visitEachChild(node, visitor, context);
|
|
@@ -100165,7 +100243,7 @@ function transformGenerators(context) {
|
|
|
100165
100243
|
return setOriginalNode(
|
|
100166
100244
|
setTextRange(
|
|
100167
100245
|
factory2.createFunctionApplyCall(
|
|
100168
|
-
cacheExpression(visitNode(target, visitor, isLeftHandSideExpression)),
|
|
100246
|
+
cacheExpression(Debug.checkDefined(visitNode(target, visitor, isLeftHandSideExpression))),
|
|
100169
100247
|
thisArg,
|
|
100170
100248
|
visitElements(node.arguments)
|
|
100171
100249
|
),
|
|
@@ -100183,7 +100261,7 @@ function transformGenerators(context) {
|
|
|
100183
100261
|
setTextRange(
|
|
100184
100262
|
factory2.createNewExpression(
|
|
100185
100263
|
factory2.createFunctionApplyCall(
|
|
100186
|
-
cacheExpression(visitNode(target, visitor, isExpression)),
|
|
100264
|
+
cacheExpression(Debug.checkDefined(visitNode(target, visitor, isExpression))),
|
|
100187
100265
|
thisArg,
|
|
100188
100266
|
visitElements(
|
|
100189
100267
|
node.arguments,
|
|
@@ -100299,7 +100377,7 @@ function transformGenerators(context) {
|
|
|
100299
100377
|
return setSourceMapRange(
|
|
100300
100378
|
factory2.createAssignment(
|
|
100301
100379
|
setSourceMapRange(factory2.cloneNode(node.name), node.name),
|
|
100302
|
-
visitNode(node.initializer, visitor, isExpression)
|
|
100380
|
+
Debug.checkDefined(visitNode(node.initializer, visitor, isExpression))
|
|
100303
100381
|
),
|
|
100304
100382
|
node
|
|
100305
100383
|
);
|
|
@@ -100311,7 +100389,7 @@ function transformGenerators(context) {
|
|
|
100311
100389
|
const elseLabel = node.elseStatement ? defineLabel() : void 0;
|
|
100312
100390
|
emitBreakWhenFalse(
|
|
100313
100391
|
node.elseStatement ? elseLabel : endLabel,
|
|
100314
|
-
visitNode(node.expression, visitor, isExpression),
|
|
100392
|
+
Debug.checkDefined(visitNode(node.expression, visitor, isExpression)),
|
|
100315
100393
|
/*location*/
|
|
100316
100394
|
node.expression
|
|
100317
100395
|
);
|
|
@@ -100340,7 +100418,7 @@ function transformGenerators(context) {
|
|
|
100340
100418
|
markLabel(loopLabel);
|
|
100341
100419
|
transformAndEmitEmbeddedStatement(node.statement);
|
|
100342
100420
|
markLabel(conditionLabel);
|
|
100343
|
-
emitBreakWhenTrue(loopLabel, visitNode(node.expression, visitor, isExpression));
|
|
100421
|
+
emitBreakWhenTrue(loopLabel, Debug.checkDefined(visitNode(node.expression, visitor, isExpression)));
|
|
100344
100422
|
endLoopBlock();
|
|
100345
100423
|
} else {
|
|
100346
100424
|
emitStatement(visitNode(node, visitor, isStatement));
|
|
@@ -100361,7 +100439,7 @@ function transformGenerators(context) {
|
|
|
100361
100439
|
const loopLabel = defineLabel();
|
|
100362
100440
|
const endLabel = beginLoopBlock(loopLabel);
|
|
100363
100441
|
markLabel(loopLabel);
|
|
100364
|
-
emitBreakWhenFalse(endLabel, visitNode(node.expression, visitor, isExpression));
|
|
100442
|
+
emitBreakWhenFalse(endLabel, Debug.checkDefined(visitNode(node.expression, visitor, isExpression)));
|
|
100365
100443
|
transformAndEmitEmbeddedStatement(node.statement);
|
|
100366
100444
|
emitBreak(loopLabel);
|
|
100367
100445
|
endLoopBlock();
|
|
@@ -100392,7 +100470,7 @@ function transformGenerators(context) {
|
|
|
100392
100470
|
emitStatement(
|
|
100393
100471
|
setTextRange(
|
|
100394
100472
|
factory2.createExpressionStatement(
|
|
100395
|
-
visitNode(initializer, visitor, isExpression)
|
|
100473
|
+
Debug.checkDefined(visitNode(initializer, visitor, isExpression))
|
|
100396
100474
|
),
|
|
100397
100475
|
initializer
|
|
100398
100476
|
)
|
|
@@ -100401,7 +100479,7 @@ function transformGenerators(context) {
|
|
|
100401
100479
|
}
|
|
100402
100480
|
markLabel(conditionLabel);
|
|
100403
100481
|
if (node.condition) {
|
|
100404
|
-
emitBreakWhenFalse(endLabel, visitNode(node.condition, visitor, isExpression));
|
|
100482
|
+
emitBreakWhenFalse(endLabel, Debug.checkDefined(visitNode(node.condition, visitor, isExpression)));
|
|
100405
100483
|
}
|
|
100406
100484
|
transformAndEmitEmbeddedStatement(node.statement);
|
|
100407
100485
|
markLabel(incrementLabel);
|
|
@@ -100409,7 +100487,7 @@ function transformGenerators(context) {
|
|
|
100409
100487
|
emitStatement(
|
|
100410
100488
|
setTextRange(
|
|
100411
100489
|
factory2.createExpressionStatement(
|
|
100412
|
-
visitNode(node.incrementor, visitor, isExpression)
|
|
100490
|
+
Debug.checkDefined(visitNode(node.incrementor, visitor, isExpression))
|
|
100413
100491
|
),
|
|
100414
100492
|
node.incrementor
|
|
100415
100493
|
)
|
|
@@ -100454,7 +100532,7 @@ function transformGenerators(context) {
|
|
|
100454
100532
|
const keysIndex = factory2.createLoopVariable();
|
|
100455
100533
|
const initializer = node.initializer;
|
|
100456
100534
|
hoistVariableDeclaration(keysIndex);
|
|
100457
|
-
emitAssignment(obj, visitNode(node.expression, visitor, isExpression));
|
|
100535
|
+
emitAssignment(obj, Debug.checkDefined(visitNode(node.expression, visitor, isExpression)));
|
|
100458
100536
|
emitAssignment(keysArray, factory2.createArrayLiteralExpression());
|
|
100459
100537
|
emitStatement(
|
|
100460
100538
|
factory2.createForInStatement(
|
|
@@ -100485,7 +100563,7 @@ function transformGenerators(context) {
|
|
|
100485
100563
|
}
|
|
100486
100564
|
variable = factory2.cloneNode(initializer.declarations[0].name);
|
|
100487
100565
|
} else {
|
|
100488
|
-
variable = visitNode(initializer, visitor, isExpression);
|
|
100566
|
+
variable = Debug.checkDefined(visitNode(initializer, visitor, isExpression));
|
|
100489
100567
|
Debug.assert(isLeftHandSideExpression(variable));
|
|
100490
100568
|
}
|
|
100491
100569
|
emitAssignment(variable, key);
|
|
@@ -100510,8 +100588,8 @@ function transformGenerators(context) {
|
|
|
100510
100588
|
node = factory2.updateForInStatement(
|
|
100511
100589
|
node,
|
|
100512
100590
|
initializer.declarations[0].name,
|
|
100513
|
-
visitNode(node.expression, visitor, isExpression),
|
|
100514
|
-
visitNode(node.statement, visitor, isStatement, factory2.liftToBlock)
|
|
100591
|
+
Debug.checkDefined(visitNode(node.expression, visitor, isExpression)),
|
|
100592
|
+
Debug.checkDefined(visitNode(node.statement, visitor, isStatement, factory2.liftToBlock))
|
|
100515
100593
|
);
|
|
100516
100594
|
} else {
|
|
100517
100595
|
node = visitEachChild(node, visitor, context);
|
|
@@ -100587,7 +100665,7 @@ function transformGenerators(context) {
|
|
|
100587
100665
|
}
|
|
100588
100666
|
function transformAndEmitWithStatement(node) {
|
|
100589
100667
|
if (containsYield(node)) {
|
|
100590
|
-
beginWithBlock(cacheExpression(visitNode(node.expression, visitor, isExpression)));
|
|
100668
|
+
beginWithBlock(cacheExpression(Debug.checkDefined(visitNode(node.expression, visitor, isExpression))));
|
|
100591
100669
|
transformAndEmitEmbeddedStatement(node.statement);
|
|
100592
100670
|
endWithBlock();
|
|
100593
100671
|
} else {
|
|
@@ -100599,7 +100677,7 @@ function transformGenerators(context) {
|
|
|
100599
100677
|
const caseBlock = node.caseBlock;
|
|
100600
100678
|
const numClauses = caseBlock.clauses.length;
|
|
100601
100679
|
const endLabel = beginSwitchBlock();
|
|
100602
|
-
const expression = cacheExpression(visitNode(node.expression, visitor, isExpression));
|
|
100680
|
+
const expression = cacheExpression(Debug.checkDefined(visitNode(node.expression, visitor, isExpression)));
|
|
100603
100681
|
const clauseLabels = [];
|
|
100604
100682
|
let defaultClauseIndex = -1;
|
|
100605
100683
|
for (let i = 0; i < numClauses; i++) {
|
|
@@ -100621,7 +100699,7 @@ function transformGenerators(context) {
|
|
|
100621
100699
|
}
|
|
100622
100700
|
pendingClauses.push(
|
|
100623
100701
|
factory2.createCaseClause(
|
|
100624
|
-
visitNode(clause.expression, visitor, isExpression),
|
|
100702
|
+
Debug.checkDefined(visitNode(clause.expression, visitor, isExpression)),
|
|
100625
100703
|
[
|
|
100626
100704
|
createInlineBreak(
|
|
100627
100705
|
clauseLabels[i],
|
|
@@ -100691,7 +100769,7 @@ function transformGenerators(context) {
|
|
|
100691
100769
|
function transformAndEmitThrowStatement(node) {
|
|
100692
100770
|
var _a2;
|
|
100693
100771
|
emitThrow(
|
|
100694
|
-
visitNode((_a2 = node.expression) != null ? _a2 : factory2.createVoidZero(), visitor, isExpression),
|
|
100772
|
+
Debug.checkDefined(visitNode((_a2 = node.expression) != null ? _a2 : factory2.createVoidZero(), visitor, isExpression)),
|
|
100695
100773
|
/*location*/
|
|
100696
100774
|
node
|
|
100697
100775
|
);
|
|
@@ -101975,7 +102053,7 @@ function transformModule(context) {
|
|
|
101975
102053
|
}
|
|
101976
102054
|
function addExportEqualsIfNeeded(statements, emitAsReturn) {
|
|
101977
102055
|
if (currentModuleInfo.exportEquals) {
|
|
101978
|
-
const expressionResult = visitNode(currentModuleInfo.exportEquals.expression, visitor);
|
|
102056
|
+
const expressionResult = visitNode(currentModuleInfo.exportEquals.expression, visitor, isExpression);
|
|
101979
102057
|
if (expressionResult) {
|
|
101980
102058
|
if (emitAsReturn) {
|
|
101981
102059
|
const statement = factory2.createReturnStatement(expressionResult);
|
|
@@ -102170,7 +102248,7 @@ function transformModule(context) {
|
|
|
102170
102248
|
}
|
|
102171
102249
|
function visitImportCallExpression(node) {
|
|
102172
102250
|
const externalModuleName = getExternalModuleNameLiteral(factory2, node, currentSourceFile, host, resolver, compilerOptions);
|
|
102173
|
-
const firstArgument = visitNode(firstOrUndefined(node.arguments), visitor);
|
|
102251
|
+
const firstArgument = visitNode(firstOrUndefined(node.arguments), visitor, isExpression);
|
|
102174
102252
|
const argument = externalModuleName && (!firstArgument || !isStringLiteral(firstArgument) || firstArgument.text !== externalModuleName.text) ? externalModuleName : firstArgument;
|
|
102175
102253
|
const containsLexicalThis = !!(node.transformFlags & 16384 /* ContainsLexicalThis */);
|
|
102176
102254
|
switch (compilerOptions.module) {
|
|
@@ -102699,7 +102777,7 @@ function transformModule(context) {
|
|
|
102699
102777
|
deferredExports[id] = appendExportStatement(
|
|
102700
102778
|
deferredExports[id],
|
|
102701
102779
|
factory2.createIdentifier("default"),
|
|
102702
|
-
visitNode(node.expression, visitor),
|
|
102780
|
+
visitNode(node.expression, visitor, isExpression),
|
|
102703
102781
|
/*location*/
|
|
102704
102782
|
node,
|
|
102705
102783
|
/*allowComments*/
|
|
@@ -102709,7 +102787,7 @@ function transformModule(context) {
|
|
|
102709
102787
|
statements = appendExportStatement(
|
|
102710
102788
|
statements,
|
|
102711
102789
|
factory2.createIdentifier("default"),
|
|
102712
|
-
visitNode(node.expression, visitor),
|
|
102790
|
+
visitNode(node.expression, visitor, isExpression),
|
|
102713
102791
|
/*location*/
|
|
102714
102792
|
node,
|
|
102715
102793
|
/*allowComments*/
|
|
@@ -102737,7 +102815,7 @@ function transformModule(context) {
|
|
|
102737
102815
|
),
|
|
102738
102816
|
/*typeParameters*/
|
|
102739
102817
|
void 0,
|
|
102740
|
-
visitNodes2(node.parameters, visitor),
|
|
102818
|
+
visitNodes2(node.parameters, visitor, isParameter),
|
|
102741
102819
|
/*type*/
|
|
102742
102820
|
void 0,
|
|
102743
102821
|
visitEachChild(node.body, visitor, context)
|
|
@@ -102778,8 +102856,8 @@ function transformModule(context) {
|
|
|
102778
102856
|
),
|
|
102779
102857
|
/*typeParameters*/
|
|
102780
102858
|
void 0,
|
|
102781
|
-
visitNodes2(node.heritageClauses, visitor),
|
|
102782
|
-
visitNodes2(node.members, visitor)
|
|
102859
|
+
visitNodes2(node.heritageClauses, visitor, isHeritageClause),
|
|
102860
|
+
visitNodes2(node.members, visitor, isClassElement)
|
|
102783
102861
|
),
|
|
102784
102862
|
node
|
|
102785
102863
|
),
|
|
@@ -102827,7 +102905,7 @@ function transformModule(context) {
|
|
|
102827
102905
|
variable.name,
|
|
102828
102906
|
variable.exclamationToken,
|
|
102829
102907
|
variable.type,
|
|
102830
|
-
visitNode(variable.initializer, visitor)
|
|
102908
|
+
visitNode(variable.initializer, visitor, isExpression)
|
|
102831
102909
|
);
|
|
102832
102910
|
variables = append(variables, updatedVariable);
|
|
102833
102911
|
expressions = append(expressions, expression);
|
|
@@ -102878,9 +102956,8 @@ function transformModule(context) {
|
|
|
102878
102956
|
function transformInitializedVariable(node) {
|
|
102879
102957
|
if (isBindingPattern(node.name)) {
|
|
102880
102958
|
return flattenDestructuringAssignment(
|
|
102881
|
-
visitNode(node, visitor),
|
|
102882
|
-
|
|
102883
|
-
void 0,
|
|
102959
|
+
visitNode(node, visitor, isInitializedVariable),
|
|
102960
|
+
visitor,
|
|
102884
102961
|
context,
|
|
102885
102962
|
0 /* All */,
|
|
102886
102963
|
/*needsValue*/
|
|
@@ -102897,7 +102974,7 @@ function transformModule(context) {
|
|
|
102897
102974
|
/*location*/
|
|
102898
102975
|
node.name
|
|
102899
102976
|
),
|
|
102900
|
-
node.initializer ? visitNode(node.initializer, visitor) : factory2.createVoidZero()
|
|
102977
|
+
node.initializer ? visitNode(node.initializer, visitor, isExpression) : factory2.createVoidZero()
|
|
102901
102978
|
);
|
|
102902
102979
|
}
|
|
102903
102980
|
}
|
|
@@ -103840,7 +103917,7 @@ function transformSystemModule(context) {
|
|
|
103840
103917
|
),
|
|
103841
103918
|
/*typeParameters*/
|
|
103842
103919
|
void 0,
|
|
103843
|
-
visitNodes2(node.parameters, visitor,
|
|
103920
|
+
visitNodes2(node.parameters, visitor, isParameter),
|
|
103844
103921
|
/*type*/
|
|
103845
103922
|
void 0,
|
|
103846
103923
|
visitNode(node.body, visitor, isBlock)
|
|
@@ -104214,7 +104291,7 @@ function transformSystemModule(context) {
|
|
|
104214
104291
|
}
|
|
104215
104292
|
return expressions ? factory2.inlineExpressions(expressions) : factory2.createOmittedExpression();
|
|
104216
104293
|
} else {
|
|
104217
|
-
return visitNode(node, discardedValueVisitor,
|
|
104294
|
+
return visitNode(node, discardedValueVisitor, isForInitializer);
|
|
104218
104295
|
}
|
|
104219
104296
|
}
|
|
104220
104297
|
function visitDoStatement(node) {
|
|
@@ -104235,21 +104312,21 @@ function transformSystemModule(context) {
|
|
|
104235
104312
|
return factory2.updateLabeledStatement(
|
|
104236
104313
|
node,
|
|
104237
104314
|
node.label,
|
|
104238
|
-
visitNode(node.statement, topLevelNestedVisitor, isStatement, factory2.liftToBlock)
|
|
104315
|
+
Debug.checkDefined(visitNode(node.statement, topLevelNestedVisitor, isStatement, factory2.liftToBlock))
|
|
104239
104316
|
);
|
|
104240
104317
|
}
|
|
104241
104318
|
function visitWithStatement(node) {
|
|
104242
104319
|
return factory2.updateWithStatement(
|
|
104243
104320
|
node,
|
|
104244
104321
|
visitNode(node.expression, visitor, isExpression),
|
|
104245
|
-
visitNode(node.statement, topLevelNestedVisitor, isStatement, factory2.liftToBlock)
|
|
104322
|
+
Debug.checkDefined(visitNode(node.statement, topLevelNestedVisitor, isStatement, factory2.liftToBlock))
|
|
104246
104323
|
);
|
|
104247
104324
|
}
|
|
104248
104325
|
function visitSwitchStatement(node) {
|
|
104249
104326
|
return factory2.updateSwitchStatement(
|
|
104250
104327
|
node,
|
|
104251
104328
|
visitNode(node.expression, visitor, isExpression),
|
|
104252
|
-
visitNode(node.caseBlock, topLevelNestedVisitor, isCaseBlock)
|
|
104329
|
+
Debug.checkDefined(visitNode(node.caseBlock, topLevelNestedVisitor, isCaseBlock))
|
|
104253
104330
|
);
|
|
104254
104331
|
}
|
|
104255
104332
|
function visitCaseBlock(node) {
|
|
@@ -104281,7 +104358,7 @@ function transformSystemModule(context) {
|
|
|
104281
104358
|
node = factory2.updateCatchClause(
|
|
104282
104359
|
node,
|
|
104283
104360
|
node.variableDeclaration,
|
|
104284
|
-
visitNode(node.block, topLevelNestedVisitor, isBlock)
|
|
104361
|
+
Debug.checkDefined(visitNode(node.block, topLevelNestedVisitor, isBlock))
|
|
104285
104362
|
);
|
|
104286
104363
|
enclosingBlockScopedContainer = savedEnclosingBlockScopedContainer;
|
|
104287
104364
|
return node;
|
|
@@ -104351,7 +104428,7 @@ function transformSystemModule(context) {
|
|
|
104351
104428
|
}
|
|
104352
104429
|
function visitImportCallExpression(node) {
|
|
104353
104430
|
const externalModuleName = getExternalModuleNameLiteral(factory2, node, currentSourceFile, host, resolver, compilerOptions);
|
|
104354
|
-
const firstArgument = visitNode(firstOrUndefined(node.arguments), visitor);
|
|
104431
|
+
const firstArgument = visitNode(firstOrUndefined(node.arguments), visitor, isExpression);
|
|
104355
104432
|
const argument = externalModuleName && (!firstArgument || !isStringLiteral(firstArgument) || firstArgument.text !== externalModuleName.text) ? externalModuleName : firstArgument;
|
|
104356
104433
|
return factory2.createCallExpression(
|
|
104357
104434
|
factory2.createPropertyAccessExpression(
|
|
@@ -105472,7 +105549,7 @@ function transformDeclarations(context) {
|
|
|
105472
105549
|
sourceFile,
|
|
105473
105550
|
/*bundled*/
|
|
105474
105551
|
true
|
|
105475
|
-
)) : visitNodes2(sourceFile.statements, visitDeclarationStatements);
|
|
105552
|
+
)) : visitNodes2(sourceFile.statements, visitDeclarationStatements, isStatement);
|
|
105476
105553
|
const newFile = factory2.updateSourceFile(
|
|
105477
105554
|
sourceFile,
|
|
105478
105555
|
[factory2.createModuleDeclaration(
|
|
@@ -105494,7 +105571,7 @@ function transformDeclarations(context) {
|
|
|
105494
105571
|
return newFile;
|
|
105495
105572
|
}
|
|
105496
105573
|
needsDeclare = true;
|
|
105497
|
-
const updated2 = isSourceFileJS(sourceFile) ? factory2.createNodeArray(transformDeclarationsForJS(sourceFile)) : visitNodes2(sourceFile.statements, visitDeclarationStatements);
|
|
105574
|
+
const updated2 = isSourceFileJS(sourceFile) ? factory2.createNodeArray(transformDeclarationsForJS(sourceFile)) : visitNodes2(sourceFile.statements, visitDeclarationStatements, isStatement);
|
|
105498
105575
|
return factory2.updateSourceFile(
|
|
105499
105576
|
sourceFile,
|
|
105500
105577
|
transformAndReplaceLatePaintedStatements(updated2),
|
|
@@ -105563,7 +105640,7 @@ function transformDeclarations(context) {
|
|
|
105563
105640
|
refs.forEach(referenceVisitor);
|
|
105564
105641
|
emittedImports = filter(combinedStatements, isAnyImportSyntax);
|
|
105565
105642
|
} else {
|
|
105566
|
-
const statements = visitNodes2(node.statements, visitDeclarationStatements);
|
|
105643
|
+
const statements = visitNodes2(node.statements, visitDeclarationStatements, isStatement);
|
|
105567
105644
|
combinedStatements = setTextRange(factory2.createNodeArray(transformAndReplaceLatePaintedStatements(statements)), node.statements);
|
|
105568
105645
|
refs.forEach(referenceVisitor);
|
|
105569
105646
|
emittedImports = filter(combinedStatements, isAnyImportSyntax);
|
|
@@ -105680,9 +105757,9 @@ function transformDeclarations(context) {
|
|
|
105680
105757
|
return name;
|
|
105681
105758
|
} else {
|
|
105682
105759
|
if (name.kind === 204 /* ArrayBindingPattern */) {
|
|
105683
|
-
return factory2.updateArrayBindingPattern(name, visitNodes2(name.elements, visitBindingElement));
|
|
105760
|
+
return factory2.updateArrayBindingPattern(name, visitNodes2(name.elements, visitBindingElement, isArrayBindingElement));
|
|
105684
105761
|
} else {
|
|
105685
|
-
return factory2.updateObjectBindingPattern(name, visitNodes2(name.elements, visitBindingElement));
|
|
105762
|
+
return factory2.updateObjectBindingPattern(name, visitNodes2(name.elements, visitBindingElement, isBindingElement));
|
|
105686
105763
|
}
|
|
105687
105764
|
}
|
|
105688
105765
|
function visitBindingElement(elem) {
|
|
@@ -105752,10 +105829,10 @@ function transformDeclarations(context) {
|
|
|
105752
105829
|
}
|
|
105753
105830
|
const shouldUseResolverType = node.kind === 166 /* Parameter */ && (resolver.isRequiredInitializedParameter(node) || resolver.isOptionalUninitializedParameterProperty(node));
|
|
105754
105831
|
if (type && !shouldUseResolverType) {
|
|
105755
|
-
return visitNode(type, visitDeclarationSubtree);
|
|
105832
|
+
return visitNode(type, visitDeclarationSubtree, isTypeNode);
|
|
105756
105833
|
}
|
|
105757
105834
|
if (!getParseTreeNode(node)) {
|
|
105758
|
-
return type ? visitNode(type, visitDeclarationSubtree) : factory2.createKeywordTypeNode(131 /* AnyKeyword */);
|
|
105835
|
+
return type ? visitNode(type, visitDeclarationSubtree, isTypeNode) : factory2.createKeywordTypeNode(131 /* AnyKeyword */);
|
|
105759
105836
|
}
|
|
105760
105837
|
if (node.kind === 175 /* SetAccessor */) {
|
|
105761
105838
|
return factory2.createKeywordTypeNode(131 /* AnyKeyword */);
|
|
@@ -105869,7 +105946,7 @@ function transformDeclarations(context) {
|
|
|
105869
105946
|
return factory2.createNodeArray(newParams || emptyArray);
|
|
105870
105947
|
}
|
|
105871
105948
|
function ensureTypeParams(node, params) {
|
|
105872
|
-
return hasEffectiveModifier(node, 8 /* Private */) ? void 0 : visitNodes2(params, visitDeclarationSubtree);
|
|
105949
|
+
return hasEffectiveModifier(node, 8 /* Private */) ? void 0 : visitNodes2(params, visitDeclarationSubtree, isTypeParameterDeclaration);
|
|
105873
105950
|
}
|
|
105874
105951
|
function isEnclosingDeclaration(node) {
|
|
105875
105952
|
return isSourceFile(node) || isTypeAliasDeclaration(node) || isModuleDeclaration(node) || isClassDeclaration(node) || isInterfaceDeclaration(node) || isFunctionLike(node) || isIndexSignatureDeclaration(node) || isMappedTypeNode(node);
|
|
@@ -106004,7 +106081,7 @@ function transformDeclarations(context) {
|
|
|
106004
106081
|
needsDeclare = priorNeedsDeclare;
|
|
106005
106082
|
lateStatementReplacementMap.set(getOriginalNodeId(i), result);
|
|
106006
106083
|
}
|
|
106007
|
-
return visitNodes2(statements, visitLateVisibilityMarkedStatements);
|
|
106084
|
+
return visitNodes2(statements, visitLateVisibilityMarkedStatements, isStatement);
|
|
106008
106085
|
function visitLateVisibilityMarkedStatements(statement) {
|
|
106009
106086
|
if (isLateVisibilityPaintedStatement(statement)) {
|
|
106010
106087
|
const key = getOriginalNodeId(statement);
|
|
@@ -106218,7 +106295,7 @@ function transformDeclarations(context) {
|
|
|
106218
106295
|
input,
|
|
106219
106296
|
ensureModifiers(input),
|
|
106220
106297
|
updateParamsList(input, input.parameters),
|
|
106221
|
-
visitNode(input.type, visitDeclarationSubtree) || factory2.createKeywordTypeNode(131 /* AnyKeyword */)
|
|
106298
|
+
visitNode(input.type, visitDeclarationSubtree, isTypeNode) || factory2.createKeywordTypeNode(131 /* AnyKeyword */)
|
|
106222
106299
|
));
|
|
106223
106300
|
}
|
|
106224
106301
|
case 257 /* VariableDeclaration */: {
|
|
@@ -106251,20 +106328,24 @@ function transformDeclarations(context) {
|
|
|
106251
106328
|
return cleanup(visitEachChild(input, visitDeclarationSubtree, context));
|
|
106252
106329
|
}
|
|
106253
106330
|
case 191 /* ConditionalType */: {
|
|
106254
|
-
const checkType = visitNode(input.checkType, visitDeclarationSubtree);
|
|
106255
|
-
const extendsType = visitNode(input.extendsType, visitDeclarationSubtree);
|
|
106331
|
+
const checkType = visitNode(input.checkType, visitDeclarationSubtree, isTypeNode);
|
|
106332
|
+
const extendsType = visitNode(input.extendsType, visitDeclarationSubtree, isTypeNode);
|
|
106256
106333
|
const oldEnclosingDecl = enclosingDeclaration;
|
|
106257
106334
|
enclosingDeclaration = input.trueType;
|
|
106258
|
-
const trueType = visitNode(input.trueType, visitDeclarationSubtree);
|
|
106335
|
+
const trueType = visitNode(input.trueType, visitDeclarationSubtree, isTypeNode);
|
|
106259
106336
|
enclosingDeclaration = oldEnclosingDecl;
|
|
106260
|
-
const falseType = visitNode(input.falseType, visitDeclarationSubtree);
|
|
106337
|
+
const falseType = visitNode(input.falseType, visitDeclarationSubtree, isTypeNode);
|
|
106338
|
+
Debug.assert(checkType);
|
|
106339
|
+
Debug.assert(extendsType);
|
|
106340
|
+
Debug.assert(trueType);
|
|
106341
|
+
Debug.assert(falseType);
|
|
106261
106342
|
return cleanup(factory2.updateConditionalTypeNode(input, checkType, extendsType, trueType, falseType));
|
|
106262
106343
|
}
|
|
106263
106344
|
case 181 /* FunctionType */: {
|
|
106264
|
-
return cleanup(factory2.updateFunctionTypeNode(input, visitNodes2(input.typeParameters, visitDeclarationSubtree), updateParamsList(input, input.parameters), visitNode(input.type, visitDeclarationSubtree)));
|
|
106345
|
+
return cleanup(factory2.updateFunctionTypeNode(input, visitNodes2(input.typeParameters, visitDeclarationSubtree, isTypeParameterDeclaration), updateParamsList(input, input.parameters), Debug.checkDefined(visitNode(input.type, visitDeclarationSubtree, isTypeNode))));
|
|
106265
106346
|
}
|
|
106266
106347
|
case 182 /* ConstructorType */: {
|
|
106267
|
-
return cleanup(factory2.updateConstructorTypeNode(input, ensureModifiers(input), visitNodes2(input.typeParameters, visitDeclarationSubtree), updateParamsList(input, input.parameters), visitNode(input.type, visitDeclarationSubtree)));
|
|
106348
|
+
return cleanup(factory2.updateConstructorTypeNode(input, ensureModifiers(input), visitNodes2(input.typeParameters, visitDeclarationSubtree, isTypeParameterDeclaration), updateParamsList(input, input.parameters), Debug.checkDefined(visitNode(input.type, visitDeclarationSubtree, isTypeNode))));
|
|
106268
106349
|
}
|
|
106269
106350
|
case 202 /* ImportType */: {
|
|
106270
106351
|
if (!isLiteralImportTypeNode(input))
|
|
@@ -106408,7 +106489,7 @@ function transformDeclarations(context) {
|
|
|
106408
106489
|
ensureModifiers(input),
|
|
106409
106490
|
input.name,
|
|
106410
106491
|
visitNodes2(input.typeParameters, visitDeclarationSubtree, isTypeParameterDeclaration),
|
|
106411
|
-
visitNode(input.type, visitDeclarationSubtree, isTypeNode)
|
|
106492
|
+
Debug.checkDefined(visitNode(input.type, visitDeclarationSubtree, isTypeNode))
|
|
106412
106493
|
));
|
|
106413
106494
|
needsDeclare = previousNeedsDeclare;
|
|
106414
106495
|
return clean2;
|
|
@@ -106420,7 +106501,7 @@ function transformDeclarations(context) {
|
|
|
106420
106501
|
input.name,
|
|
106421
106502
|
ensureTypeParams(input, input.typeParameters),
|
|
106422
106503
|
transformHeritageClauses(input.heritageClauses),
|
|
106423
|
-
visitNodes2(input.members, visitDeclarationSubtree)
|
|
106504
|
+
visitNodes2(input.members, visitDeclarationSubtree, isTypeElement)
|
|
106424
106505
|
));
|
|
106425
106506
|
}
|
|
106426
106507
|
case 259 /* FunctionDeclaration */: {
|
|
@@ -106537,7 +106618,7 @@ function transformDeclarations(context) {
|
|
|
106537
106618
|
const oldHasScopeFix = resultHasScopeMarker;
|
|
106538
106619
|
resultHasScopeMarker = false;
|
|
106539
106620
|
needsScopeFixMarker = false;
|
|
106540
|
-
const statements = visitNodes2(inner.statements, visitDeclarationStatements);
|
|
106621
|
+
const statements = visitNodes2(inner.statements, visitDeclarationStatements, isStatement);
|
|
106541
106622
|
let lateStatements = transformAndReplaceLatePaintedStatements(statements);
|
|
106542
106623
|
if (input.flags & 16777216 /* Ambient */) {
|
|
106543
106624
|
needsScopeFixMarker = false;
|
|
@@ -106546,7 +106627,7 @@ function transformDeclarations(context) {
|
|
|
106546
106627
|
if (needsScopeFixMarker) {
|
|
106547
106628
|
lateStatements = factory2.createNodeArray([...lateStatements, createEmptyExports(factory2)]);
|
|
106548
106629
|
} else {
|
|
106549
|
-
lateStatements = visitNodes2(lateStatements, stripExportModifiers);
|
|
106630
|
+
lateStatements = visitNodes2(lateStatements, stripExportModifiers, isStatement);
|
|
106550
106631
|
}
|
|
106551
106632
|
}
|
|
106552
106633
|
const body = factory2.updateModuleBlock(inner, lateStatements);
|
|
@@ -106642,7 +106723,7 @@ function transformDeclarations(context) {
|
|
|
106642
106723
|
void 0
|
|
106643
106724
|
)
|
|
106644
106725
|
] : void 0;
|
|
106645
|
-
const memberNodes = concatenate(concatenate(privateIdentifier, parameterProperties), visitNodes2(input.members, visitDeclarationSubtree));
|
|
106726
|
+
const memberNodes = concatenate(concatenate(privateIdentifier, parameterProperties), visitNodes2(input.members, visitDeclarationSubtree, isClassElement));
|
|
106646
106727
|
const members = factory2.createNodeArray(memberNodes);
|
|
106647
106728
|
const extendsClause = getEffectiveBaseTypeNode(input);
|
|
106648
106729
|
if (extendsClause && !isEntityNameExpression(extendsClause.expression) && extendsClause.expression.kind !== 104 /* NullKeyword */) {
|
|
@@ -106666,11 +106747,11 @@ function transformDeclarations(context) {
|
|
|
106666
106747
|
if (clause.token === 94 /* ExtendsKeyword */) {
|
|
106667
106748
|
const oldDiag2 = getSymbolAccessibilityDiagnostic;
|
|
106668
106749
|
getSymbolAccessibilityDiagnostic = createGetSymbolAccessibilityDiagnosticForNode(clause.types[0]);
|
|
106669
|
-
const newClause = factory2.updateHeritageClause(clause, map(clause.types, (t) => factory2.updateExpressionWithTypeArguments(t, newId, visitNodes2(t.typeArguments, visitDeclarationSubtree))));
|
|
106750
|
+
const newClause = factory2.updateHeritageClause(clause, map(clause.types, (t) => factory2.updateExpressionWithTypeArguments(t, newId, visitNodes2(t.typeArguments, visitDeclarationSubtree, isTypeNode))));
|
|
106670
106751
|
getSymbolAccessibilityDiagnostic = oldDiag2;
|
|
106671
106752
|
return newClause;
|
|
106672
106753
|
}
|
|
106673
|
-
return factory2.updateHeritageClause(clause, visitNodes2(factory2.createNodeArray(filter(clause.types, (t) => isEntityNameExpression(t.expression) || t.expression.kind === 104 /* NullKeyword */)), visitDeclarationSubtree));
|
|
106754
|
+
return factory2.updateHeritageClause(clause, visitNodes2(factory2.createNodeArray(filter(clause.types, (t) => isEntityNameExpression(t.expression) || t.expression.kind === 104 /* NullKeyword */)), visitDeclarationSubtree, isExpressionWithTypeArguments));
|
|
106674
106755
|
}));
|
|
106675
106756
|
return [statement, cleanup(factory2.updateClassDeclaration(
|
|
106676
106757
|
input,
|
|
@@ -106726,7 +106807,7 @@ function transformDeclarations(context) {
|
|
|
106726
106807
|
function transformVariableStatement(input) {
|
|
106727
106808
|
if (!forEach(input.declarationList.declarations, getBindingNameVisible))
|
|
106728
106809
|
return;
|
|
106729
|
-
const nodes = visitNodes2(input.declarationList.declarations, visitDeclarationSubtree);
|
|
106810
|
+
const nodes = visitNodes2(input.declarationList.declarations, visitDeclarationSubtree, isVariableDeclaration);
|
|
106730
106811
|
if (!length(nodes))
|
|
106731
106812
|
return;
|
|
106732
106813
|
return factory2.updateVariableStatement(input, factory2.createNodeArray(ensureModifiers(input)), factory2.updateVariableDeclarationList(input.declarationList, nodes));
|
|
@@ -106817,7 +106898,7 @@ function transformDeclarations(context) {
|
|
|
106817
106898
|
function transformHeritageClauses(nodes) {
|
|
106818
106899
|
return factory2.createNodeArray(filter(map(nodes, (clause) => factory2.updateHeritageClause(clause, visitNodes2(factory2.createNodeArray(filter(clause.types, (t) => {
|
|
106819
106900
|
return isEntityNameExpression(t.expression) || clause.token === 94 /* ExtendsKeyword */ && t.expression.kind === 104 /* NullKeyword */;
|
|
106820
|
-
})), visitDeclarationSubtree))), (clause) => clause.types && !!clause.types.length));
|
|
106901
|
+
})), visitDeclarationSubtree, isExpressionWithTypeArguments))), (clause) => clause.types && !!clause.types.length));
|
|
106821
106902
|
}
|
|
106822
106903
|
}
|
|
106823
106904
|
function isAlwaysType(node) {
|
|
@@ -119560,6 +119641,9 @@ function getFilesInErrorForSummary(diagnostics) {
|
|
|
119560
119641
|
}
|
|
119561
119642
|
);
|
|
119562
119643
|
return filesInError.map((fileName) => {
|
|
119644
|
+
if (fileName === void 0) {
|
|
119645
|
+
return void 0;
|
|
119646
|
+
}
|
|
119563
119647
|
const diagnosticForFileName = find(
|
|
119564
119648
|
diagnostics,
|
|
119565
119649
|
(diagnostic) => diagnostic.file !== void 0 && diagnostic.file.fileName === fileName
|
|
@@ -120233,6 +120317,8 @@ function createWatchProgram(host) {
|
|
|
120233
120317
|
parseConfigFile2();
|
|
120234
120318
|
newLine = updateNewLine();
|
|
120235
120319
|
}
|
|
120320
|
+
Debug.assert(compilerOptions);
|
|
120321
|
+
Debug.assert(rootFileNames);
|
|
120236
120322
|
const { watchFile: watchFile2, watchDirectory, writeLog } = createWatchFactory(host, compilerOptions);
|
|
120237
120323
|
const getCanonicalFileName = createGetCanonicalFileName(useCaseSensitiveFileNames);
|
|
120238
120324
|
writeLog(`Current directory: ${currentDirectory} CaseSensitiveFileNames: ${useCaseSensitiveFileNames}`);
|
|
@@ -120335,6 +120421,8 @@ function createWatchProgram(host) {
|
|
|
120335
120421
|
}
|
|
120336
120422
|
function synchronizeProgram() {
|
|
120337
120423
|
writeLog(`Synchronizing program`);
|
|
120424
|
+
Debug.assert(compilerOptions);
|
|
120425
|
+
Debug.assert(rootFileNames);
|
|
120338
120426
|
clearInvalidateResolutionsOfFailedLookupLocations();
|
|
120339
120427
|
const program = getCurrentBuilderProgram();
|
|
120340
120428
|
if (hasChangedCompilerOptions) {
|
|
@@ -120574,6 +120662,8 @@ function createWatchProgram(host) {
|
|
|
120574
120662
|
}
|
|
120575
120663
|
function reloadFileNamesFromConfigFile() {
|
|
120576
120664
|
writeLog("Reloading new file names and options");
|
|
120665
|
+
Debug.assert(compilerOptions);
|
|
120666
|
+
Debug.assert(configFileName);
|
|
120577
120667
|
reloadLevel = 0 /* None */;
|
|
120578
120668
|
rootFileNames = getFileNamesFromConfigSpecs(compilerOptions.configFile.configFileSpecs, getNormalizedAbsolutePath(getDirectoryPath(configFileName), currentDirectory), compilerOptions, parseConfigFileHost, extraFileExtensions);
|
|
120579
120669
|
if (updateErrorForNoInputFiles(rootFileNames, getNormalizedAbsolutePath(configFileName, currentDirectory), compilerOptions.configFile.configFileSpecs, configFileParsingDiagnostics, canConfigFileJsonReportNoInputFiles)) {
|
|
@@ -120582,6 +120672,7 @@ function createWatchProgram(host) {
|
|
|
120582
120672
|
synchronizeProgram();
|
|
120583
120673
|
}
|
|
120584
120674
|
function reloadConfigFile() {
|
|
120675
|
+
Debug.assert(configFileName);
|
|
120585
120676
|
writeLog(`Reloading config file: ${configFileName}`);
|
|
120586
120677
|
reloadLevel = 0 /* None */;
|
|
120587
120678
|
if (cachedDirectoryStructureHost) {
|
|
@@ -120594,6 +120685,7 @@ function createWatchProgram(host) {
|
|
|
120594
120685
|
updateExtendedConfigFilesWatches(toPath3(configFileName), compilerOptions, watchOptions, WatchType.ExtendedConfigFile);
|
|
120595
120686
|
}
|
|
120596
120687
|
function parseConfigFile2() {
|
|
120688
|
+
Debug.assert(configFileName);
|
|
120597
120689
|
setConfigFileParsingResult(getParsedCommandLineOfConfigFile(
|
|
120598
120690
|
configFileName,
|
|
120599
120691
|
optionsToExtendForConfigFile,
|
|
@@ -120621,6 +120713,7 @@ function createWatchProgram(host) {
|
|
|
120621
120713
|
return config.parsedCommandLine;
|
|
120622
120714
|
if (config.parsedCommandLine && config.reloadLevel === 1 /* Partial */ && !host.getParsedCommandLine) {
|
|
120623
120715
|
writeLog("Reloading new file names and options");
|
|
120716
|
+
Debug.assert(compilerOptions);
|
|
120624
120717
|
const fileNames = getFileNamesFromConfigSpecs(
|
|
120625
120718
|
config.parsedCommandLine.options.configFile.configFileSpecs,
|
|
120626
120719
|
getNormalizedAbsolutePath(getDirectoryPath(configFileName2), currentDirectory),
|
|
@@ -120712,7 +120805,8 @@ function createWatchProgram(host) {
|
|
|
120712
120805
|
return watchDirectory(
|
|
120713
120806
|
directory,
|
|
120714
120807
|
(fileOrDirectory) => {
|
|
120715
|
-
Debug.assert(
|
|
120808
|
+
Debug.assert(configFileName);
|
|
120809
|
+
Debug.assert(compilerOptions);
|
|
120716
120810
|
const fileOrDirectoryPath = toPath3(fileOrDirectory);
|
|
120717
120811
|
if (cachedDirectoryStructureHost) {
|
|
120718
120812
|
cachedDirectoryStructureHost.addOrDeleteFileOrDirectory(fileOrDirectory, fileOrDirectoryPath);
|
|
@@ -120743,6 +120837,7 @@ function createWatchProgram(host) {
|
|
|
120743
120837
|
);
|
|
120744
120838
|
}
|
|
120745
120839
|
function updateExtendedConfigFilesWatches(forProjectPath, options, watchOptions2, watchType) {
|
|
120840
|
+
Debug.assert(configFileName);
|
|
120746
120841
|
updateSharedExtendedConfigFileWatcher(
|
|
120747
120842
|
forProjectPath,
|
|
120748
120843
|
options,
|
|
@@ -124583,6 +124678,7 @@ __export(ts_exports3, {
|
|
|
124583
124678
|
isArgumentExpressionOfElementAccess: () => isArgumentExpressionOfElementAccess,
|
|
124584
124679
|
isArray: () => isArray,
|
|
124585
124680
|
isArrayBindingElement: () => isArrayBindingElement,
|
|
124681
|
+
isArrayBindingOrAssignmentElement: () => isArrayBindingOrAssignmentElement,
|
|
124586
124682
|
isArrayBindingOrAssignmentPattern: () => isArrayBindingOrAssignmentPattern,
|
|
124587
124683
|
isArrayBindingPattern: () => isArrayBindingPattern,
|
|
124588
124684
|
isArrayLiteralExpression: () => isArrayLiteralExpression,
|
|
@@ -124615,6 +124711,7 @@ __export(ts_exports3, {
|
|
|
124615
124711
|
isBindableStaticNameExpression: () => isBindableStaticNameExpression,
|
|
124616
124712
|
isBindingElement: () => isBindingElement,
|
|
124617
124713
|
isBindingName: () => isBindingName,
|
|
124714
|
+
isBindingOrAssignmentElement: () => isBindingOrAssignmentElement,
|
|
124618
124715
|
isBindingOrAssignmentPattern: () => isBindingOrAssignmentPattern,
|
|
124619
124716
|
isBindingPattern: () => isBindingPattern,
|
|
124620
124717
|
isBlock: () => isBlock,
|
|
@@ -124821,6 +124918,7 @@ __export(ts_exports3, {
|
|
|
124821
124918
|
isInferTypeNode: () => isInferTypeNode,
|
|
124822
124919
|
isInfinityOrNaNString: () => isInfinityOrNaNString,
|
|
124823
124920
|
isInitializedProperty: () => isInitializedProperty,
|
|
124921
|
+
isInitializedVariable: () => isInitializedVariable,
|
|
124824
124922
|
isInsideJsxElement: () => isInsideJsxElement,
|
|
124825
124923
|
isInsideJsxElementOrAttribute: () => isInsideJsxElementOrAttribute,
|
|
124826
124924
|
isInsideNodeModules: () => isInsideNodeModules,
|
|
@@ -124925,6 +125023,7 @@ __export(ts_exports3, {
|
|
|
124925
125023
|
isLiteralLikeElementAccess: () => isLiteralLikeElementAccess,
|
|
124926
125024
|
isLiteralNameOfPropertyDeclarationOrIndexAccess: () => isLiteralNameOfPropertyDeclarationOrIndexAccess,
|
|
124927
125025
|
isLiteralTypeLikeExpression: () => isLiteralTypeLikeExpression,
|
|
125026
|
+
isLiteralTypeLiteral: () => isLiteralTypeLiteral,
|
|
124928
125027
|
isLiteralTypeNode: () => isLiteralTypeNode,
|
|
124929
125028
|
isLocalName: () => isLocalName,
|
|
124930
125029
|
isLogicalOperator: () => isLogicalOperator,
|
|
@@ -128740,7 +128839,7 @@ function isNonGlobalDeclaration(declaration) {
|
|
|
128740
128839
|
if (!sourceFile.externalModuleIndicator && !sourceFile.commonJsModuleIndicator) {
|
|
128741
128840
|
return false;
|
|
128742
128841
|
}
|
|
128743
|
-
return isInJSFile(declaration) || !findAncestor(declaration, isGlobalScopeAugmentation);
|
|
128842
|
+
return isInJSFile(declaration) || !findAncestor(declaration, (d) => isModuleDeclaration(d) && isGlobalScopeAugmentation(d));
|
|
128744
128843
|
}
|
|
128745
128844
|
function isDeprecatedDeclaration(decl) {
|
|
128746
128845
|
return !!(getCombinedNodeFlagsAlwaysIncludeJSDoc(decl) & 8192 /* Deprecated */);
|
|
@@ -137939,7 +138038,7 @@ function doChange(changes, sourceFile, decl) {
|
|
|
137939
138038
|
if (!param.type) {
|
|
137940
138039
|
const paramType = getJSDocType(param);
|
|
137941
138040
|
if (paramType)
|
|
137942
|
-
changes.tryInsertTypeAnnotation(sourceFile, param,
|
|
138041
|
+
changes.tryInsertTypeAnnotation(sourceFile, param, visitNode(paramType, transformJSDocType, isTypeNode));
|
|
137943
138042
|
}
|
|
137944
138043
|
}
|
|
137945
138044
|
if (needParens)
|
|
@@ -137947,12 +138046,12 @@ function doChange(changes, sourceFile, decl) {
|
|
|
137947
138046
|
if (!decl.type) {
|
|
137948
138047
|
const returnType = getJSDocReturnType(decl);
|
|
137949
138048
|
if (returnType)
|
|
137950
|
-
changes.tryInsertTypeAnnotation(sourceFile, decl,
|
|
138049
|
+
changes.tryInsertTypeAnnotation(sourceFile, decl, visitNode(returnType, transformJSDocType, isTypeNode));
|
|
137951
138050
|
}
|
|
137952
138051
|
} else {
|
|
137953
138052
|
const jsdocType = Debug.checkDefined(getJSDocType(decl), "A JSDocType for this declaration should exist");
|
|
137954
138053
|
Debug.assert(!decl.type, "The JSDocType decl should have a type");
|
|
137955
|
-
changes.tryInsertTypeAnnotation(sourceFile, decl,
|
|
138054
|
+
changes.tryInsertTypeAnnotation(sourceFile, decl, visitNode(jsdocType, transformJSDocType, isTypeNode));
|
|
137956
138055
|
}
|
|
137957
138056
|
}
|
|
137958
138057
|
function isDeclarationWithType(node) {
|
|
@@ -137989,19 +138088,19 @@ function transformJSDocTypeLiteral(node) {
|
|
|
137989
138088
|
void 0,
|
|
137990
138089
|
isIdentifier(tag.name) ? tag.name : tag.name.right,
|
|
137991
138090
|
isOptionalJSDocPropertyLikeTag(tag) ? factory.createToken(57 /* QuestionToken */) : void 0,
|
|
137992
|
-
tag.typeExpression && visitNode(tag.typeExpression.type, transformJSDocType) || factory.createKeywordTypeNode(131 /* AnyKeyword */)
|
|
138091
|
+
tag.typeExpression && visitNode(tag.typeExpression.type, transformJSDocType, isTypeNode) || factory.createKeywordTypeNode(131 /* AnyKeyword */)
|
|
137993
138092
|
)));
|
|
137994
138093
|
setEmitFlags(typeNode, 1 /* SingleLine */);
|
|
137995
138094
|
return typeNode;
|
|
137996
138095
|
}
|
|
137997
138096
|
function transformJSDocOptionalType(node) {
|
|
137998
|
-
return factory.createUnionTypeNode([visitNode(node.type, transformJSDocType), factory.createTypeReferenceNode("undefined", emptyArray)]);
|
|
138097
|
+
return factory.createUnionTypeNode([visitNode(node.type, transformJSDocType, isTypeNode), factory.createTypeReferenceNode("undefined", emptyArray)]);
|
|
137999
138098
|
}
|
|
138000
138099
|
function transformJSDocNullableType(node) {
|
|
138001
|
-
return factory.createUnionTypeNode([visitNode(node.type, transformJSDocType), factory.createTypeReferenceNode("null", emptyArray)]);
|
|
138100
|
+
return factory.createUnionTypeNode([visitNode(node.type, transformJSDocType, isTypeNode), factory.createTypeReferenceNode("null", emptyArray)]);
|
|
138002
138101
|
}
|
|
138003
138102
|
function transformJSDocVariadicType(node) {
|
|
138004
|
-
return factory.createArrayTypeNode(visitNode(node.type, transformJSDocType));
|
|
138103
|
+
return factory.createArrayTypeNode(visitNode(node.type, transformJSDocType, isTypeNode));
|
|
138005
138104
|
}
|
|
138006
138105
|
function transformJSDocFunctionType(node) {
|
|
138007
138106
|
var _a2;
|
|
@@ -138012,7 +138111,7 @@ function transformJSDocParameter(node) {
|
|
|
138012
138111
|
const isRest = node.type.kind === 321 /* JSDocVariadicType */ && index === node.parent.parameters.length - 1;
|
|
138013
138112
|
const name = node.name || (isRest ? "rest" : "arg" + index);
|
|
138014
138113
|
const dotdotdot = isRest ? factory.createToken(25 /* DotDotDotToken */) : node.dotDotDotToken;
|
|
138015
|
-
return factory.createParameterDeclaration(node.modifiers, dotdotdot, name, node.questionToken, visitNode(node.type, transformJSDocType), node.initializer);
|
|
138114
|
+
return factory.createParameterDeclaration(node.modifiers, dotdotdot, name, node.questionToken, visitNode(node.type, transformJSDocType, isTypeNode), node.initializer);
|
|
138016
138115
|
}
|
|
138017
138116
|
function transformJSDocTypeReference(node) {
|
|
138018
138117
|
let name = node.typeName;
|
|
@@ -138039,7 +138138,7 @@ function transformJSDocTypeReference(node) {
|
|
|
138039
138138
|
if ((text === "Array" || text === "Promise") && !node.typeArguments) {
|
|
138040
138139
|
args = factory.createNodeArray([factory.createTypeReferenceNode("any", emptyArray)]);
|
|
138041
138140
|
} else {
|
|
138042
|
-
args = visitNodes2(node.typeArguments, transformJSDocType);
|
|
138141
|
+
args = visitNodes2(node.typeArguments, transformJSDocType, isTypeNode);
|
|
138043
138142
|
}
|
|
138044
138143
|
}
|
|
138045
138144
|
return factory.createTypeReferenceNode(name, args);
|
|
@@ -140597,13 +140696,19 @@ function getUmdSymbol(token, checker) {
|
|
|
140597
140696
|
if (isUMDExportSymbol(umdSymbol))
|
|
140598
140697
|
return umdSymbol;
|
|
140599
140698
|
const { parent: parent2 } = token;
|
|
140600
|
-
|
|
140601
|
-
checker.
|
|
140602
|
-
|
|
140603
|
-
|
|
140604
|
-
|
|
140605
|
-
|
|
140606
|
-
|
|
140699
|
+
if (isJsxOpeningLikeElement(parent2) && parent2.tagName === token || isJsxOpeningFragment(parent2)) {
|
|
140700
|
+
const parentSymbol = checker.resolveName(
|
|
140701
|
+
checker.getJsxNamespace(parent2),
|
|
140702
|
+
isJsxOpeningLikeElement(parent2) ? token : parent2,
|
|
140703
|
+
111551 /* Value */,
|
|
140704
|
+
/*excludeGlobals*/
|
|
140705
|
+
false
|
|
140706
|
+
);
|
|
140707
|
+
if (isUMDExportSymbol(parentSymbol)) {
|
|
140708
|
+
return parentSymbol;
|
|
140709
|
+
}
|
|
140710
|
+
}
|
|
140711
|
+
return void 0;
|
|
140607
140712
|
}
|
|
140608
140713
|
function getImportKind(importingFile, exportKind, compilerOptions, forceImportKeyword) {
|
|
140609
140714
|
switch (exportKind) {
|
|
@@ -145715,18 +145820,17 @@ function findJsonProperty(obj, name) {
|
|
|
145715
145820
|
}
|
|
145716
145821
|
function tryGetAutoImportableReferenceFromTypeNode(importTypeNode, scriptTarget) {
|
|
145717
145822
|
let symbols;
|
|
145718
|
-
const typeNode = visitNode(importTypeNode, visit);
|
|
145823
|
+
const typeNode = visitNode(importTypeNode, visit, isTypeNode);
|
|
145719
145824
|
if (symbols && typeNode) {
|
|
145720
145825
|
return { typeNode, symbols };
|
|
145721
145826
|
}
|
|
145722
145827
|
function visit(node) {
|
|
145723
|
-
var _a2;
|
|
145724
145828
|
if (isLiteralImportTypeNode(node) && node.qualifier) {
|
|
145725
145829
|
const firstIdentifier = getFirstIdentifier(node.qualifier);
|
|
145726
145830
|
const name = getNameForExportedSymbol(firstIdentifier.symbol, scriptTarget);
|
|
145727
145831
|
const qualifier = name !== firstIdentifier.text ? replaceFirstIdentifierOfEntityName(node.qualifier, factory.createIdentifier(name)) : node.qualifier;
|
|
145728
145832
|
symbols = append(symbols, firstIdentifier.symbol);
|
|
145729
|
-
const typeArguments = (
|
|
145833
|
+
const typeArguments = visitNodes2(node.typeArguments, visit, isTypeNode);
|
|
145730
145834
|
return factory.createTypeReferenceNode(qualifier, typeArguments);
|
|
145731
145835
|
}
|
|
145732
145836
|
return visitEachChild(node, visit, nullTransformationContext);
|
|
@@ -147169,6 +147273,7 @@ function completionInfoFromData(sourceFile, host, program, compilerOptions, log,
|
|
|
147169
147273
|
void 0,
|
|
147170
147274
|
contextToken,
|
|
147171
147275
|
location,
|
|
147276
|
+
position,
|
|
147172
147277
|
sourceFile,
|
|
147173
147278
|
host,
|
|
147174
147279
|
program,
|
|
@@ -147494,7 +147599,7 @@ function completionNameForLiteral(sourceFile, preferences, literal) {
|
|
|
147494
147599
|
function createCompletionEntryForLiteral(sourceFile, preferences, literal) {
|
|
147495
147600
|
return { name: completionNameForLiteral(sourceFile, preferences, literal), kind: "string" /* string */, kindModifiers: "" /* none */, sortText: SortText.LocationPriority };
|
|
147496
147601
|
}
|
|
147497
|
-
function createCompletionEntry(symbol, sortText, replacementToken, contextToken, location, sourceFile, host, program, name, needsConvertPropertyAccess, origin, recommendedCompletion, propertyAccessToConvert, isJsxInitializer, importStatementCompletion, useSemicolons, options, preferences, completionKind, formatContext, isJsxIdentifierExpected, isRightOfOpenTag) {
|
|
147602
|
+
function createCompletionEntry(symbol, sortText, replacementToken, contextToken, location, position, sourceFile, host, program, name, needsConvertPropertyAccess, origin, recommendedCompletion, propertyAccessToConvert, isJsxInitializer, importStatementCompletion, useSemicolons, options, preferences, completionKind, formatContext, isJsxIdentifierExpected, isRightOfOpenTag) {
|
|
147498
147603
|
let insertText;
|
|
147499
147604
|
let replacementSpan = getReplacementSpanForContextToken(replacementToken);
|
|
147500
147605
|
let data;
|
|
@@ -147552,7 +147657,7 @@ function createCompletionEntry(symbol, sortText, replacementToken, contextToken,
|
|
|
147552
147657
|
}
|
|
147553
147658
|
if (preferences.includeCompletionsWithClassMemberSnippets && preferences.includeCompletionsWithInsertText && completionKind === CompletionKind.MemberLike && isClassLikeMemberCompletion(symbol, location, sourceFile)) {
|
|
147554
147659
|
let importAdder;
|
|
147555
|
-
({ insertText, isSnippet, importAdder, replacementSpan } = getEntryForMemberCompletion(host, program, options, preferences, name, symbol, location, contextToken, formatContext));
|
|
147660
|
+
({ insertText, isSnippet, importAdder, replacementSpan } = getEntryForMemberCompletion(host, program, options, preferences, name, symbol, location, position, contextToken, formatContext));
|
|
147556
147661
|
sortText = SortText.ClassMemberSnippets;
|
|
147557
147662
|
if (importAdder == null ? void 0 : importAdder.hasFixes()) {
|
|
147558
147663
|
hasAction = true;
|
|
@@ -147616,7 +147721,7 @@ function isClassLikeMemberCompletion(symbol, location, sourceFile) {
|
|
|
147616
147721
|
const memberFlags = 106500 /* ClassMember */ & 900095 /* EnumMemberExcludes */;
|
|
147617
147722
|
return !!(symbol.flags & memberFlags) && (isClassLike(location) || location.parent && location.parent.parent && isClassElement(location.parent) && location === location.parent.name && location.parent.getLastToken(sourceFile) === location.parent.name && isClassLike(location.parent.parent) || location.parent && isSyntaxList(location) && isClassLike(location.parent));
|
|
147618
147723
|
}
|
|
147619
|
-
function getEntryForMemberCompletion(host, program, options, preferences, name, symbol, location, contextToken, formatContext) {
|
|
147724
|
+
function getEntryForMemberCompletion(host, program, options, preferences, name, symbol, location, position, contextToken, formatContext) {
|
|
147620
147725
|
const classLikeDeclaration = findAncestor(location, isClassLike);
|
|
147621
147726
|
if (!classLikeDeclaration) {
|
|
147622
147727
|
return { insertText: name };
|
|
@@ -147652,7 +147757,7 @@ function getEntryForMemberCompletion(host, program, options, preferences, name,
|
|
|
147652
147757
|
);
|
|
147653
147758
|
}
|
|
147654
147759
|
let modifiers = 0 /* None */;
|
|
147655
|
-
const { modifiers: presentModifiers, span: modifiersSpan } = getPresentModifiers(contextToken);
|
|
147760
|
+
const { modifiers: presentModifiers, span: modifiersSpan } = getPresentModifiers(contextToken, sourceFile, position);
|
|
147656
147761
|
const isAbstract = !!(presentModifiers & 256 /* Abstract */);
|
|
147657
147762
|
const completionNodes = [];
|
|
147658
147763
|
ts_codefix_exports.addNewNodeForMemberSymbol(
|
|
@@ -147707,8 +147812,8 @@ function getEntryForMemberCompletion(host, program, options, preferences, name,
|
|
|
147707
147812
|
}
|
|
147708
147813
|
return { insertText, isSnippet, importAdder, replacementSpan };
|
|
147709
147814
|
}
|
|
147710
|
-
function getPresentModifiers(contextToken) {
|
|
147711
|
-
if (!contextToken) {
|
|
147815
|
+
function getPresentModifiers(contextToken, sourceFile, position) {
|
|
147816
|
+
if (!contextToken || getLineAndCharacterOfPosition(sourceFile, position).line > getLineAndCharacterOfPosition(sourceFile, contextToken.getEnd()).line) {
|
|
147712
147817
|
return { modifiers: 0 /* None */ };
|
|
147713
147818
|
}
|
|
147714
147819
|
let modifiers = 0 /* None */;
|
|
@@ -148074,7 +148179,7 @@ function getSourceFromOrigin(origin) {
|
|
|
148074
148179
|
return "TypeOnlyAlias/" /* TypeOnlyAlias */;
|
|
148075
148180
|
}
|
|
148076
148181
|
}
|
|
148077
|
-
function getCompletionEntriesFromSymbols(symbols, entries, replacementToken, contextToken, location, sourceFile, host, program, target, log, kind, preferences, compilerOptions, formatContext, isTypeOnlyLocation, propertyAccessToConvert, jsxIdentifierExpected, isJsxInitializer, importStatementCompletion, recommendedCompletion, symbolToOriginInfoMap, symbolToSortTextMap, isJsxIdentifierExpected, isRightOfOpenTag) {
|
|
148182
|
+
function getCompletionEntriesFromSymbols(symbols, entries, replacementToken, contextToken, location, position, sourceFile, host, program, target, log, kind, preferences, compilerOptions, formatContext, isTypeOnlyLocation, propertyAccessToConvert, jsxIdentifierExpected, isJsxInitializer, importStatementCompletion, recommendedCompletion, symbolToOriginInfoMap, symbolToSortTextMap, isJsxIdentifierExpected, isRightOfOpenTag) {
|
|
148078
148183
|
var _a2;
|
|
148079
148184
|
const start2 = timestamp();
|
|
148080
148185
|
const variableDeclaration = getVariableDeclaration(location);
|
|
@@ -148097,6 +148202,7 @@ function getCompletionEntriesFromSymbols(symbols, entries, replacementToken, con
|
|
|
148097
148202
|
replacementToken,
|
|
148098
148203
|
contextToken,
|
|
148099
148204
|
location,
|
|
148205
|
+
position,
|
|
148100
148206
|
sourceFile,
|
|
148101
148207
|
host,
|
|
148102
148208
|
program,
|
|
@@ -148340,6 +148446,7 @@ function getCompletionEntryCodeActionsAndSourceDisplay(name, location, contextTo
|
|
|
148340
148446
|
name,
|
|
148341
148447
|
symbol,
|
|
148342
148448
|
location,
|
|
148449
|
+
position,
|
|
148343
148450
|
contextToken,
|
|
148344
148451
|
formatContext
|
|
148345
148452
|
);
|
|
@@ -150326,10 +150433,10 @@ function getStringLiteralCompletions(sourceFile, position, contextToken, options
|
|
|
150326
150433
|
if (!contextToken || !isStringLiteralLike(contextToken))
|
|
150327
150434
|
return void 0;
|
|
150328
150435
|
const entries = getStringLiteralCompletionEntries(sourceFile, contextToken, position, program.getTypeChecker(), options, host, preferences);
|
|
150329
|
-
return convertStringLiteralCompletions(entries, contextToken, sourceFile, host, program, log, options, preferences);
|
|
150436
|
+
return convertStringLiteralCompletions(entries, contextToken, sourceFile, host, program, log, options, preferences, position);
|
|
150330
150437
|
}
|
|
150331
150438
|
}
|
|
150332
|
-
function convertStringLiteralCompletions(completion, contextToken, sourceFile, host, program, log, options, preferences) {
|
|
150439
|
+
function convertStringLiteralCompletions(completion, contextToken, sourceFile, host, program, log, options, preferences, position) {
|
|
150333
150440
|
if (completion === void 0) {
|
|
150334
150441
|
return void 0;
|
|
150335
150442
|
}
|
|
@@ -150345,6 +150452,7 @@ function convertStringLiteralCompletions(completion, contextToken, sourceFile, h
|
|
|
150345
150452
|
contextToken,
|
|
150346
150453
|
contextToken,
|
|
150347
150454
|
sourceFile,
|
|
150455
|
+
position,
|
|
150348
150456
|
sourceFile,
|
|
150349
150457
|
host,
|
|
150350
150458
|
program,
|
|
@@ -159944,7 +160052,7 @@ function transformFunctionBody(body, exposedVariableDeclarations, writes, substi
|
|
|
159944
160052
|
let ignoreReturns = false;
|
|
159945
160053
|
const statements = factory.createNodeArray(isBlock(body) ? body.statements.slice(0) : [isStatement(body) ? body : factory.createReturnStatement(skipParentheses(body))]);
|
|
159946
160054
|
if (hasWritesOrVariableDeclarations || substitutions.size) {
|
|
159947
|
-
const rewrittenStatements = visitNodes2(statements, visitor).slice();
|
|
160055
|
+
const rewrittenStatements = visitNodes2(statements, visitor, isStatement).slice();
|
|
159948
160056
|
if (hasWritesOrVariableDeclarations && !hasReturn2 && isStatement(body)) {
|
|
159949
160057
|
const assignments = getPropertyAssignmentsForWritesAndVariableDeclarations(exposedVariableDeclarations, writes);
|
|
159950
160058
|
if (assignments.length === 1) {
|
|
@@ -159972,7 +160080,7 @@ function transformFunctionBody(body, exposedVariableDeclarations, writes, substi
|
|
|
159972
160080
|
if (!returnValueProperty) {
|
|
159973
160081
|
returnValueProperty = "__return";
|
|
159974
160082
|
}
|
|
159975
|
-
assignments.unshift(factory.createPropertyAssignment(returnValueProperty, visitNode(node.expression, visitor)));
|
|
160083
|
+
assignments.unshift(factory.createPropertyAssignment(returnValueProperty, visitNode(node.expression, visitor, isExpression)));
|
|
159976
160084
|
}
|
|
159977
160085
|
if (assignments.length === 1) {
|
|
159978
160086
|
return factory.createReturnStatement(assignments[0].name);
|
|
@@ -162990,6 +163098,7 @@ function assignPositionsToNodeArray(nodes, visitor, test, start2, count) {
|
|
|
162990
163098
|
if (!visited) {
|
|
162991
163099
|
return visited;
|
|
162992
163100
|
}
|
|
163101
|
+
Debug.assert(nodes);
|
|
162993
163102
|
const nodeArray = visited === nodes ? factory.createNodeArray(visited.slice(0)) : visited;
|
|
162994
163103
|
setTextRangePosEnd(nodeArray, getPos2(nodes), getEnd(nodes));
|
|
162995
163104
|
return nodeArray;
|
|
@@ -174657,6 +174766,7 @@ var Session3 = class {
|
|
|
174657
174766
|
constructor(opts) {
|
|
174658
174767
|
this.changeSeq = 0;
|
|
174659
174768
|
this.handlers = new Map(Object.entries({
|
|
174769
|
+
// TODO(jakebailey): correctly type the handlers
|
|
174660
174770
|
[CommandNames.Status]: () => {
|
|
174661
174771
|
const response = { version };
|
|
174662
174772
|
return this.requiredResponse(response);
|
|
@@ -180220,6 +180330,7 @@ start(initializeNodeSystem(), require("os").platform());
|
|
|
180220
180330
|
isArgumentExpressionOfElementAccess,
|
|
180221
180331
|
isArray,
|
|
180222
180332
|
isArrayBindingElement,
|
|
180333
|
+
isArrayBindingOrAssignmentElement,
|
|
180223
180334
|
isArrayBindingOrAssignmentPattern,
|
|
180224
180335
|
isArrayBindingPattern,
|
|
180225
180336
|
isArrayLiteralExpression,
|
|
@@ -180252,6 +180363,7 @@ start(initializeNodeSystem(), require("os").platform());
|
|
|
180252
180363
|
isBindableStaticNameExpression,
|
|
180253
180364
|
isBindingElement,
|
|
180254
180365
|
isBindingName,
|
|
180366
|
+
isBindingOrAssignmentElement,
|
|
180255
180367
|
isBindingOrAssignmentPattern,
|
|
180256
180368
|
isBindingPattern,
|
|
180257
180369
|
isBlock,
|
|
@@ -180458,6 +180570,7 @@ start(initializeNodeSystem(), require("os").platform());
|
|
|
180458
180570
|
isInferTypeNode,
|
|
180459
180571
|
isInfinityOrNaNString,
|
|
180460
180572
|
isInitializedProperty,
|
|
180573
|
+
isInitializedVariable,
|
|
180461
180574
|
isInsideJsxElement,
|
|
180462
180575
|
isInsideJsxElementOrAttribute,
|
|
180463
180576
|
isInsideNodeModules,
|
|
@@ -180562,6 +180675,7 @@ start(initializeNodeSystem(), require("os").platform());
|
|
|
180562
180675
|
isLiteralLikeElementAccess,
|
|
180563
180676
|
isLiteralNameOfPropertyDeclarationOrIndexAccess,
|
|
180564
180677
|
isLiteralTypeLikeExpression,
|
|
180678
|
+
isLiteralTypeLiteral,
|
|
180565
180679
|
isLiteralTypeNode,
|
|
180566
180680
|
isLocalName,
|
|
180567
180681
|
isLogicalOperator,
|