typescript 4.6.0-dev.20220121 → 4.6.0-dev.20220122
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 +13 -2
- package/lib/tsserver.js +19 -3
- package/lib/tsserverlibrary.js +19 -3
- package/lib/typescript.js +19 -3
- package/lib/typescriptServices.js +19 -3
- package/lib/typingsInstaller.js +18 -2
- package/package.json +1 -1
package/lib/tsc.js
CHANGED
|
@@ -69,7 +69,7 @@ var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
|
69
69
|
var ts;
|
|
70
70
|
(function (ts) {
|
|
71
71
|
ts.versionMajorMinor = "4.6";
|
|
72
|
-
ts.version = ts.versionMajorMinor + ".0-dev.
|
|
72
|
+
ts.version = ts.versionMajorMinor + ".0-dev.20220122";
|
|
73
73
|
var NativeCollections;
|
|
74
74
|
(function (NativeCollections) {
|
|
75
75
|
function tryGetNativeMap() {
|
|
@@ -56693,10 +56693,21 @@ var ts;
|
|
|
56693
56693
|
}
|
|
56694
56694
|
if (flags & 2097152) {
|
|
56695
56695
|
ignoreObjects || (ignoreObjects = maybeTypeOfKind(type, 131068));
|
|
56696
|
-
return
|
|
56696
|
+
return getIntersectionTypeFacts(type, ignoreObjects);
|
|
56697
56697
|
}
|
|
56698
56698
|
return 16777215;
|
|
56699
56699
|
}
|
|
56700
|
+
function getIntersectionTypeFacts(type, ignoreObjects) {
|
|
56701
|
+
var oredFacts = 0;
|
|
56702
|
+
var andedFacts = 16777215;
|
|
56703
|
+
for (var _i = 0, _a = type.types; _i < _a.length; _i++) {
|
|
56704
|
+
var t = _a[_i];
|
|
56705
|
+
var f = getTypeFacts(t, ignoreObjects);
|
|
56706
|
+
oredFacts |= f;
|
|
56707
|
+
andedFacts &= f;
|
|
56708
|
+
}
|
|
56709
|
+
return oredFacts & 8288 | andedFacts & 16768927;
|
|
56710
|
+
}
|
|
56700
56711
|
function getTypeWithFacts(type, include) {
|
|
56701
56712
|
return filterType(type, function (t) { return (getTypeFacts(t) & include) !== 0; });
|
|
56702
56713
|
}
|
package/lib/tsserver.js
CHANGED
|
@@ -100,7 +100,7 @@ var ts;
|
|
|
100
100
|
// The following is baselined as a literal template type without intervention
|
|
101
101
|
/** The version of the TypeScript compiler release */
|
|
102
102
|
// eslint-disable-next-line @typescript-eslint/no-inferrable-types
|
|
103
|
-
ts.version = ts.versionMajorMinor + ".0-dev.
|
|
103
|
+
ts.version = ts.versionMajorMinor + ".0-dev.20220122";
|
|
104
104
|
/* @internal */
|
|
105
105
|
var Comparison;
|
|
106
106
|
(function (Comparison) {
|
|
@@ -46788,6 +46788,9 @@ var ts;
|
|
|
46788
46788
|
TypeFacts[TypeFacts["EmptyObjectStrictFacts"] = 16318463] = "EmptyObjectStrictFacts";
|
|
46789
46789
|
TypeFacts[TypeFacts["AllTypeofNE"] = 556800] = "AllTypeofNE";
|
|
46790
46790
|
TypeFacts[TypeFacts["EmptyObjectFacts"] = 16777215] = "EmptyObjectFacts";
|
|
46791
|
+
// Masks
|
|
46792
|
+
TypeFacts[TypeFacts["OrFactsMask"] = 8288] = "OrFactsMask";
|
|
46793
|
+
TypeFacts[TypeFacts["AndFactsMask"] = 16768927] = "AndFactsMask";
|
|
46791
46794
|
})(TypeFacts || (TypeFacts = {}));
|
|
46792
46795
|
var typeofEQFacts = new ts.Map(ts.getEntries({
|
|
46793
46796
|
string: 1 /* TypeofEQString */,
|
|
@@ -67929,10 +67932,23 @@ var ts;
|
|
|
67929
67932
|
// When an intersection contains a primitive type we ignore object type constituents as they are
|
|
67930
67933
|
// presumably type tags. For example, in string & { __kind__: "name" } we ignore the object type.
|
|
67931
67934
|
ignoreObjects || (ignoreObjects = maybeTypeOfKind(type, 131068 /* Primitive */));
|
|
67932
|
-
return
|
|
67935
|
+
return getIntersectionTypeFacts(type, ignoreObjects);
|
|
67933
67936
|
}
|
|
67934
67937
|
return 16777215 /* All */;
|
|
67935
67938
|
}
|
|
67939
|
+
function getIntersectionTypeFacts(type, ignoreObjects) {
|
|
67940
|
+
// When computing the type facts of an intersection type, certain type facts are computed as `and`
|
|
67941
|
+
// and others are computed as `or`.
|
|
67942
|
+
var oredFacts = 0 /* None */;
|
|
67943
|
+
var andedFacts = 16777215 /* All */;
|
|
67944
|
+
for (var _i = 0, _a = type.types; _i < _a.length; _i++) {
|
|
67945
|
+
var t = _a[_i];
|
|
67946
|
+
var f = getTypeFacts(t, ignoreObjects);
|
|
67947
|
+
oredFacts |= f;
|
|
67948
|
+
andedFacts &= f;
|
|
67949
|
+
}
|
|
67950
|
+
return oredFacts & 8288 /* OrFactsMask */ | andedFacts & 16768927 /* AndFactsMask */;
|
|
67951
|
+
}
|
|
67936
67952
|
function getTypeWithFacts(type, include) {
|
|
67937
67953
|
return filterType(type, function (t) { return (getTypeFacts(t) & include) !== 0; });
|
|
67938
67954
|
}
|
|
@@ -136279,7 +136295,7 @@ var ts;
|
|
|
136279
136295
|
return file && { reference: libReferenceDirective, fileName: file.fileName, file: file, unverified: false };
|
|
136280
136296
|
}
|
|
136281
136297
|
if ((_a = sourceFile.resolvedModules) === null || _a === void 0 ? void 0 : _a.size()) {
|
|
136282
|
-
var node = ts.
|
|
136298
|
+
var node = ts.getTouchingToken(sourceFile, position);
|
|
136283
136299
|
if (ts.isModuleSpecifierLike(node) && ts.isExternalModuleNameRelative(node.text) && sourceFile.resolvedModules.has(node.text, ts.getModeForUsageLocation(sourceFile, node))) {
|
|
136284
136300
|
var verifiedFileName = (_b = sourceFile.resolvedModules.get(node.text, ts.getModeForUsageLocation(sourceFile, node))) === null || _b === void 0 ? void 0 : _b.resolvedFileName;
|
|
136285
136301
|
var fileName = verifiedFileName || ts.resolvePath(ts.getDirectoryPath(sourceFile.fileName), node.text);
|
package/lib/tsserverlibrary.js
CHANGED
|
@@ -294,7 +294,7 @@ var ts;
|
|
|
294
294
|
// The following is baselined as a literal template type without intervention
|
|
295
295
|
/** The version of the TypeScript compiler release */
|
|
296
296
|
// eslint-disable-next-line @typescript-eslint/no-inferrable-types
|
|
297
|
-
ts.version = ts.versionMajorMinor + ".0-dev.
|
|
297
|
+
ts.version = ts.versionMajorMinor + ".0-dev.20220122";
|
|
298
298
|
/* @internal */
|
|
299
299
|
var Comparison;
|
|
300
300
|
(function (Comparison) {
|
|
@@ -46982,6 +46982,9 @@ var ts;
|
|
|
46982
46982
|
TypeFacts[TypeFacts["EmptyObjectStrictFacts"] = 16318463] = "EmptyObjectStrictFacts";
|
|
46983
46983
|
TypeFacts[TypeFacts["AllTypeofNE"] = 556800] = "AllTypeofNE";
|
|
46984
46984
|
TypeFacts[TypeFacts["EmptyObjectFacts"] = 16777215] = "EmptyObjectFacts";
|
|
46985
|
+
// Masks
|
|
46986
|
+
TypeFacts[TypeFacts["OrFactsMask"] = 8288] = "OrFactsMask";
|
|
46987
|
+
TypeFacts[TypeFacts["AndFactsMask"] = 16768927] = "AndFactsMask";
|
|
46985
46988
|
})(TypeFacts || (TypeFacts = {}));
|
|
46986
46989
|
var typeofEQFacts = new ts.Map(ts.getEntries({
|
|
46987
46990
|
string: 1 /* TypeofEQString */,
|
|
@@ -68123,10 +68126,23 @@ var ts;
|
|
|
68123
68126
|
// When an intersection contains a primitive type we ignore object type constituents as they are
|
|
68124
68127
|
// presumably type tags. For example, in string & { __kind__: "name" } we ignore the object type.
|
|
68125
68128
|
ignoreObjects || (ignoreObjects = maybeTypeOfKind(type, 131068 /* Primitive */));
|
|
68126
|
-
return
|
|
68129
|
+
return getIntersectionTypeFacts(type, ignoreObjects);
|
|
68127
68130
|
}
|
|
68128
68131
|
return 16777215 /* All */;
|
|
68129
68132
|
}
|
|
68133
|
+
function getIntersectionTypeFacts(type, ignoreObjects) {
|
|
68134
|
+
// When computing the type facts of an intersection type, certain type facts are computed as `and`
|
|
68135
|
+
// and others are computed as `or`.
|
|
68136
|
+
var oredFacts = 0 /* None */;
|
|
68137
|
+
var andedFacts = 16777215 /* All */;
|
|
68138
|
+
for (var _i = 0, _a = type.types; _i < _a.length; _i++) {
|
|
68139
|
+
var t = _a[_i];
|
|
68140
|
+
var f = getTypeFacts(t, ignoreObjects);
|
|
68141
|
+
oredFacts |= f;
|
|
68142
|
+
andedFacts &= f;
|
|
68143
|
+
}
|
|
68144
|
+
return oredFacts & 8288 /* OrFactsMask */ | andedFacts & 16768927 /* AndFactsMask */;
|
|
68145
|
+
}
|
|
68130
68146
|
function getTypeWithFacts(type, include) {
|
|
68131
68147
|
return filterType(type, function (t) { return (getTypeFacts(t) & include) !== 0; });
|
|
68132
68148
|
}
|
|
@@ -136890,7 +136906,7 @@ var ts;
|
|
|
136890
136906
|
return file && { reference: libReferenceDirective, fileName: file.fileName, file: file, unverified: false };
|
|
136891
136907
|
}
|
|
136892
136908
|
if ((_a = sourceFile.resolvedModules) === null || _a === void 0 ? void 0 : _a.size()) {
|
|
136893
|
-
var node = ts.
|
|
136909
|
+
var node = ts.getTouchingToken(sourceFile, position);
|
|
136894
136910
|
if (ts.isModuleSpecifierLike(node) && ts.isExternalModuleNameRelative(node.text) && sourceFile.resolvedModules.has(node.text, ts.getModeForUsageLocation(sourceFile, node))) {
|
|
136895
136911
|
var verifiedFileName = (_b = sourceFile.resolvedModules.get(node.text, ts.getModeForUsageLocation(sourceFile, node))) === null || _b === void 0 ? void 0 : _b.resolvedFileName;
|
|
136896
136912
|
var fileName = verifiedFileName || ts.resolvePath(ts.getDirectoryPath(sourceFile.fileName), node.text);
|
package/lib/typescript.js
CHANGED
|
@@ -294,7 +294,7 @@ var ts;
|
|
|
294
294
|
// The following is baselined as a literal template type without intervention
|
|
295
295
|
/** The version of the TypeScript compiler release */
|
|
296
296
|
// eslint-disable-next-line @typescript-eslint/no-inferrable-types
|
|
297
|
-
ts.version = ts.versionMajorMinor + ".0-dev.
|
|
297
|
+
ts.version = ts.versionMajorMinor + ".0-dev.20220122";
|
|
298
298
|
/* @internal */
|
|
299
299
|
var Comparison;
|
|
300
300
|
(function (Comparison) {
|
|
@@ -46982,6 +46982,9 @@ var ts;
|
|
|
46982
46982
|
TypeFacts[TypeFacts["EmptyObjectStrictFacts"] = 16318463] = "EmptyObjectStrictFacts";
|
|
46983
46983
|
TypeFacts[TypeFacts["AllTypeofNE"] = 556800] = "AllTypeofNE";
|
|
46984
46984
|
TypeFacts[TypeFacts["EmptyObjectFacts"] = 16777215] = "EmptyObjectFacts";
|
|
46985
|
+
// Masks
|
|
46986
|
+
TypeFacts[TypeFacts["OrFactsMask"] = 8288] = "OrFactsMask";
|
|
46987
|
+
TypeFacts[TypeFacts["AndFactsMask"] = 16768927] = "AndFactsMask";
|
|
46985
46988
|
})(TypeFacts || (TypeFacts = {}));
|
|
46986
46989
|
var typeofEQFacts = new ts.Map(ts.getEntries({
|
|
46987
46990
|
string: 1 /* TypeofEQString */,
|
|
@@ -68123,10 +68126,23 @@ var ts;
|
|
|
68123
68126
|
// When an intersection contains a primitive type we ignore object type constituents as they are
|
|
68124
68127
|
// presumably type tags. For example, in string & { __kind__: "name" } we ignore the object type.
|
|
68125
68128
|
ignoreObjects || (ignoreObjects = maybeTypeOfKind(type, 131068 /* Primitive */));
|
|
68126
|
-
return
|
|
68129
|
+
return getIntersectionTypeFacts(type, ignoreObjects);
|
|
68127
68130
|
}
|
|
68128
68131
|
return 16777215 /* All */;
|
|
68129
68132
|
}
|
|
68133
|
+
function getIntersectionTypeFacts(type, ignoreObjects) {
|
|
68134
|
+
// When computing the type facts of an intersection type, certain type facts are computed as `and`
|
|
68135
|
+
// and others are computed as `or`.
|
|
68136
|
+
var oredFacts = 0 /* None */;
|
|
68137
|
+
var andedFacts = 16777215 /* All */;
|
|
68138
|
+
for (var _i = 0, _a = type.types; _i < _a.length; _i++) {
|
|
68139
|
+
var t = _a[_i];
|
|
68140
|
+
var f = getTypeFacts(t, ignoreObjects);
|
|
68141
|
+
oredFacts |= f;
|
|
68142
|
+
andedFacts &= f;
|
|
68143
|
+
}
|
|
68144
|
+
return oredFacts & 8288 /* OrFactsMask */ | andedFacts & 16768927 /* AndFactsMask */;
|
|
68145
|
+
}
|
|
68130
68146
|
function getTypeWithFacts(type, include) {
|
|
68131
68147
|
return filterType(type, function (t) { return (getTypeFacts(t) & include) !== 0; });
|
|
68132
68148
|
}
|
|
@@ -136890,7 +136906,7 @@ var ts;
|
|
|
136890
136906
|
return file && { reference: libReferenceDirective, fileName: file.fileName, file: file, unverified: false };
|
|
136891
136907
|
}
|
|
136892
136908
|
if ((_a = sourceFile.resolvedModules) === null || _a === void 0 ? void 0 : _a.size()) {
|
|
136893
|
-
var node = ts.
|
|
136909
|
+
var node = ts.getTouchingToken(sourceFile, position);
|
|
136894
136910
|
if (ts.isModuleSpecifierLike(node) && ts.isExternalModuleNameRelative(node.text) && sourceFile.resolvedModules.has(node.text, ts.getModeForUsageLocation(sourceFile, node))) {
|
|
136895
136911
|
var verifiedFileName = (_b = sourceFile.resolvedModules.get(node.text, ts.getModeForUsageLocation(sourceFile, node))) === null || _b === void 0 ? void 0 : _b.resolvedFileName;
|
|
136896
136912
|
var fileName = verifiedFileName || ts.resolvePath(ts.getDirectoryPath(sourceFile.fileName), node.text);
|
|
@@ -294,7 +294,7 @@ var ts;
|
|
|
294
294
|
// The following is baselined as a literal template type without intervention
|
|
295
295
|
/** The version of the TypeScript compiler release */
|
|
296
296
|
// eslint-disable-next-line @typescript-eslint/no-inferrable-types
|
|
297
|
-
ts.version = ts.versionMajorMinor + ".0-dev.
|
|
297
|
+
ts.version = ts.versionMajorMinor + ".0-dev.20220122";
|
|
298
298
|
/* @internal */
|
|
299
299
|
var Comparison;
|
|
300
300
|
(function (Comparison) {
|
|
@@ -46982,6 +46982,9 @@ var ts;
|
|
|
46982
46982
|
TypeFacts[TypeFacts["EmptyObjectStrictFacts"] = 16318463] = "EmptyObjectStrictFacts";
|
|
46983
46983
|
TypeFacts[TypeFacts["AllTypeofNE"] = 556800] = "AllTypeofNE";
|
|
46984
46984
|
TypeFacts[TypeFacts["EmptyObjectFacts"] = 16777215] = "EmptyObjectFacts";
|
|
46985
|
+
// Masks
|
|
46986
|
+
TypeFacts[TypeFacts["OrFactsMask"] = 8288] = "OrFactsMask";
|
|
46987
|
+
TypeFacts[TypeFacts["AndFactsMask"] = 16768927] = "AndFactsMask";
|
|
46985
46988
|
})(TypeFacts || (TypeFacts = {}));
|
|
46986
46989
|
var typeofEQFacts = new ts.Map(ts.getEntries({
|
|
46987
46990
|
string: 1 /* TypeofEQString */,
|
|
@@ -68123,10 +68126,23 @@ var ts;
|
|
|
68123
68126
|
// When an intersection contains a primitive type we ignore object type constituents as they are
|
|
68124
68127
|
// presumably type tags. For example, in string & { __kind__: "name" } we ignore the object type.
|
|
68125
68128
|
ignoreObjects || (ignoreObjects = maybeTypeOfKind(type, 131068 /* Primitive */));
|
|
68126
|
-
return
|
|
68129
|
+
return getIntersectionTypeFacts(type, ignoreObjects);
|
|
68127
68130
|
}
|
|
68128
68131
|
return 16777215 /* All */;
|
|
68129
68132
|
}
|
|
68133
|
+
function getIntersectionTypeFacts(type, ignoreObjects) {
|
|
68134
|
+
// When computing the type facts of an intersection type, certain type facts are computed as `and`
|
|
68135
|
+
// and others are computed as `or`.
|
|
68136
|
+
var oredFacts = 0 /* None */;
|
|
68137
|
+
var andedFacts = 16777215 /* All */;
|
|
68138
|
+
for (var _i = 0, _a = type.types; _i < _a.length; _i++) {
|
|
68139
|
+
var t = _a[_i];
|
|
68140
|
+
var f = getTypeFacts(t, ignoreObjects);
|
|
68141
|
+
oredFacts |= f;
|
|
68142
|
+
andedFacts &= f;
|
|
68143
|
+
}
|
|
68144
|
+
return oredFacts & 8288 /* OrFactsMask */ | andedFacts & 16768927 /* AndFactsMask */;
|
|
68145
|
+
}
|
|
68130
68146
|
function getTypeWithFacts(type, include) {
|
|
68131
68147
|
return filterType(type, function (t) { return (getTypeFacts(t) & include) !== 0; });
|
|
68132
68148
|
}
|
|
@@ -136890,7 +136906,7 @@ var ts;
|
|
|
136890
136906
|
return file && { reference: libReferenceDirective, fileName: file.fileName, file: file, unverified: false };
|
|
136891
136907
|
}
|
|
136892
136908
|
if ((_a = sourceFile.resolvedModules) === null || _a === void 0 ? void 0 : _a.size()) {
|
|
136893
|
-
var node = ts.
|
|
136909
|
+
var node = ts.getTouchingToken(sourceFile, position);
|
|
136894
136910
|
if (ts.isModuleSpecifierLike(node) && ts.isExternalModuleNameRelative(node.text) && sourceFile.resolvedModules.has(node.text, ts.getModeForUsageLocation(sourceFile, node))) {
|
|
136895
136911
|
var verifiedFileName = (_b = sourceFile.resolvedModules.get(node.text, ts.getModeForUsageLocation(sourceFile, node))) === null || _b === void 0 ? void 0 : _b.resolvedFileName;
|
|
136896
136912
|
var fileName = verifiedFileName || ts.resolvePath(ts.getDirectoryPath(sourceFile.fileName), node.text);
|
package/lib/typingsInstaller.js
CHANGED
|
@@ -89,7 +89,7 @@ var ts;
|
|
|
89
89
|
// The following is baselined as a literal template type without intervention
|
|
90
90
|
/** The version of the TypeScript compiler release */
|
|
91
91
|
// eslint-disable-next-line @typescript-eslint/no-inferrable-types
|
|
92
|
-
ts.version = ts.versionMajorMinor + ".0-dev.
|
|
92
|
+
ts.version = ts.versionMajorMinor + ".0-dev.20220122";
|
|
93
93
|
/* @internal */
|
|
94
94
|
var Comparison;
|
|
95
95
|
(function (Comparison) {
|
|
@@ -46777,6 +46777,9 @@ var ts;
|
|
|
46777
46777
|
TypeFacts[TypeFacts["EmptyObjectStrictFacts"] = 16318463] = "EmptyObjectStrictFacts";
|
|
46778
46778
|
TypeFacts[TypeFacts["AllTypeofNE"] = 556800] = "AllTypeofNE";
|
|
46779
46779
|
TypeFacts[TypeFacts["EmptyObjectFacts"] = 16777215] = "EmptyObjectFacts";
|
|
46780
|
+
// Masks
|
|
46781
|
+
TypeFacts[TypeFacts["OrFactsMask"] = 8288] = "OrFactsMask";
|
|
46782
|
+
TypeFacts[TypeFacts["AndFactsMask"] = 16768927] = "AndFactsMask";
|
|
46780
46783
|
})(TypeFacts || (TypeFacts = {}));
|
|
46781
46784
|
var typeofEQFacts = new ts.Map(ts.getEntries({
|
|
46782
46785
|
string: 1 /* TypeofEQString */,
|
|
@@ -67918,10 +67921,23 @@ var ts;
|
|
|
67918
67921
|
// When an intersection contains a primitive type we ignore object type constituents as they are
|
|
67919
67922
|
// presumably type tags. For example, in string & { __kind__: "name" } we ignore the object type.
|
|
67920
67923
|
ignoreObjects || (ignoreObjects = maybeTypeOfKind(type, 131068 /* Primitive */));
|
|
67921
|
-
return
|
|
67924
|
+
return getIntersectionTypeFacts(type, ignoreObjects);
|
|
67922
67925
|
}
|
|
67923
67926
|
return 16777215 /* All */;
|
|
67924
67927
|
}
|
|
67928
|
+
function getIntersectionTypeFacts(type, ignoreObjects) {
|
|
67929
|
+
// When computing the type facts of an intersection type, certain type facts are computed as `and`
|
|
67930
|
+
// and others are computed as `or`.
|
|
67931
|
+
var oredFacts = 0 /* None */;
|
|
67932
|
+
var andedFacts = 16777215 /* All */;
|
|
67933
|
+
for (var _i = 0, _a = type.types; _i < _a.length; _i++) {
|
|
67934
|
+
var t = _a[_i];
|
|
67935
|
+
var f = getTypeFacts(t, ignoreObjects);
|
|
67936
|
+
oredFacts |= f;
|
|
67937
|
+
andedFacts &= f;
|
|
67938
|
+
}
|
|
67939
|
+
return oredFacts & 8288 /* OrFactsMask */ | andedFacts & 16768927 /* AndFactsMask */;
|
|
67940
|
+
}
|
|
67925
67941
|
function getTypeWithFacts(type, include) {
|
|
67926
67942
|
return filterType(type, function (t) { return (getTypeFacts(t) & include) !== 0; });
|
|
67927
67943
|
}
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "typescript",
|
|
3
3
|
"author": "Microsoft Corp.",
|
|
4
4
|
"homepage": "https://www.typescriptlang.org/",
|
|
5
|
-
"version": "4.6.0-dev.
|
|
5
|
+
"version": "4.6.0-dev.20220122",
|
|
6
6
|
"license": "Apache-2.0",
|
|
7
7
|
"description": "TypeScript is a language for application scale JavaScript development",
|
|
8
8
|
"keywords": [
|