@typescript-deploys/pr-build 5.7.0-pr-59975-15 → 5.7.0-pr-58573-47
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/lib.es2016.intl.d.ts +1 -1
- package/lib/lib.es2017.arraybuffer.d.ts +21 -0
- package/lib/lib.es2017.d.ts +3 -2
- package/lib/lib.es2017.sharedmemory.d.ts +2 -2
- package/lib/lib.es2020.bigint.d.ts +1 -1
- package/lib/lib.es2020.intl.d.ts +36 -36
- package/lib/lib.es2020.sharedmemory.d.ts +2 -0
- package/lib/lib.es2020.string.d.ts +2 -0
- package/lib/lib.es2021.intl.d.ts +17 -17
- package/lib/lib.es2021.weakref.d.ts +2 -0
- package/lib/lib.es2022.d.ts +1 -2
- package/lib/lib.es2022.error.d.ts +2 -0
- package/lib/lib.es2022.intl.d.ts +9 -9
- package/lib/lib.es2024.arraybuffer.d.ts +65 -0
- package/lib/lib.es2024.collection.d.ts +29 -0
- package/lib/lib.es2024.d.ts +26 -0
- package/lib/lib.es2024.full.d.ts +24 -0
- package/lib/{lib.es2022.sharedmemory.d.ts → lib.es2024.sharedmemory.d.ts} +29 -0
- package/lib/lib.es5.d.ts +1 -1
- package/lib/lib.esnext.collection.d.ts +1 -11
- package/lib/lib.esnext.d.ts +1 -5
- package/lib/tsc.js +138 -28
- package/lib/typescript.d.ts +2 -0
- package/lib/typescript.js +140 -28
- package/package.json +1 -1
- /package/lib/{lib.esnext.object.d.ts → lib.es2024.object.d.ts} +0 -0
- /package/lib/{lib.esnext.promise.d.ts → lib.es2024.promise.d.ts} +0 -0
- /package/lib/{lib.esnext.regexp.d.ts → lib.es2024.regexp.d.ts} +0 -0
- /package/lib/{lib.esnext.string.d.ts → lib.es2024.string.d.ts} +0 -0
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
/*! *****************************************************************************
|
|
2
|
+
Copyright (c) Microsoft Corporation. All rights reserved.
|
|
3
|
+
Licensed under the Apache License, Version 2.0 (the "License"); you may not use
|
|
4
|
+
this file except in compliance with the License. You may obtain a copy of the
|
|
5
|
+
License at http://www.apache.org/licenses/LICENSE-2.0
|
|
6
|
+
|
|
7
|
+
THIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
|
8
|
+
KIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED
|
|
9
|
+
WARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,
|
|
10
|
+
MERCHANTABLITY OR NON-INFRINGEMENT.
|
|
11
|
+
|
|
12
|
+
See the Apache Version 2.0 License for specific language governing permissions
|
|
13
|
+
and limitations under the License.
|
|
14
|
+
***************************************************************************** */
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
/// <reference no-default-lib="true"/>
|
|
18
|
+
|
|
19
|
+
interface MapConstructor {
|
|
20
|
+
/**
|
|
21
|
+
* Groups members of an iterable according to the return value of the passed callback.
|
|
22
|
+
* @param items An iterable.
|
|
23
|
+
* @param keySelector A callback which will be invoked for each item in items.
|
|
24
|
+
*/
|
|
25
|
+
groupBy<K, T>(
|
|
26
|
+
items: Iterable<T>,
|
|
27
|
+
keySelector: (item: T, index: number) => K,
|
|
28
|
+
): Map<K, T[]>;
|
|
29
|
+
}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
/*! *****************************************************************************
|
|
2
|
+
Copyright (c) Microsoft Corporation. All rights reserved.
|
|
3
|
+
Licensed under the Apache License, Version 2.0 (the "License"); you may not use
|
|
4
|
+
this file except in compliance with the License. You may obtain a copy of the
|
|
5
|
+
License at http://www.apache.org/licenses/LICENSE-2.0
|
|
6
|
+
|
|
7
|
+
THIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
|
8
|
+
KIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED
|
|
9
|
+
WARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,
|
|
10
|
+
MERCHANTABLITY OR NON-INFRINGEMENT.
|
|
11
|
+
|
|
12
|
+
See the Apache Version 2.0 License for specific language governing permissions
|
|
13
|
+
and limitations under the License.
|
|
14
|
+
***************************************************************************** */
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
/// <reference no-default-lib="true"/>
|
|
18
|
+
|
|
19
|
+
/// <reference lib="es2023" />
|
|
20
|
+
/// <reference lib="es2024.arraybuffer" />
|
|
21
|
+
/// <reference lib="es2024.collection" />
|
|
22
|
+
/// <reference lib="es2024.object" />
|
|
23
|
+
/// <reference lib="es2024.promise" />
|
|
24
|
+
/// <reference lib="es2024.regexp" />
|
|
25
|
+
/// <reference lib="es2024.sharedmemory" />
|
|
26
|
+
/// <reference lib="es2024.string" />
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
/*! *****************************************************************************
|
|
2
|
+
Copyright (c) Microsoft Corporation. All rights reserved.
|
|
3
|
+
Licensed under the Apache License, Version 2.0 (the "License"); you may not use
|
|
4
|
+
this file except in compliance with the License. You may obtain a copy of the
|
|
5
|
+
License at http://www.apache.org/licenses/LICENSE-2.0
|
|
6
|
+
|
|
7
|
+
THIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
|
8
|
+
KIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED
|
|
9
|
+
WARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,
|
|
10
|
+
MERCHANTABLITY OR NON-INFRINGEMENT.
|
|
11
|
+
|
|
12
|
+
See the Apache Version 2.0 License for specific language governing permissions
|
|
13
|
+
and limitations under the License.
|
|
14
|
+
***************************************************************************** */
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
/// <reference no-default-lib="true"/>
|
|
18
|
+
|
|
19
|
+
/// <reference lib="es2024" />
|
|
20
|
+
/// <reference lib="dom" />
|
|
21
|
+
/// <reference lib="webworker.importscripts" />
|
|
22
|
+
/// <reference lib="scripthost" />
|
|
23
|
+
/// <reference lib="dom.iterable" />
|
|
24
|
+
/// <reference lib="dom.asynciterable" />
|
|
@@ -16,6 +16,8 @@ and limitations under the License.
|
|
|
16
16
|
|
|
17
17
|
/// <reference no-default-lib="true"/>
|
|
18
18
|
|
|
19
|
+
/// <reference lib="es2020.bigint" />
|
|
20
|
+
|
|
19
21
|
interface Atomics {
|
|
20
22
|
/**
|
|
21
23
|
* A non-blocking, asynchronous version of wait which is usable on the main thread.
|
|
@@ -37,3 +39,30 @@ interface Atomics {
|
|
|
37
39
|
*/
|
|
38
40
|
waitAsync(typedArray: BigInt64Array, index: number, value: bigint, timeout?: number): { async: false; value: "not-equal" | "timed-out"; } | { async: true; value: Promise<"ok" | "timed-out">; };
|
|
39
41
|
}
|
|
42
|
+
|
|
43
|
+
interface SharedArrayBuffer {
|
|
44
|
+
/**
|
|
45
|
+
* Returns true if this SharedArrayBuffer can be grown.
|
|
46
|
+
*
|
|
47
|
+
* [MDN](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/SharedArrayBuffer/growable)
|
|
48
|
+
*/
|
|
49
|
+
get growable(): number;
|
|
50
|
+
|
|
51
|
+
/**
|
|
52
|
+
* If this SharedArrayBuffer is growable, returns the maximum byte length given during construction; returns the byte length if not.
|
|
53
|
+
*
|
|
54
|
+
* [MDN](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/SharedArrayBuffer/maxByteLength)
|
|
55
|
+
*/
|
|
56
|
+
get maxByteLength(): number;
|
|
57
|
+
|
|
58
|
+
/**
|
|
59
|
+
* Grows the SharedArrayBuffer to the specified size (in bytes).
|
|
60
|
+
*
|
|
61
|
+
* [MDN](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/SharedArrayBuffer/grow)
|
|
62
|
+
*/
|
|
63
|
+
grow(newByteLength?: number): void;
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
interface SharedArrayBufferConstructor {
|
|
67
|
+
new (byteLength: number, options?: { maxByteLength?: number; }): SharedArrayBuffer;
|
|
68
|
+
}
|
package/lib/lib.es5.d.ts
CHANGED
|
@@ -16,17 +16,7 @@ and limitations under the License.
|
|
|
16
16
|
|
|
17
17
|
/// <reference no-default-lib="true"/>
|
|
18
18
|
|
|
19
|
-
|
|
20
|
-
/**
|
|
21
|
-
* Groups members of an iterable according to the return value of the passed callback.
|
|
22
|
-
* @param items An iterable.
|
|
23
|
-
* @param keySelector A callback which will be invoked for each item in items.
|
|
24
|
-
*/
|
|
25
|
-
groupBy<K, T>(
|
|
26
|
-
items: Iterable<T>,
|
|
27
|
-
keySelector: (item: T, index: number) => K,
|
|
28
|
-
): Map<K, T[]>;
|
|
29
|
-
}
|
|
19
|
+
/// <reference lib="es2024.collection" />
|
|
30
20
|
|
|
31
21
|
interface ReadonlySetLike<T> {
|
|
32
22
|
/**
|
package/lib/lib.esnext.d.ts
CHANGED
|
@@ -16,14 +16,10 @@ and limitations under the License.
|
|
|
16
16
|
|
|
17
17
|
/// <reference no-default-lib="true"/>
|
|
18
18
|
|
|
19
|
-
/// <reference lib="
|
|
19
|
+
/// <reference lib="es2024" />
|
|
20
20
|
/// <reference lib="esnext.intl" />
|
|
21
21
|
/// <reference lib="esnext.decorators" />
|
|
22
22
|
/// <reference lib="esnext.disposable" />
|
|
23
|
-
/// <reference lib="esnext.promise" />
|
|
24
|
-
/// <reference lib="esnext.object" />
|
|
25
23
|
/// <reference lib="esnext.collection" />
|
|
26
24
|
/// <reference lib="esnext.array" />
|
|
27
|
-
/// <reference lib="esnext.regexp" />
|
|
28
|
-
/// <reference lib="esnext.string" />
|
|
29
25
|
/// <reference lib="esnext.iterator" />
|
package/lib/tsc.js
CHANGED
|
@@ -3885,10 +3885,10 @@ var LanguageFeatureMinimumTarget = {
|
|
|
3885
3885
|
ClassFields: 9 /* ES2022 */,
|
|
3886
3886
|
PrivateNamesAndClassStaticBlocks: 9 /* ES2022 */,
|
|
3887
3887
|
RegularExpressionFlagsHasIndices: 9 /* ES2022 */,
|
|
3888
|
-
ShebangComments:
|
|
3888
|
+
ShebangComments: 10 /* ES2023 */,
|
|
3889
|
+
RegularExpressionFlagsUnicodeSets: 11 /* ES2024 */,
|
|
3889
3890
|
UsingAndAwaitUsing: 99 /* ESNext */,
|
|
3890
|
-
ClassAndClassElementDecorators: 99 /* ESNext
|
|
3891
|
-
RegularExpressionFlagsUnicodeSets: 99 /* ESNext */
|
|
3891
|
+
ClassAndClassElementDecorators: 99 /* ESNext */
|
|
3892
3892
|
};
|
|
3893
3893
|
var commentPragmas = {
|
|
3894
3894
|
"reference": {
|
|
@@ -13011,11 +13011,45 @@ var getScriptTargetFeatures = /* @__PURE__ */ memoize(
|
|
|
13011
13011
|
AsyncIterator: new Map(Object.entries({
|
|
13012
13012
|
es2015: emptyArray
|
|
13013
13013
|
})),
|
|
13014
|
+
ArrayBuffer: new Map(Object.entries({
|
|
13015
|
+
es2024: [
|
|
13016
|
+
"maxByteLength",
|
|
13017
|
+
"resizable",
|
|
13018
|
+
"resize",
|
|
13019
|
+
"detached",
|
|
13020
|
+
"transfer",
|
|
13021
|
+
"transferToFixedLength"
|
|
13022
|
+
]
|
|
13023
|
+
})),
|
|
13014
13024
|
Atomics: new Map(Object.entries({
|
|
13015
|
-
es2017:
|
|
13025
|
+
es2017: [
|
|
13026
|
+
"add",
|
|
13027
|
+
"and",
|
|
13028
|
+
"compareExchange",
|
|
13029
|
+
"exchange",
|
|
13030
|
+
"isLockFree",
|
|
13031
|
+
"load",
|
|
13032
|
+
"or",
|
|
13033
|
+
"store",
|
|
13034
|
+
"sub",
|
|
13035
|
+
"wait",
|
|
13036
|
+
"notify",
|
|
13037
|
+
"xor"
|
|
13038
|
+
],
|
|
13039
|
+
es2024: [
|
|
13040
|
+
"waitAsync"
|
|
13041
|
+
]
|
|
13016
13042
|
})),
|
|
13017
13043
|
SharedArrayBuffer: new Map(Object.entries({
|
|
13018
|
-
es2017:
|
|
13044
|
+
es2017: [
|
|
13045
|
+
"byteLength",
|
|
13046
|
+
"slice"
|
|
13047
|
+
],
|
|
13048
|
+
es2024: [
|
|
13049
|
+
"growable",
|
|
13050
|
+
"maxByteLength",
|
|
13051
|
+
"grow"
|
|
13052
|
+
]
|
|
13019
13053
|
})),
|
|
13020
13054
|
AsyncIterable: new Map(Object.entries({
|
|
13021
13055
|
es2018: emptyArray
|
|
@@ -13037,6 +13071,9 @@ var getScriptTargetFeatures = /* @__PURE__ */ memoize(
|
|
|
13037
13071
|
],
|
|
13038
13072
|
es2018: [
|
|
13039
13073
|
"dotAll"
|
|
13074
|
+
],
|
|
13075
|
+
es2024: [
|
|
13076
|
+
"unicodeSets"
|
|
13040
13077
|
]
|
|
13041
13078
|
})),
|
|
13042
13079
|
Reflect: new Map(Object.entries({
|
|
@@ -13083,6 +13120,9 @@ var getScriptTargetFeatures = /* @__PURE__ */ memoize(
|
|
|
13083
13120
|
],
|
|
13084
13121
|
es2022: [
|
|
13085
13122
|
"hasOwn"
|
|
13123
|
+
],
|
|
13124
|
+
es2024: [
|
|
13125
|
+
"groupBy"
|
|
13086
13126
|
]
|
|
13087
13127
|
})),
|
|
13088
13128
|
NumberConstructor: new Map(Object.entries({
|
|
@@ -13123,11 +13163,25 @@ var getScriptTargetFeatures = /* @__PURE__ */ memoize(
|
|
|
13123
13163
|
"values"
|
|
13124
13164
|
]
|
|
13125
13165
|
})),
|
|
13166
|
+
MapConstructor: new Map(Object.entries({
|
|
13167
|
+
es2024: [
|
|
13168
|
+
"groupBy"
|
|
13169
|
+
]
|
|
13170
|
+
})),
|
|
13126
13171
|
Set: new Map(Object.entries({
|
|
13127
13172
|
es2015: [
|
|
13128
13173
|
"entries",
|
|
13129
13174
|
"keys",
|
|
13130
13175
|
"values"
|
|
13176
|
+
],
|
|
13177
|
+
esnext: [
|
|
13178
|
+
"union",
|
|
13179
|
+
"intersection",
|
|
13180
|
+
"difference",
|
|
13181
|
+
"symmetricDifference",
|
|
13182
|
+
"isSubsetOf",
|
|
13183
|
+
"isSupersetOf",
|
|
13184
|
+
"isDisjointFrom"
|
|
13131
13185
|
]
|
|
13132
13186
|
})),
|
|
13133
13187
|
PromiseConstructor: new Map(Object.entries({
|
|
@@ -13142,6 +13196,9 @@ var getScriptTargetFeatures = /* @__PURE__ */ memoize(
|
|
|
13142
13196
|
],
|
|
13143
13197
|
es2021: [
|
|
13144
13198
|
"any"
|
|
13199
|
+
],
|
|
13200
|
+
es2024: [
|
|
13201
|
+
"withResolvers"
|
|
13145
13202
|
]
|
|
13146
13203
|
})),
|
|
13147
13204
|
Symbol: new Map(Object.entries({
|
|
@@ -13208,7 +13265,7 @@ var getScriptTargetFeatures = /* @__PURE__ */ memoize(
|
|
|
13208
13265
|
es2022: [
|
|
13209
13266
|
"at"
|
|
13210
13267
|
],
|
|
13211
|
-
|
|
13268
|
+
es2024: [
|
|
13212
13269
|
"isWellFormed",
|
|
13213
13270
|
"toWellFormed"
|
|
13214
13271
|
]
|
|
@@ -13253,6 +13310,11 @@ var getScriptTargetFeatures = /* @__PURE__ */ memoize(
|
|
|
13253
13310
|
SymbolConstructor: new Map(Object.entries({
|
|
13254
13311
|
es2020: [
|
|
13255
13312
|
"matchAll"
|
|
13313
|
+
],
|
|
13314
|
+
esnext: [
|
|
13315
|
+
"metadata",
|
|
13316
|
+
"dispose",
|
|
13317
|
+
"asyncDispose"
|
|
13256
13318
|
]
|
|
13257
13319
|
})),
|
|
13258
13320
|
DataView: new Map(Object.entries({
|
|
@@ -35848,6 +35910,7 @@ var libEntries = [
|
|
|
35848
35910
|
["es2021", "lib.es2021.d.ts"],
|
|
35849
35911
|
["es2022", "lib.es2022.d.ts"],
|
|
35850
35912
|
["es2023", "lib.es2023.d.ts"],
|
|
35913
|
+
["es2024", "lib.es2024.d.ts"],
|
|
35851
35914
|
["esnext", "lib.esnext.d.ts"],
|
|
35852
35915
|
// Host only
|
|
35853
35916
|
["dom", "lib.dom.d.ts"],
|
|
@@ -35870,6 +35933,7 @@ var libEntries = [
|
|
|
35870
35933
|
["es2015.symbol.wellknown", "lib.es2015.symbol.wellknown.d.ts"],
|
|
35871
35934
|
["es2016.array.include", "lib.es2016.array.include.d.ts"],
|
|
35872
35935
|
["es2016.intl", "lib.es2016.intl.d.ts"],
|
|
35936
|
+
["es2017.arraybuffer", "lib.es2017.arraybuffer.d.ts"],
|
|
35873
35937
|
["es2017.date", "lib.es2017.date.d.ts"],
|
|
35874
35938
|
["es2017.object", "lib.es2017.object.d.ts"],
|
|
35875
35939
|
["es2017.sharedmemory", "lib.es2017.sharedmemory.d.ts"],
|
|
@@ -35902,12 +35966,18 @@ var libEntries = [
|
|
|
35902
35966
|
["es2022.error", "lib.es2022.error.d.ts"],
|
|
35903
35967
|
["es2022.intl", "lib.es2022.intl.d.ts"],
|
|
35904
35968
|
["es2022.object", "lib.es2022.object.d.ts"],
|
|
35905
|
-
["es2022.sharedmemory", "lib.es2022.sharedmemory.d.ts"],
|
|
35906
35969
|
["es2022.string", "lib.es2022.string.d.ts"],
|
|
35907
35970
|
["es2022.regexp", "lib.es2022.regexp.d.ts"],
|
|
35908
35971
|
["es2023.array", "lib.es2023.array.d.ts"],
|
|
35909
35972
|
["es2023.collection", "lib.es2023.collection.d.ts"],
|
|
35910
35973
|
["es2023.intl", "lib.es2023.intl.d.ts"],
|
|
35974
|
+
["es2024.arraybuffer", "lib.es2024.arraybuffer.d.ts"],
|
|
35975
|
+
["es2024.collection", "lib.es2024.collection.d.ts"],
|
|
35976
|
+
["es2024.object", "lib.es2024.object.d.ts"],
|
|
35977
|
+
["es2024.promise", "lib.es2024.promise.d.ts"],
|
|
35978
|
+
["es2024.regexp", "lib.es2024.regexp.d.ts"],
|
|
35979
|
+
["es2024.sharedmemory", "lib.es2024.sharedmemory.d.ts"],
|
|
35980
|
+
["es2024.string", "lib.es2024.string.d.ts"],
|
|
35911
35981
|
["esnext.array", "lib.es2023.array.d.ts"],
|
|
35912
35982
|
["esnext.collection", "lib.esnext.collection.d.ts"],
|
|
35913
35983
|
["esnext.symbol", "lib.es2019.symbol.d.ts"],
|
|
@@ -35916,13 +35986,13 @@ var libEntries = [
|
|
|
35916
35986
|
["esnext.disposable", "lib.esnext.disposable.d.ts"],
|
|
35917
35987
|
["esnext.bigint", "lib.es2020.bigint.d.ts"],
|
|
35918
35988
|
["esnext.string", "lib.es2022.string.d.ts"],
|
|
35919
|
-
["esnext.promise", "lib.
|
|
35989
|
+
["esnext.promise", "lib.es2024.promise.d.ts"],
|
|
35920
35990
|
["esnext.weakref", "lib.es2021.weakref.d.ts"],
|
|
35921
35991
|
["esnext.decorators", "lib.esnext.decorators.d.ts"],
|
|
35922
|
-
["esnext.object", "lib.
|
|
35992
|
+
["esnext.object", "lib.es2024.object.d.ts"],
|
|
35923
35993
|
["esnext.array", "lib.esnext.array.d.ts"],
|
|
35924
|
-
["esnext.regexp", "lib.
|
|
35925
|
-
["esnext.string", "lib.
|
|
35994
|
+
["esnext.regexp", "lib.es2024.regexp.d.ts"],
|
|
35995
|
+
["esnext.string", "lib.es2024.string.d.ts"],
|
|
35926
35996
|
["esnext.iterator", "lib.esnext.iterator.d.ts"],
|
|
35927
35997
|
["decorators", "lib.decorators.d.ts"],
|
|
35928
35998
|
["decorators.legacy", "lib.decorators.legacy.d.ts"]
|
|
@@ -36221,6 +36291,7 @@ var targetOptionDeclaration = {
|
|
|
36221
36291
|
es2021: 8 /* ES2021 */,
|
|
36222
36292
|
es2022: 9 /* ES2022 */,
|
|
36223
36293
|
es2023: 10 /* ES2023 */,
|
|
36294
|
+
es2024: 11 /* ES2024 */,
|
|
36224
36295
|
esnext: 99 /* ESNext */
|
|
36225
36296
|
})),
|
|
36226
36297
|
affectsSourceFile: true,
|
|
@@ -48696,7 +48767,7 @@ function createTypeChecker(host) {
|
|
|
48696
48767
|
return isStringLiteralLike(moduleReferenceExpression) ? resolveExternalModule(location, moduleReferenceExpression.text, moduleNotFoundError, !ignoreErrors ? moduleReferenceExpression : void 0, isForAugmentation) : void 0;
|
|
48697
48768
|
}
|
|
48698
48769
|
function resolveExternalModule(location, moduleReference, moduleNotFoundError, errorNode, isForAugmentation = false) {
|
|
48699
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k
|
|
48770
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k;
|
|
48700
48771
|
if (errorNode && startsWith(moduleReference, "@types/")) {
|
|
48701
48772
|
const diag2 = Diagnostics.Cannot_import_type_declaration_files_Consider_importing_0_instead_of_1;
|
|
48702
48773
|
const withoutAtTypePrefix = removePrefix(moduleReference, "@types/");
|
|
@@ -48711,14 +48782,14 @@ function createTypeChecker(host) {
|
|
|
48711
48782
|
return ambientModule;
|
|
48712
48783
|
}
|
|
48713
48784
|
const currentSourceFile = getSourceFileOfNode(location);
|
|
48714
|
-
const contextSpecifier = isStringLiteralLike(location) ? location : ((_a = isModuleDeclaration(location) ? location : location.parent && isModuleDeclaration(location.parent) && location.parent.name === location ? location.parent : void 0) == null ? void 0 : _a.name) || ((_b = isLiteralImportTypeNode(location) ? location : void 0) == null ? void 0 : _b.argument.literal) || (
|
|
48785
|
+
const contextSpecifier = isStringLiteralLike(location) ? location : ((_a = isModuleDeclaration(location) ? location : location.parent && isModuleDeclaration(location.parent) && location.parent.name === location ? location.parent : void 0) == null ? void 0 : _a.name) || ((_b = isLiteralImportTypeNode(location) ? location : void 0) == null ? void 0 : _b.argument.literal) || (isVariableDeclaration(location) && location.initializer && isRequireCall(
|
|
48715
48786
|
location.initializer,
|
|
48716
48787
|
/*requireStringLiteralLikeArgument*/
|
|
48717
48788
|
true
|
|
48718
|
-
) ? location.initializer.arguments[0] : void 0) || ((_c = findAncestor(location, isImportCall)) == null ? void 0 : _c.arguments[0]) || ((_d = findAncestor(location, isImportDeclaration)) == null ? void 0 : _d.moduleSpecifier) || ((_e = findAncestor(location, isExternalModuleImportEqualsDeclaration)) == null ? void 0 : _e.moduleReference.expression)
|
|
48789
|
+
) ? location.initializer.arguments[0] : void 0) || ((_c = findAncestor(location, isImportCall)) == null ? void 0 : _c.arguments[0]) || ((_d = findAncestor(location, or(isImportDeclaration, isJSDocImportTag, isExportDeclaration))) == null ? void 0 : _d.moduleSpecifier) || ((_e = findAncestor(location, isExternalModuleImportEqualsDeclaration)) == null ? void 0 : _e.moduleReference.expression);
|
|
48719
48790
|
const mode = contextSpecifier && isStringLiteralLike(contextSpecifier) ? host.getModeForUsageLocation(currentSourceFile, contextSpecifier) : host.getDefaultResolutionModeForFile(currentSourceFile);
|
|
48720
48791
|
const moduleResolutionKind = getEmitModuleResolutionKind(compilerOptions);
|
|
48721
|
-
const resolvedModule = (
|
|
48792
|
+
const resolvedModule = (_f = host.getResolvedModule(currentSourceFile, moduleReference, mode)) == null ? void 0 : _f.resolvedModule;
|
|
48722
48793
|
const resolutionDiagnostic = errorNode && resolvedModule && getResolutionDiagnostic(compilerOptions, resolvedModule, currentSourceFile);
|
|
48723
48794
|
const sourceFile = resolvedModule && (!resolutionDiagnostic || resolutionDiagnostic === Diagnostics.Module_0_was_resolved_to_1_but_jsx_is_not_set) && host.getSourceFile(resolvedModule.resolvedFileName);
|
|
48724
48795
|
if (sourceFile) {
|
|
@@ -48726,7 +48797,7 @@ function createTypeChecker(host) {
|
|
|
48726
48797
|
error(errorNode, resolutionDiagnostic, moduleReference, resolvedModule.resolvedFileName);
|
|
48727
48798
|
}
|
|
48728
48799
|
if (resolvedModule.resolvedUsingTsExtension && isDeclarationFileName(moduleReference)) {
|
|
48729
|
-
const importOrExport = ((
|
|
48800
|
+
const importOrExport = ((_g = findAncestor(location, isImportDeclaration)) == null ? void 0 : _g.importClause) || findAncestor(location, or(isImportEqualsDeclaration, isExportDeclaration));
|
|
48730
48801
|
if (errorNode && importOrExport && !importOrExport.isTypeOnly || findAncestor(location, isImportCall)) {
|
|
48731
48802
|
error(
|
|
48732
48803
|
errorNode,
|
|
@@ -48735,7 +48806,7 @@ function createTypeChecker(host) {
|
|
|
48735
48806
|
);
|
|
48736
48807
|
}
|
|
48737
48808
|
} else if (resolvedModule.resolvedUsingTsExtension && !shouldAllowImportingTsExtension(compilerOptions, currentSourceFile.fileName)) {
|
|
48738
|
-
const importOrExport = ((
|
|
48809
|
+
const importOrExport = ((_h = findAncestor(location, isImportDeclaration)) == null ? void 0 : _h.importClause) || findAncestor(location, or(isImportEqualsDeclaration, isExportDeclaration));
|
|
48739
48810
|
if (errorNode && !((importOrExport == null ? void 0 : importOrExport.isTypeOnly) || findAncestor(location, isImportTypeNode))) {
|
|
48740
48811
|
const tsExtension = Debug.checkDefined(tryExtractTSExtension(moduleReference));
|
|
48741
48812
|
error(errorNode, Diagnostics.An_import_path_can_only_end_with_a_0_extension_when_allowImportingTsExtensions_is_enabled, tsExtension);
|
|
@@ -48765,7 +48836,7 @@ function createTypeChecker(host) {
|
|
|
48765
48836
|
if (ext === ".ts" /* Ts */ || ext === ".js" /* Js */ || ext === ".tsx" /* Tsx */ || ext === ".jsx" /* Jsx */) {
|
|
48766
48837
|
diagnosticDetails = createModeMismatchDetails(currentSourceFile);
|
|
48767
48838
|
}
|
|
48768
|
-
const message = (overrideHost == null ? void 0 : overrideHost.kind) === 272 /* ImportDeclaration */ && ((
|
|
48839
|
+
const message = (overrideHost == null ? void 0 : overrideHost.kind) === 272 /* ImportDeclaration */ && ((_i = overrideHost.importClause) == null ? void 0 : _i.isTypeOnly) ? Diagnostics.Type_only_import_of_an_ECMAScript_module_from_a_CommonJS_module_must_have_a_resolution_mode_attribute : (overrideHost == null ? void 0 : overrideHost.kind) === 205 /* ImportType */ ? Diagnostics.Type_import_of_an_ECMAScript_module_from_a_CommonJS_module_must_have_a_resolution_mode_attribute : Diagnostics.The_current_file_is_a_CommonJS_module_whose_imports_will_produce_require_calls_however_the_referenced_file_is_an_ECMAScript_module_and_cannot_be_imported_with_require_Consider_writing_a_dynamic_import_0_call_instead;
|
|
48769
48840
|
diagnostics.add(createDiagnosticForNodeFromMessageChain(
|
|
48770
48841
|
getSourceFileOfNode(errorNode),
|
|
48771
48842
|
errorNode,
|
|
@@ -48828,14 +48899,14 @@ function createTypeChecker(host) {
|
|
|
48828
48899
|
error(errorNode, Diagnostics.Cannot_find_module_0_Consider_using_resolveJsonModule_to_import_module_with_json_extension, moduleReference);
|
|
48829
48900
|
} else if (mode === 99 /* ESNext */ && resolutionIsNode16OrNext && isExtensionlessRelativePathImport) {
|
|
48830
48901
|
const absoluteRef = getNormalizedAbsolutePath(moduleReference, getDirectoryPath(currentSourceFile.path));
|
|
48831
|
-
const suggestedExt = (
|
|
48902
|
+
const suggestedExt = (_j = suggestedExtensions.find(([actualExt, _importExt]) => host.fileExists(absoluteRef + actualExt))) == null ? void 0 : _j[1];
|
|
48832
48903
|
if (suggestedExt) {
|
|
48833
48904
|
error(errorNode, Diagnostics.Relative_import_paths_need_explicit_file_extensions_in_ECMAScript_imports_when_moduleResolution_is_node16_or_nodenext_Did_you_mean_0, moduleReference + suggestedExt);
|
|
48834
48905
|
} else {
|
|
48835
48906
|
error(errorNode, Diagnostics.Relative_import_paths_need_explicit_file_extensions_in_ECMAScript_imports_when_moduleResolution_is_node16_or_nodenext_Consider_adding_an_extension_to_the_import_path);
|
|
48836
48907
|
}
|
|
48837
48908
|
} else {
|
|
48838
|
-
if ((
|
|
48909
|
+
if ((_k = host.getResolvedModule(currentSourceFile, moduleReference, mode)) == null ? void 0 : _k.alternateResult) {
|
|
48839
48910
|
const errorInfo = createModuleNotFoundChain(currentSourceFile, host, moduleReference, mode, moduleReference);
|
|
48840
48911
|
errorOrSuggestion(
|
|
48841
48912
|
/*isError*/
|
|
@@ -52034,7 +52105,13 @@ function createTypeChecker(host) {
|
|
|
52034
52105
|
if (typeFromTypeNode === type) {
|
|
52035
52106
|
return true;
|
|
52036
52107
|
}
|
|
52037
|
-
if (annotatedDeclaration
|
|
52108
|
+
if (!annotatedDeclaration) {
|
|
52109
|
+
return false;
|
|
52110
|
+
}
|
|
52111
|
+
if ((isPropertySignature(annotatedDeclaration) || isPropertyDeclaration(annotatedDeclaration)) && annotatedDeclaration.questionToken) {
|
|
52112
|
+
return getTypeWithFacts(type, 524288 /* NEUndefined */) === typeFromTypeNode;
|
|
52113
|
+
}
|
|
52114
|
+
if (isParameter(annotatedDeclaration) && hasEffectiveQuestionToken(annotatedDeclaration)) {
|
|
52038
52115
|
return getTypeWithFacts(type, 524288 /* NEUndefined */) === typeFromTypeNode;
|
|
52039
52116
|
}
|
|
52040
52117
|
return false;
|
|
@@ -52995,7 +53072,9 @@ function createTypeChecker(host) {
|
|
|
52995
53072
|
const skipMembershipCheck = !isPrivate;
|
|
52996
53073
|
if (skipMembershipCheck || !!length(symbol.declarations) && some(symbol.declarations, (d) => !!findAncestor(d, (n) => n === enclosingDeclaration))) {
|
|
52997
53074
|
const scopeCleanup = cloneNodeBuilderContext(context);
|
|
53075
|
+
context.tracker.pushErrorFallbackNode(find(symbol.declarations, (d) => getSourceFileOfNode(d) === context.enclosingFile));
|
|
52998
53076
|
serializeSymbolWorker(symbol, isPrivate, propertyAsAlias);
|
|
53077
|
+
context.tracker.popErrorFallbackNode();
|
|
52999
53078
|
scopeCleanup();
|
|
53000
53079
|
}
|
|
53001
53080
|
}
|
|
@@ -56998,8 +57077,13 @@ function createTypeChecker(host) {
|
|
|
56998
57077
|
if (left.typeParameters && right.typeParameters) {
|
|
56999
57078
|
paramMapper = createTypeMapper(right.typeParameters, left.typeParameters);
|
|
57000
57079
|
}
|
|
57080
|
+
let flags = (left.flags | right.flags) & (167 /* PropagatingFlags */ & ~1 /* HasRestParameter */);
|
|
57001
57081
|
const declaration = left.declaration;
|
|
57002
57082
|
const params = combineUnionParameters(left, right, paramMapper);
|
|
57083
|
+
const lastParam = lastOrUndefined(params);
|
|
57084
|
+
if (lastParam && getCheckFlags(lastParam) & 32768 /* RestParameter */) {
|
|
57085
|
+
flags |= 1 /* HasRestParameter */;
|
|
57086
|
+
}
|
|
57003
57087
|
const thisParam = combineUnionThisParam(left.thisParameter, right.thisParameter, paramMapper);
|
|
57004
57088
|
const minArgCount = Math.max(left.minArgumentCount, right.minArgumentCount);
|
|
57005
57089
|
const result = createSignature(
|
|
@@ -57012,7 +57096,7 @@ function createTypeChecker(host) {
|
|
|
57012
57096
|
/*resolvedTypePredicate*/
|
|
57013
57097
|
void 0,
|
|
57014
57098
|
minArgCount,
|
|
57015
|
-
|
|
57099
|
+
flags
|
|
57016
57100
|
);
|
|
57017
57101
|
result.compositeKind = 1048576 /* Union */;
|
|
57018
57102
|
result.compositeSignatures = concatenate(left.compositeKind !== 2097152 /* Intersection */ && left.compositeSignatures || [left], [right]);
|
|
@@ -72445,13 +72529,14 @@ function createTypeChecker(host) {
|
|
|
72445
72529
|
const paramName = leftName === rightName ? leftName : !leftName ? rightName : !rightName ? leftName : void 0;
|
|
72446
72530
|
const paramSymbol = createSymbol(
|
|
72447
72531
|
1 /* FunctionScopedVariable */ | (isOptional && !isRestParam ? 16777216 /* Optional */ : 0),
|
|
72448
|
-
paramName || `arg${i}
|
|
72532
|
+
paramName || `arg${i}`,
|
|
72533
|
+
isRestParam ? 32768 /* RestParameter */ : isOptional ? 16384 /* OptionalParameter */ : 0
|
|
72449
72534
|
);
|
|
72450
72535
|
paramSymbol.links.type = isRestParam ? createArrayType(unionParamType) : unionParamType;
|
|
72451
72536
|
params[i] = paramSymbol;
|
|
72452
72537
|
}
|
|
72453
72538
|
if (needsExtraRestElement) {
|
|
72454
|
-
const restParamSymbol = createSymbol(1 /* FunctionScopedVariable */, "args");
|
|
72539
|
+
const restParamSymbol = createSymbol(1 /* FunctionScopedVariable */, "args", 32768 /* RestParameter */);
|
|
72455
72540
|
restParamSymbol.links.type = createArrayType(getTypeAtPosition(shorter, longestCount));
|
|
72456
72541
|
if (shorter === right) {
|
|
72457
72542
|
restParamSymbol.links.type = instantiateType(restParamSymbol.links.type, mapper);
|
|
@@ -72466,8 +72551,13 @@ function createTypeChecker(host) {
|
|
|
72466
72551
|
if (left.typeParameters && right.typeParameters) {
|
|
72467
72552
|
paramMapper = createTypeMapper(right.typeParameters, left.typeParameters);
|
|
72468
72553
|
}
|
|
72554
|
+
let flags = (left.flags | right.flags) & (167 /* PropagatingFlags */ & ~1 /* HasRestParameter */);
|
|
72469
72555
|
const declaration = left.declaration;
|
|
72470
72556
|
const params = combineIntersectionParameters(left, right, paramMapper);
|
|
72557
|
+
const lastParam = lastOrUndefined(params);
|
|
72558
|
+
if (lastParam && getCheckFlags(lastParam) & 32768 /* RestParameter */) {
|
|
72559
|
+
flags |= 1 /* HasRestParameter */;
|
|
72560
|
+
}
|
|
72471
72561
|
const thisParam = combineIntersectionThisParam(left.thisParameter, right.thisParameter, paramMapper);
|
|
72472
72562
|
const minArgCount = Math.max(left.minArgumentCount, right.minArgumentCount);
|
|
72473
72563
|
const result = createSignature(
|
|
@@ -72480,7 +72570,7 @@ function createTypeChecker(host) {
|
|
|
72480
72570
|
/*resolvedTypePredicate*/
|
|
72481
72571
|
void 0,
|
|
72482
72572
|
minArgCount,
|
|
72483
|
-
|
|
72573
|
+
flags
|
|
72484
72574
|
);
|
|
72485
72575
|
result.compositeKind = 2097152 /* Intersection */;
|
|
72486
72576
|
result.compositeSignatures = concatenate(left.compositeKind === 2097152 /* Intersection */ && left.compositeSignatures || [left], [right]);
|
|
@@ -79191,8 +79281,7 @@ function createTypeChecker(host) {
|
|
|
79191
79281
|
void 0,
|
|
79192
79282
|
checkMode || 0 /* Normal */
|
|
79193
79283
|
) : checkExpressionCached(initializer, checkMode));
|
|
79194
|
-
|
|
79195
|
-
if (isParameter(rootDeclaration) && !getEffectiveTypeAnnotationNode(rootDeclaration) && (!isFunctionLikeDeclaration(rootDeclaration.parent) || !getContextualSignatureForFunctionLikeDeclaration(rootDeclaration.parent))) {
|
|
79284
|
+
if (isParameter(isBindingElement(declaration) ? walkUpBindingElementsAndPatterns(declaration) : declaration)) {
|
|
79196
79285
|
if (declaration.name.kind === 206 /* ObjectBindingPattern */ && isObjectLiteralType(type)) {
|
|
79197
79286
|
return padObjectLiteralType(type, declaration.name);
|
|
79198
79287
|
}
|
|
@@ -88996,6 +89085,14 @@ var SymbolTrackerImpl = class _SymbolTrackerImpl {
|
|
|
88996
89085
|
this.inner.reportInferenceFallback(node);
|
|
88997
89086
|
}
|
|
88998
89087
|
}
|
|
89088
|
+
pushErrorFallbackNode(node) {
|
|
89089
|
+
var _a, _b;
|
|
89090
|
+
return (_b = (_a = this.inner) == null ? void 0 : _a.pushErrorFallbackNode) == null ? void 0 : _b.call(_a, node);
|
|
89091
|
+
}
|
|
89092
|
+
popErrorFallbackNode() {
|
|
89093
|
+
var _a, _b;
|
|
89094
|
+
return (_b = (_a = this.inner) == null ? void 0 : _a.popErrorFallbackNode) == null ? void 0 : _b.call(_a);
|
|
89095
|
+
}
|
|
88999
89096
|
};
|
|
89000
89097
|
|
|
89001
89098
|
// src/compiler/visitorPublic.ts
|
|
@@ -112152,6 +112249,7 @@ function transformDeclarations(context) {
|
|
|
112152
112249
|
let suppressNewDiagnosticContexts;
|
|
112153
112250
|
const { factory: factory2 } = context;
|
|
112154
112251
|
const host = context.getEmitHost();
|
|
112252
|
+
let restoreFallbackNode = () => void 0;
|
|
112155
112253
|
const symbolTracker = {
|
|
112156
112254
|
trackSymbol,
|
|
112157
112255
|
reportInaccessibleThisError,
|
|
@@ -112163,7 +112261,19 @@ function transformDeclarations(context) {
|
|
|
112163
112261
|
moduleResolverHost: host,
|
|
112164
112262
|
reportNonlocalAugmentation,
|
|
112165
112263
|
reportNonSerializableProperty,
|
|
112166
|
-
reportInferenceFallback
|
|
112264
|
+
reportInferenceFallback,
|
|
112265
|
+
pushErrorFallbackNode(node) {
|
|
112266
|
+
const currentFallback = errorFallbackNode;
|
|
112267
|
+
const currentRestore = restoreFallbackNode;
|
|
112268
|
+
restoreFallbackNode = () => {
|
|
112269
|
+
restoreFallbackNode = currentRestore;
|
|
112270
|
+
errorFallbackNode = currentFallback;
|
|
112271
|
+
};
|
|
112272
|
+
errorFallbackNode = node;
|
|
112273
|
+
},
|
|
112274
|
+
popErrorFallbackNode() {
|
|
112275
|
+
restoreFallbackNode();
|
|
112276
|
+
}
|
|
112167
112277
|
};
|
|
112168
112278
|
let errorNameNode;
|
|
112169
112279
|
let errorFallbackNode;
|
package/lib/typescript.d.ts
CHANGED
|
@@ -2526,6 +2526,7 @@ declare namespace ts {
|
|
|
2526
2526
|
ES2021 = "es2021",
|
|
2527
2527
|
ES2022 = "es2022",
|
|
2528
2528
|
ES2023 = "es2023",
|
|
2529
|
+
ES2024 = "es2024",
|
|
2529
2530
|
ESNext = "esnext",
|
|
2530
2531
|
JSON = "json",
|
|
2531
2532
|
Latest = "esnext",
|
|
@@ -7156,6 +7157,7 @@ declare namespace ts {
|
|
|
7156
7157
|
ES2021 = 8,
|
|
7157
7158
|
ES2022 = 9,
|
|
7158
7159
|
ES2023 = 10,
|
|
7160
|
+
ES2024 = 11,
|
|
7159
7161
|
ESNext = 99,
|
|
7160
7162
|
JSON = 100,
|
|
7161
7163
|
Latest = 99,
|