@typescript-deploys/pr-build 5.3.0-pr-56004-36 → 5.3.0-pr-56122-13
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 +21 -37
- package/lib/tsserver.js +21 -37
- package/lib/typescript.js +21 -37
- package/lib/typingsInstaller.js +1 -1
- package/package.json +2 -2
package/lib/tsc.js
CHANGED
|
@@ -18,7 +18,7 @@ and limitations under the License.
|
|
|
18
18
|
|
|
19
19
|
// src/compiler/corePublic.ts
|
|
20
20
|
var versionMajorMinor = "5.3";
|
|
21
|
-
var version = `${versionMajorMinor}.0-insiders.
|
|
21
|
+
var version = `${versionMajorMinor}.0-insiders.20231016`;
|
|
22
22
|
|
|
23
23
|
// src/compiler/core.ts
|
|
24
24
|
var emptyArray = [];
|
|
@@ -54085,12 +54085,7 @@ function createTypeChecker(host) {
|
|
|
54085
54085
|
const checkType = type.checkType;
|
|
54086
54086
|
const constraint = getLowerBoundOfKeyType(checkType);
|
|
54087
54087
|
if (constraint !== checkType) {
|
|
54088
|
-
return getConditionalTypeInstantiation(
|
|
54089
|
-
type,
|
|
54090
|
-
prependTypeMapping(type.root.checkType, constraint, type.mapper),
|
|
54091
|
-
/*forConstraint*/
|
|
54092
|
-
false
|
|
54093
|
-
);
|
|
54088
|
+
return getConditionalTypeInstantiation(type, prependTypeMapping(type.root.checkType, constraint, type.mapper));
|
|
54094
54089
|
}
|
|
54095
54090
|
}
|
|
54096
54091
|
return type;
|
|
@@ -54442,12 +54437,7 @@ function createTypeChecker(host) {
|
|
|
54442
54437
|
);
|
|
54443
54438
|
const constraint = simplified === type.checkType ? getConstraintOfType(simplified) : simplified;
|
|
54444
54439
|
if (constraint && constraint !== type.checkType) {
|
|
54445
|
-
const instantiated = getConditionalTypeInstantiation(
|
|
54446
|
-
type,
|
|
54447
|
-
prependTypeMapping(type.root.checkType, constraint, type.mapper),
|
|
54448
|
-
/*forConstraint*/
|
|
54449
|
-
true
|
|
54450
|
-
);
|
|
54440
|
+
const instantiated = getConditionalTypeInstantiation(type, prependTypeMapping(type.root.checkType, constraint, type.mapper));
|
|
54451
54441
|
if (!(instantiated.flags & 131072 /* Never */)) {
|
|
54452
54442
|
type.resolvedConstraintOfDistributive = instantiated;
|
|
54453
54443
|
return instantiated;
|
|
@@ -58010,7 +58000,7 @@ function createTypeChecker(host) {
|
|
|
58010
58000
|
function isDeferredType(type, checkTuples) {
|
|
58011
58001
|
return isGenericType(type) || checkTuples && isTupleType(type) && some(getElementTypes(type), isGenericType);
|
|
58012
58002
|
}
|
|
58013
|
-
function getConditionalType(root, mapper,
|
|
58003
|
+
function getConditionalType(root, mapper, aliasSymbol, aliasTypeArguments) {
|
|
58014
58004
|
let result;
|
|
58015
58005
|
let extraTypes;
|
|
58016
58006
|
let tailCount = 0;
|
|
@@ -58056,7 +58046,7 @@ function createTypeChecker(host) {
|
|
|
58056
58046
|
const inferredExtendsType = combinedMapper ? instantiateType(root.extendsType, combinedMapper) : extendsType;
|
|
58057
58047
|
if (!checkTypeDeferred && !isDeferredType(inferredExtendsType, checkTuples)) {
|
|
58058
58048
|
if (!(inferredExtendsType.flags & 3 /* AnyOrUnknown */) && (checkType.flags & 1 /* Any */ || !isTypeAssignableTo(getPermissiveInstantiation(checkType), getPermissiveInstantiation(inferredExtendsType)))) {
|
|
58059
|
-
if (checkType.flags & 1 /* Any */
|
|
58049
|
+
if (checkType.flags & 1 /* Any */) {
|
|
58060
58050
|
(extraTypes || (extraTypes = [])).push(instantiateType(getTypeFromTypeNode(root.node.trueType), combinedMapper || mapper));
|
|
58061
58051
|
}
|
|
58062
58052
|
const falseType2 = getTypeFromTypeNode(root.node.falseType);
|
|
@@ -58166,9 +58156,7 @@ function createTypeChecker(host) {
|
|
|
58166
58156
|
links.resolvedType = getConditionalType(
|
|
58167
58157
|
root,
|
|
58168
58158
|
/*mapper*/
|
|
58169
|
-
void 0
|
|
58170
|
-
/*forConstraint*/
|
|
58171
|
-
false
|
|
58159
|
+
void 0
|
|
58172
58160
|
);
|
|
58173
58161
|
if (outerTypeParameters) {
|
|
58174
58162
|
root.instantiations = /* @__PURE__ */ new Map();
|
|
@@ -59022,17 +59010,17 @@ function createTypeChecker(host) {
|
|
|
59022
59010
|
result.objectFlags |= result.aliasTypeArguments ? getPropagatingFlagsOfTypes(result.aliasTypeArguments) : 0;
|
|
59023
59011
|
return result;
|
|
59024
59012
|
}
|
|
59025
|
-
function getConditionalTypeInstantiation(type, mapper,
|
|
59013
|
+
function getConditionalTypeInstantiation(type, mapper, aliasSymbol, aliasTypeArguments) {
|
|
59026
59014
|
const root = type.root;
|
|
59027
59015
|
if (root.outerTypeParameters) {
|
|
59028
59016
|
const typeArguments = map(root.outerTypeParameters, (t) => getMappedType(t, mapper));
|
|
59029
|
-
const id =
|
|
59017
|
+
const id = getTypeListId(typeArguments) + getAliasId(aliasSymbol, aliasTypeArguments);
|
|
59030
59018
|
let result = root.instantiations.get(id);
|
|
59031
59019
|
if (!result) {
|
|
59032
59020
|
const newMapper = createTypeMapper(root.outerTypeParameters, typeArguments);
|
|
59033
59021
|
const checkType = root.checkType;
|
|
59034
59022
|
const distributionType = root.isDistributive ? getMappedType(checkType, newMapper) : void 0;
|
|
59035
|
-
result = distributionType && checkType !== distributionType && distributionType.flags & (1048576 /* Union */ | 131072 /* Never */) ? mapTypeWithAlias(getReducedType(distributionType), (t) => getConditionalType(root, prependTypeMapping(checkType, t, newMapper)
|
|
59023
|
+
result = distributionType && checkType !== distributionType && distributionType.flags & (1048576 /* Union */ | 131072 /* Never */) ? mapTypeWithAlias(getReducedType(distributionType), (t) => getConditionalType(root, prependTypeMapping(checkType, t, newMapper)), aliasSymbol, aliasTypeArguments) : getConditionalType(root, newMapper, aliasSymbol, aliasTypeArguments);
|
|
59036
59024
|
root.instantiations.set(id, result);
|
|
59037
59025
|
}
|
|
59038
59026
|
return result;
|
|
@@ -59120,14 +59108,7 @@ function createTypeChecker(host) {
|
|
|
59120
59108
|
);
|
|
59121
59109
|
}
|
|
59122
59110
|
if (flags & 16777216 /* Conditional */) {
|
|
59123
|
-
return getConditionalTypeInstantiation(
|
|
59124
|
-
type,
|
|
59125
|
-
combineTypeMappers(type.mapper, mapper),
|
|
59126
|
-
/*forConstraint*/
|
|
59127
|
-
false,
|
|
59128
|
-
aliasSymbol,
|
|
59129
|
-
aliasTypeArguments
|
|
59130
|
-
);
|
|
59111
|
+
return getConditionalTypeInstantiation(type, combineTypeMappers(type.mapper, mapper), aliasSymbol, aliasTypeArguments);
|
|
59131
59112
|
}
|
|
59132
59113
|
if (flags & 33554432 /* Substitution */) {
|
|
59133
59114
|
const newBaseType = instantiateType(type.baseType, mapper);
|
|
@@ -61668,6 +61649,13 @@ function createTypeChecker(host) {
|
|
|
61668
61649
|
return result2;
|
|
61669
61650
|
}
|
|
61670
61651
|
}
|
|
61652
|
+
} else {
|
|
61653
|
+
const distributiveConstraint = hasNonCircularBaseConstraint(source2) ? getConstraintOfDistributiveConditionalType(source2) : void 0;
|
|
61654
|
+
if (distributiveConstraint) {
|
|
61655
|
+
if (result2 = isRelatedTo(distributiveConstraint, target2, 1 /* Source */, reportErrors2)) {
|
|
61656
|
+
return result2;
|
|
61657
|
+
}
|
|
61658
|
+
}
|
|
61671
61659
|
}
|
|
61672
61660
|
const defaultConstraint = getDefaultConstraintOfConditionalType(source2);
|
|
61673
61661
|
if (defaultConstraint) {
|
|
@@ -61675,13 +61663,6 @@ function createTypeChecker(host) {
|
|
|
61675
61663
|
return result2;
|
|
61676
61664
|
}
|
|
61677
61665
|
}
|
|
61678
|
-
const distributiveConstraint = !(targetFlags & 16777216 /* Conditional */) && hasNonCircularBaseConstraint(source2) ? getConstraintOfDistributiveConditionalType(source2) : void 0;
|
|
61679
|
-
if (distributiveConstraint) {
|
|
61680
|
-
resetErrorInfo(saveErrorInfo);
|
|
61681
|
-
if (result2 = isRelatedTo(distributiveConstraint, target2, 1 /* Source */, reportErrors2)) {
|
|
61682
|
-
return result2;
|
|
61683
|
-
}
|
|
61684
|
-
}
|
|
61685
61666
|
} else {
|
|
61686
61667
|
if (relation !== subtypeRelation && relation !== strictSubtypeRelation && isPartialMappedType(target2) && isEmptyObjectType(source2)) {
|
|
61687
61668
|
return -1 /* True */;
|
|
@@ -73723,7 +73704,7 @@ function createTypeChecker(host) {
|
|
|
73723
73704
|
return typeofType;
|
|
73724
73705
|
}
|
|
73725
73706
|
function checkVoidExpression(node) {
|
|
73726
|
-
|
|
73707
|
+
checkNodeDeferred(node);
|
|
73727
73708
|
return undefinedWideningType;
|
|
73728
73709
|
}
|
|
73729
73710
|
function checkAwaitGrammar(node) {
|
|
@@ -80919,6 +80900,9 @@ function createTypeChecker(host) {
|
|
|
80919
80900
|
case 217 /* ParenthesizedExpression */:
|
|
80920
80901
|
checkAssertionDeferred(node);
|
|
80921
80902
|
break;
|
|
80903
|
+
case 222 /* VoidExpression */:
|
|
80904
|
+
checkExpression(node.expression);
|
|
80905
|
+
break;
|
|
80922
80906
|
case 226 /* BinaryExpression */:
|
|
80923
80907
|
if (isInstanceOfExpression(node)) {
|
|
80924
80908
|
resolveUntypedCall(node);
|
package/lib/tsserver.js
CHANGED
|
@@ -2328,7 +2328,7 @@ module.exports = __toCommonJS(server_exports);
|
|
|
2328
2328
|
|
|
2329
2329
|
// src/compiler/corePublic.ts
|
|
2330
2330
|
var versionMajorMinor = "5.3";
|
|
2331
|
-
var version = `${versionMajorMinor}.0-insiders.
|
|
2331
|
+
var version = `${versionMajorMinor}.0-insiders.20231016`;
|
|
2332
2332
|
var Comparison = /* @__PURE__ */ ((Comparison3) => {
|
|
2333
2333
|
Comparison3[Comparison3["LessThan"] = -1] = "LessThan";
|
|
2334
2334
|
Comparison3[Comparison3["EqualTo"] = 0] = "EqualTo";
|
|
@@ -58797,12 +58797,7 @@ function createTypeChecker(host) {
|
|
|
58797
58797
|
const checkType = type.checkType;
|
|
58798
58798
|
const constraint = getLowerBoundOfKeyType(checkType);
|
|
58799
58799
|
if (constraint !== checkType) {
|
|
58800
|
-
return getConditionalTypeInstantiation(
|
|
58801
|
-
type,
|
|
58802
|
-
prependTypeMapping(type.root.checkType, constraint, type.mapper),
|
|
58803
|
-
/*forConstraint*/
|
|
58804
|
-
false
|
|
58805
|
-
);
|
|
58800
|
+
return getConditionalTypeInstantiation(type, prependTypeMapping(type.root.checkType, constraint, type.mapper));
|
|
58806
58801
|
}
|
|
58807
58802
|
}
|
|
58808
58803
|
return type;
|
|
@@ -59154,12 +59149,7 @@ function createTypeChecker(host) {
|
|
|
59154
59149
|
);
|
|
59155
59150
|
const constraint = simplified === type.checkType ? getConstraintOfType(simplified) : simplified;
|
|
59156
59151
|
if (constraint && constraint !== type.checkType) {
|
|
59157
|
-
const instantiated = getConditionalTypeInstantiation(
|
|
59158
|
-
type,
|
|
59159
|
-
prependTypeMapping(type.root.checkType, constraint, type.mapper),
|
|
59160
|
-
/*forConstraint*/
|
|
59161
|
-
true
|
|
59162
|
-
);
|
|
59152
|
+
const instantiated = getConditionalTypeInstantiation(type, prependTypeMapping(type.root.checkType, constraint, type.mapper));
|
|
59163
59153
|
if (!(instantiated.flags & 131072 /* Never */)) {
|
|
59164
59154
|
type.resolvedConstraintOfDistributive = instantiated;
|
|
59165
59155
|
return instantiated;
|
|
@@ -62722,7 +62712,7 @@ function createTypeChecker(host) {
|
|
|
62722
62712
|
function isDeferredType(type, checkTuples) {
|
|
62723
62713
|
return isGenericType(type) || checkTuples && isTupleType(type) && some(getElementTypes(type), isGenericType);
|
|
62724
62714
|
}
|
|
62725
|
-
function getConditionalType(root, mapper,
|
|
62715
|
+
function getConditionalType(root, mapper, aliasSymbol, aliasTypeArguments) {
|
|
62726
62716
|
let result;
|
|
62727
62717
|
let extraTypes;
|
|
62728
62718
|
let tailCount = 0;
|
|
@@ -62768,7 +62758,7 @@ function createTypeChecker(host) {
|
|
|
62768
62758
|
const inferredExtendsType = combinedMapper ? instantiateType(root.extendsType, combinedMapper) : extendsType;
|
|
62769
62759
|
if (!checkTypeDeferred && !isDeferredType(inferredExtendsType, checkTuples)) {
|
|
62770
62760
|
if (!(inferredExtendsType.flags & 3 /* AnyOrUnknown */) && (checkType.flags & 1 /* Any */ || !isTypeAssignableTo(getPermissiveInstantiation(checkType), getPermissiveInstantiation(inferredExtendsType)))) {
|
|
62771
|
-
if (checkType.flags & 1 /* Any */
|
|
62761
|
+
if (checkType.flags & 1 /* Any */) {
|
|
62772
62762
|
(extraTypes || (extraTypes = [])).push(instantiateType(getTypeFromTypeNode(root.node.trueType), combinedMapper || mapper));
|
|
62773
62763
|
}
|
|
62774
62764
|
const falseType2 = getTypeFromTypeNode(root.node.falseType);
|
|
@@ -62878,9 +62868,7 @@ function createTypeChecker(host) {
|
|
|
62878
62868
|
links.resolvedType = getConditionalType(
|
|
62879
62869
|
root,
|
|
62880
62870
|
/*mapper*/
|
|
62881
|
-
void 0
|
|
62882
|
-
/*forConstraint*/
|
|
62883
|
-
false
|
|
62871
|
+
void 0
|
|
62884
62872
|
);
|
|
62885
62873
|
if (outerTypeParameters) {
|
|
62886
62874
|
root.instantiations = /* @__PURE__ */ new Map();
|
|
@@ -63734,17 +63722,17 @@ function createTypeChecker(host) {
|
|
|
63734
63722
|
result.objectFlags |= result.aliasTypeArguments ? getPropagatingFlagsOfTypes(result.aliasTypeArguments) : 0;
|
|
63735
63723
|
return result;
|
|
63736
63724
|
}
|
|
63737
|
-
function getConditionalTypeInstantiation(type, mapper,
|
|
63725
|
+
function getConditionalTypeInstantiation(type, mapper, aliasSymbol, aliasTypeArguments) {
|
|
63738
63726
|
const root = type.root;
|
|
63739
63727
|
if (root.outerTypeParameters) {
|
|
63740
63728
|
const typeArguments = map(root.outerTypeParameters, (t) => getMappedType(t, mapper));
|
|
63741
|
-
const id =
|
|
63729
|
+
const id = getTypeListId(typeArguments) + getAliasId(aliasSymbol, aliasTypeArguments);
|
|
63742
63730
|
let result = root.instantiations.get(id);
|
|
63743
63731
|
if (!result) {
|
|
63744
63732
|
const newMapper = createTypeMapper(root.outerTypeParameters, typeArguments);
|
|
63745
63733
|
const checkType = root.checkType;
|
|
63746
63734
|
const distributionType = root.isDistributive ? getMappedType(checkType, newMapper) : void 0;
|
|
63747
|
-
result = distributionType && checkType !== distributionType && distributionType.flags & (1048576 /* Union */ | 131072 /* Never */) ? mapTypeWithAlias(getReducedType(distributionType), (t) => getConditionalType(root, prependTypeMapping(checkType, t, newMapper)
|
|
63735
|
+
result = distributionType && checkType !== distributionType && distributionType.flags & (1048576 /* Union */ | 131072 /* Never */) ? mapTypeWithAlias(getReducedType(distributionType), (t) => getConditionalType(root, prependTypeMapping(checkType, t, newMapper)), aliasSymbol, aliasTypeArguments) : getConditionalType(root, newMapper, aliasSymbol, aliasTypeArguments);
|
|
63748
63736
|
root.instantiations.set(id, result);
|
|
63749
63737
|
}
|
|
63750
63738
|
return result;
|
|
@@ -63832,14 +63820,7 @@ function createTypeChecker(host) {
|
|
|
63832
63820
|
);
|
|
63833
63821
|
}
|
|
63834
63822
|
if (flags & 16777216 /* Conditional */) {
|
|
63835
|
-
return getConditionalTypeInstantiation(
|
|
63836
|
-
type,
|
|
63837
|
-
combineTypeMappers(type.mapper, mapper),
|
|
63838
|
-
/*forConstraint*/
|
|
63839
|
-
false,
|
|
63840
|
-
aliasSymbol,
|
|
63841
|
-
aliasTypeArguments
|
|
63842
|
-
);
|
|
63823
|
+
return getConditionalTypeInstantiation(type, combineTypeMappers(type.mapper, mapper), aliasSymbol, aliasTypeArguments);
|
|
63843
63824
|
}
|
|
63844
63825
|
if (flags & 33554432 /* Substitution */) {
|
|
63845
63826
|
const newBaseType = instantiateType(type.baseType, mapper);
|
|
@@ -66380,6 +66361,13 @@ function createTypeChecker(host) {
|
|
|
66380
66361
|
return result2;
|
|
66381
66362
|
}
|
|
66382
66363
|
}
|
|
66364
|
+
} else {
|
|
66365
|
+
const distributiveConstraint = hasNonCircularBaseConstraint(source2) ? getConstraintOfDistributiveConditionalType(source2) : void 0;
|
|
66366
|
+
if (distributiveConstraint) {
|
|
66367
|
+
if (result2 = isRelatedTo(distributiveConstraint, target2, 1 /* Source */, reportErrors2)) {
|
|
66368
|
+
return result2;
|
|
66369
|
+
}
|
|
66370
|
+
}
|
|
66383
66371
|
}
|
|
66384
66372
|
const defaultConstraint = getDefaultConstraintOfConditionalType(source2);
|
|
66385
66373
|
if (defaultConstraint) {
|
|
@@ -66387,13 +66375,6 @@ function createTypeChecker(host) {
|
|
|
66387
66375
|
return result2;
|
|
66388
66376
|
}
|
|
66389
66377
|
}
|
|
66390
|
-
const distributiveConstraint = !(targetFlags & 16777216 /* Conditional */) && hasNonCircularBaseConstraint(source2) ? getConstraintOfDistributiveConditionalType(source2) : void 0;
|
|
66391
|
-
if (distributiveConstraint) {
|
|
66392
|
-
resetErrorInfo(saveErrorInfo);
|
|
66393
|
-
if (result2 = isRelatedTo(distributiveConstraint, target2, 1 /* Source */, reportErrors2)) {
|
|
66394
|
-
return result2;
|
|
66395
|
-
}
|
|
66396
|
-
}
|
|
66397
66378
|
} else {
|
|
66398
66379
|
if (relation !== subtypeRelation && relation !== strictSubtypeRelation && isPartialMappedType(target2) && isEmptyObjectType(source2)) {
|
|
66399
66380
|
return -1 /* True */;
|
|
@@ -78435,7 +78416,7 @@ function createTypeChecker(host) {
|
|
|
78435
78416
|
return typeofType;
|
|
78436
78417
|
}
|
|
78437
78418
|
function checkVoidExpression(node) {
|
|
78438
|
-
|
|
78419
|
+
checkNodeDeferred(node);
|
|
78439
78420
|
return undefinedWideningType;
|
|
78440
78421
|
}
|
|
78441
78422
|
function checkAwaitGrammar(node) {
|
|
@@ -85631,6 +85612,9 @@ function createTypeChecker(host) {
|
|
|
85631
85612
|
case 217 /* ParenthesizedExpression */:
|
|
85632
85613
|
checkAssertionDeferred(node);
|
|
85633
85614
|
break;
|
|
85615
|
+
case 222 /* VoidExpression */:
|
|
85616
|
+
checkExpression(node.expression);
|
|
85617
|
+
break;
|
|
85634
85618
|
case 226 /* BinaryExpression */:
|
|
85635
85619
|
if (isInstanceOfExpression(node)) {
|
|
85636
85620
|
resolveUntypedCall(node);
|
package/lib/typescript.js
CHANGED
|
@@ -35,7 +35,7 @@ var ts = (() => {
|
|
|
35
35
|
"src/compiler/corePublic.ts"() {
|
|
36
36
|
"use strict";
|
|
37
37
|
versionMajorMinor = "5.3";
|
|
38
|
-
version = `${versionMajorMinor}.0-insiders.
|
|
38
|
+
version = `${versionMajorMinor}.0-insiders.20231016`;
|
|
39
39
|
Comparison = /* @__PURE__ */ ((Comparison3) => {
|
|
40
40
|
Comparison3[Comparison3["LessThan"] = -1] = "LessThan";
|
|
41
41
|
Comparison3[Comparison3["EqualTo"] = 0] = "EqualTo";
|
|
@@ -56564,12 +56564,7 @@ ${lanes.join("\n")}
|
|
|
56564
56564
|
const checkType = type.checkType;
|
|
56565
56565
|
const constraint = getLowerBoundOfKeyType(checkType);
|
|
56566
56566
|
if (constraint !== checkType) {
|
|
56567
|
-
return getConditionalTypeInstantiation(
|
|
56568
|
-
type,
|
|
56569
|
-
prependTypeMapping(type.root.checkType, constraint, type.mapper),
|
|
56570
|
-
/*forConstraint*/
|
|
56571
|
-
false
|
|
56572
|
-
);
|
|
56567
|
+
return getConditionalTypeInstantiation(type, prependTypeMapping(type.root.checkType, constraint, type.mapper));
|
|
56573
56568
|
}
|
|
56574
56569
|
}
|
|
56575
56570
|
return type;
|
|
@@ -56921,12 +56916,7 @@ ${lanes.join("\n")}
|
|
|
56921
56916
|
);
|
|
56922
56917
|
const constraint = simplified === type.checkType ? getConstraintOfType(simplified) : simplified;
|
|
56923
56918
|
if (constraint && constraint !== type.checkType) {
|
|
56924
|
-
const instantiated = getConditionalTypeInstantiation(
|
|
56925
|
-
type,
|
|
56926
|
-
prependTypeMapping(type.root.checkType, constraint, type.mapper),
|
|
56927
|
-
/*forConstraint*/
|
|
56928
|
-
true
|
|
56929
|
-
);
|
|
56919
|
+
const instantiated = getConditionalTypeInstantiation(type, prependTypeMapping(type.root.checkType, constraint, type.mapper));
|
|
56930
56920
|
if (!(instantiated.flags & 131072 /* Never */)) {
|
|
56931
56921
|
type.resolvedConstraintOfDistributive = instantiated;
|
|
56932
56922
|
return instantiated;
|
|
@@ -60489,7 +60479,7 @@ ${lanes.join("\n")}
|
|
|
60489
60479
|
function isDeferredType(type, checkTuples) {
|
|
60490
60480
|
return isGenericType(type) || checkTuples && isTupleType(type) && some(getElementTypes(type), isGenericType);
|
|
60491
60481
|
}
|
|
60492
|
-
function getConditionalType(root, mapper,
|
|
60482
|
+
function getConditionalType(root, mapper, aliasSymbol, aliasTypeArguments) {
|
|
60493
60483
|
let result;
|
|
60494
60484
|
let extraTypes;
|
|
60495
60485
|
let tailCount = 0;
|
|
@@ -60535,7 +60525,7 @@ ${lanes.join("\n")}
|
|
|
60535
60525
|
const inferredExtendsType = combinedMapper ? instantiateType(root.extendsType, combinedMapper) : extendsType;
|
|
60536
60526
|
if (!checkTypeDeferred && !isDeferredType(inferredExtendsType, checkTuples)) {
|
|
60537
60527
|
if (!(inferredExtendsType.flags & 3 /* AnyOrUnknown */) && (checkType.flags & 1 /* Any */ || !isTypeAssignableTo(getPermissiveInstantiation(checkType), getPermissiveInstantiation(inferredExtendsType)))) {
|
|
60538
|
-
if (checkType.flags & 1 /* Any */
|
|
60528
|
+
if (checkType.flags & 1 /* Any */) {
|
|
60539
60529
|
(extraTypes || (extraTypes = [])).push(instantiateType(getTypeFromTypeNode(root.node.trueType), combinedMapper || mapper));
|
|
60540
60530
|
}
|
|
60541
60531
|
const falseType2 = getTypeFromTypeNode(root.node.falseType);
|
|
@@ -60645,9 +60635,7 @@ ${lanes.join("\n")}
|
|
|
60645
60635
|
links.resolvedType = getConditionalType(
|
|
60646
60636
|
root,
|
|
60647
60637
|
/*mapper*/
|
|
60648
|
-
void 0
|
|
60649
|
-
/*forConstraint*/
|
|
60650
|
-
false
|
|
60638
|
+
void 0
|
|
60651
60639
|
);
|
|
60652
60640
|
if (outerTypeParameters) {
|
|
60653
60641
|
root.instantiations = /* @__PURE__ */ new Map();
|
|
@@ -61501,17 +61489,17 @@ ${lanes.join("\n")}
|
|
|
61501
61489
|
result.objectFlags |= result.aliasTypeArguments ? getPropagatingFlagsOfTypes(result.aliasTypeArguments) : 0;
|
|
61502
61490
|
return result;
|
|
61503
61491
|
}
|
|
61504
|
-
function getConditionalTypeInstantiation(type, mapper,
|
|
61492
|
+
function getConditionalTypeInstantiation(type, mapper, aliasSymbol, aliasTypeArguments) {
|
|
61505
61493
|
const root = type.root;
|
|
61506
61494
|
if (root.outerTypeParameters) {
|
|
61507
61495
|
const typeArguments = map(root.outerTypeParameters, (t) => getMappedType(t, mapper));
|
|
61508
|
-
const id =
|
|
61496
|
+
const id = getTypeListId(typeArguments) + getAliasId(aliasSymbol, aliasTypeArguments);
|
|
61509
61497
|
let result = root.instantiations.get(id);
|
|
61510
61498
|
if (!result) {
|
|
61511
61499
|
const newMapper = createTypeMapper(root.outerTypeParameters, typeArguments);
|
|
61512
61500
|
const checkType = root.checkType;
|
|
61513
61501
|
const distributionType = root.isDistributive ? getMappedType(checkType, newMapper) : void 0;
|
|
61514
|
-
result = distributionType && checkType !== distributionType && distributionType.flags & (1048576 /* Union */ | 131072 /* Never */) ? mapTypeWithAlias(getReducedType(distributionType), (t) => getConditionalType(root, prependTypeMapping(checkType, t, newMapper)
|
|
61502
|
+
result = distributionType && checkType !== distributionType && distributionType.flags & (1048576 /* Union */ | 131072 /* Never */) ? mapTypeWithAlias(getReducedType(distributionType), (t) => getConditionalType(root, prependTypeMapping(checkType, t, newMapper)), aliasSymbol, aliasTypeArguments) : getConditionalType(root, newMapper, aliasSymbol, aliasTypeArguments);
|
|
61515
61503
|
root.instantiations.set(id, result);
|
|
61516
61504
|
}
|
|
61517
61505
|
return result;
|
|
@@ -61599,14 +61587,7 @@ ${lanes.join("\n")}
|
|
|
61599
61587
|
);
|
|
61600
61588
|
}
|
|
61601
61589
|
if (flags & 16777216 /* Conditional */) {
|
|
61602
|
-
return getConditionalTypeInstantiation(
|
|
61603
|
-
type,
|
|
61604
|
-
combineTypeMappers(type.mapper, mapper),
|
|
61605
|
-
/*forConstraint*/
|
|
61606
|
-
false,
|
|
61607
|
-
aliasSymbol,
|
|
61608
|
-
aliasTypeArguments
|
|
61609
|
-
);
|
|
61590
|
+
return getConditionalTypeInstantiation(type, combineTypeMappers(type.mapper, mapper), aliasSymbol, aliasTypeArguments);
|
|
61610
61591
|
}
|
|
61611
61592
|
if (flags & 33554432 /* Substitution */) {
|
|
61612
61593
|
const newBaseType = instantiateType(type.baseType, mapper);
|
|
@@ -64147,6 +64128,13 @@ ${lanes.join("\n")}
|
|
|
64147
64128
|
return result2;
|
|
64148
64129
|
}
|
|
64149
64130
|
}
|
|
64131
|
+
} else {
|
|
64132
|
+
const distributiveConstraint = hasNonCircularBaseConstraint(source2) ? getConstraintOfDistributiveConditionalType(source2) : void 0;
|
|
64133
|
+
if (distributiveConstraint) {
|
|
64134
|
+
if (result2 = isRelatedTo(distributiveConstraint, target2, 1 /* Source */, reportErrors2)) {
|
|
64135
|
+
return result2;
|
|
64136
|
+
}
|
|
64137
|
+
}
|
|
64150
64138
|
}
|
|
64151
64139
|
const defaultConstraint = getDefaultConstraintOfConditionalType(source2);
|
|
64152
64140
|
if (defaultConstraint) {
|
|
@@ -64154,13 +64142,6 @@ ${lanes.join("\n")}
|
|
|
64154
64142
|
return result2;
|
|
64155
64143
|
}
|
|
64156
64144
|
}
|
|
64157
|
-
const distributiveConstraint = !(targetFlags & 16777216 /* Conditional */) && hasNonCircularBaseConstraint(source2) ? getConstraintOfDistributiveConditionalType(source2) : void 0;
|
|
64158
|
-
if (distributiveConstraint) {
|
|
64159
|
-
resetErrorInfo(saveErrorInfo);
|
|
64160
|
-
if (result2 = isRelatedTo(distributiveConstraint, target2, 1 /* Source */, reportErrors2)) {
|
|
64161
|
-
return result2;
|
|
64162
|
-
}
|
|
64163
|
-
}
|
|
64164
64145
|
} else {
|
|
64165
64146
|
if (relation !== subtypeRelation && relation !== strictSubtypeRelation && isPartialMappedType(target2) && isEmptyObjectType(source2)) {
|
|
64166
64147
|
return -1 /* True */;
|
|
@@ -76202,7 +76183,7 @@ ${lanes.join("\n")}
|
|
|
76202
76183
|
return typeofType;
|
|
76203
76184
|
}
|
|
76204
76185
|
function checkVoidExpression(node) {
|
|
76205
|
-
|
|
76186
|
+
checkNodeDeferred(node);
|
|
76206
76187
|
return undefinedWideningType;
|
|
76207
76188
|
}
|
|
76208
76189
|
function checkAwaitGrammar(node) {
|
|
@@ -83398,6 +83379,9 @@ ${lanes.join("\n")}
|
|
|
83398
83379
|
case 217 /* ParenthesizedExpression */:
|
|
83399
83380
|
checkAssertionDeferred(node);
|
|
83400
83381
|
break;
|
|
83382
|
+
case 222 /* VoidExpression */:
|
|
83383
|
+
checkExpression(node.expression);
|
|
83384
|
+
break;
|
|
83401
83385
|
case 226 /* BinaryExpression */:
|
|
83402
83386
|
if (isInstanceOfExpression(node)) {
|
|
83403
83387
|
resolveUntypedCall(node);
|
package/lib/typingsInstaller.js
CHANGED
|
@@ -54,7 +54,7 @@ var path = __toESM(require("path"));
|
|
|
54
54
|
|
|
55
55
|
// src/compiler/corePublic.ts
|
|
56
56
|
var versionMajorMinor = "5.3";
|
|
57
|
-
var version = `${versionMajorMinor}.0-insiders.
|
|
57
|
+
var version = `${versionMajorMinor}.0-insiders.20231016`;
|
|
58
58
|
|
|
59
59
|
// src/compiler/core.ts
|
|
60
60
|
var emptyArray = [];
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "@typescript-deploys/pr-build",
|
|
3
3
|
"author": "Microsoft Corp.",
|
|
4
4
|
"homepage": "https://www.typescriptlang.org/",
|
|
5
|
-
"version": "5.3.0-pr-
|
|
5
|
+
"version": "5.3.0-pr-56122-13",
|
|
6
6
|
"license": "Apache-2.0",
|
|
7
7
|
"description": "TypeScript is a language for application scale JavaScript development",
|
|
8
8
|
"keywords": [
|
|
@@ -115,5 +115,5 @@
|
|
|
115
115
|
"node": "20.1.0",
|
|
116
116
|
"npm": "8.19.4"
|
|
117
117
|
},
|
|
118
|
-
"gitHead": "
|
|
118
|
+
"gitHead": "defd225d9968cdbec1354f759020bedbf129c2d8"
|
|
119
119
|
}
|