@typescript-deploys/pr-build 5.0.0-pr-51157-8 → 5.0.0-pr-51474-2
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 +321 -361
- package/lib/tsserver.js +499 -532
- package/lib/tsserverlibrary.d.ts +10 -71
- package/lib/tsserverlibrary.js +3020 -543
- package/lib/typescript.d.ts +6 -65
- package/lib/typescript.js +2944 -467
- package/lib/typingsInstaller.js +57 -82
- package/package.json +6 -5
package/lib/tsserver.js
CHANGED
|
@@ -117,7 +117,6 @@ var ts = (() => {
|
|
|
117
117
|
LexicalEnvironmentFlags: () => LexicalEnvironmentFlags,
|
|
118
118
|
ListFormat: () => ListFormat,
|
|
119
119
|
LogLevel: () => LogLevel,
|
|
120
|
-
Map: () => Map,
|
|
121
120
|
MemberOverrideStatus: () => MemberOverrideStatus,
|
|
122
121
|
ModifierFlags: () => ModifierFlags,
|
|
123
122
|
ModuleDetectionKind: () => ModuleDetectionKind,
|
|
@@ -160,7 +159,6 @@ var ts = (() => {
|
|
|
160
159
|
SemanticClassificationFormat: () => SemanticClassificationFormat,
|
|
161
160
|
SemanticMeaning: () => SemanticMeaning,
|
|
162
161
|
SemicolonPreference: () => SemicolonPreference,
|
|
163
|
-
Set: () => Set,
|
|
164
162
|
SignatureCheckMode: () => SignatureCheckMode,
|
|
165
163
|
SignatureFlags: () => SignatureFlags,
|
|
166
164
|
SignatureHelp: () => ts_SignatureHelp_exports,
|
|
@@ -2649,37 +2647,13 @@ var ts = (() => {
|
|
|
2649
2647
|
|
|
2650
2648
|
// src/compiler/corePublic.ts
|
|
2651
2649
|
var versionMajorMinor = "5.0";
|
|
2652
|
-
var version = `${versionMajorMinor}.0-insiders.
|
|
2650
|
+
var version = `${versionMajorMinor}.0-insiders.20221110`;
|
|
2653
2651
|
var Comparison = /* @__PURE__ */ ((Comparison3) => {
|
|
2654
2652
|
Comparison3[Comparison3["LessThan"] = -1] = "LessThan";
|
|
2655
2653
|
Comparison3[Comparison3["EqualTo"] = 0] = "EqualTo";
|
|
2656
2654
|
Comparison3[Comparison3["GreaterThan"] = 1] = "GreaterThan";
|
|
2657
2655
|
return Comparison3;
|
|
2658
2656
|
})(Comparison || {});
|
|
2659
|
-
var NativeCollections;
|
|
2660
|
-
((NativeCollections2) => {
|
|
2661
|
-
const globals = typeof globalThis !== "undefined" ? globalThis : typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : void 0;
|
|
2662
|
-
function tryGetNativeMap() {
|
|
2663
|
-
const gMap = globals == null ? void 0 : globals.Map;
|
|
2664
|
-
const constructor = typeof gMap !== "undefined" && "entries" in gMap.prototype && new gMap([[0, 0]]).size === 1 ? gMap : void 0;
|
|
2665
|
-
if (!constructor) {
|
|
2666
|
-
throw new Error("No compatible Map implementation found.");
|
|
2667
|
-
}
|
|
2668
|
-
return constructor;
|
|
2669
|
-
}
|
|
2670
|
-
NativeCollections2.tryGetNativeMap = tryGetNativeMap;
|
|
2671
|
-
function tryGetNativeSet() {
|
|
2672
|
-
const gSet = globals == null ? void 0 : globals.Set;
|
|
2673
|
-
const constructor = typeof gSet !== "undefined" && "entries" in gSet.prototype && new gSet([0]).size === 1 ? gSet : void 0;
|
|
2674
|
-
if (!constructor) {
|
|
2675
|
-
throw new Error("No compatible Set implementation found.");
|
|
2676
|
-
}
|
|
2677
|
-
return constructor;
|
|
2678
|
-
}
|
|
2679
|
-
NativeCollections2.tryGetNativeSet = tryGetNativeSet;
|
|
2680
|
-
})(NativeCollections || (NativeCollections = {}));
|
|
2681
|
-
var Map = NativeCollections.tryGetNativeMap();
|
|
2682
|
-
var Set = NativeCollections.tryGetNativeSet();
|
|
2683
2657
|
|
|
2684
2658
|
// src/compiler/core.ts
|
|
2685
2659
|
function getIterator(iterable) {
|
|
@@ -2694,8 +2668,8 @@ var ts = (() => {
|
|
|
2694
2668
|
}
|
|
2695
2669
|
}
|
|
2696
2670
|
var emptyArray = [];
|
|
2697
|
-
var emptyMap = new Map();
|
|
2698
|
-
var emptySet = new Set();
|
|
2671
|
+
var emptyMap = /* @__PURE__ */ new Map();
|
|
2672
|
+
var emptySet = /* @__PURE__ */ new Set();
|
|
2699
2673
|
function length(array) {
|
|
2700
2674
|
return array ? array.length : 0;
|
|
2701
2675
|
}
|
|
@@ -2777,7 +2751,7 @@ var ts = (() => {
|
|
|
2777
2751
|
}
|
|
2778
2752
|
function zipToMap(keys, values) {
|
|
2779
2753
|
Debug.assert(keys.length === values.length);
|
|
2780
|
-
const map2 = new Map();
|
|
2754
|
+
const map2 = /* @__PURE__ */ new Map();
|
|
2781
2755
|
for (let i = 0; i < keys.length; ++i) {
|
|
2782
2756
|
map2.set(keys[i], values[i]);
|
|
2783
2757
|
}
|
|
@@ -3092,7 +3066,7 @@ var ts = (() => {
|
|
|
3092
3066
|
if (!map2) {
|
|
3093
3067
|
return void 0;
|
|
3094
3068
|
}
|
|
3095
|
-
const result = new Map();
|
|
3069
|
+
const result = /* @__PURE__ */ new Map();
|
|
3096
3070
|
map2.forEach((value, key) => {
|
|
3097
3071
|
const entry = f(key, value);
|
|
3098
3072
|
if (entry !== void 0) {
|
|
@@ -3106,7 +3080,7 @@ var ts = (() => {
|
|
|
3106
3080
|
}
|
|
3107
3081
|
function mapDefinedValues(set, f) {
|
|
3108
3082
|
if (set) {
|
|
3109
|
-
const result = new Set();
|
|
3083
|
+
const result = /* @__PURE__ */ new Set();
|
|
3110
3084
|
set.forEach((value) => {
|
|
3111
3085
|
const newValue = f(value);
|
|
3112
3086
|
if (newValue !== void 0) {
|
|
@@ -3179,7 +3153,7 @@ var ts = (() => {
|
|
|
3179
3153
|
if (!map2) {
|
|
3180
3154
|
return void 0;
|
|
3181
3155
|
}
|
|
3182
|
-
const result = new Map();
|
|
3156
|
+
const result = /* @__PURE__ */ new Map();
|
|
3183
3157
|
map2.forEach((value, key) => {
|
|
3184
3158
|
const [newKey, newValue] = f(key, value);
|
|
3185
3159
|
result.set(newKey, newValue);
|
|
@@ -3645,7 +3619,7 @@ var ts = (() => {
|
|
|
3645
3619
|
return true;
|
|
3646
3620
|
}
|
|
3647
3621
|
function arrayToMap(array, makeKey, makeValue = identity) {
|
|
3648
|
-
const result = new Map();
|
|
3622
|
+
const result = /* @__PURE__ */ new Map();
|
|
3649
3623
|
for (const value of array) {
|
|
3650
3624
|
const key = makeKey(value);
|
|
3651
3625
|
if (key !== void 0)
|
|
@@ -3704,7 +3678,7 @@ var ts = (() => {
|
|
|
3704
3678
|
return fn ? fn.bind(obj) : void 0;
|
|
3705
3679
|
}
|
|
3706
3680
|
function createMultiMap() {
|
|
3707
|
-
const map2 = new Map();
|
|
3681
|
+
const map2 = /* @__PURE__ */ new Map();
|
|
3708
3682
|
map2.add = multiMapAdd;
|
|
3709
3683
|
map2.remove = multiMapRemove;
|
|
3710
3684
|
return map2;
|
|
@@ -3761,12 +3735,12 @@ var ts = (() => {
|
|
|
3761
3735
|
};
|
|
3762
3736
|
}
|
|
3763
3737
|
function createSet(getHashCode, equals) {
|
|
3764
|
-
const multiMap = new Map();
|
|
3738
|
+
const multiMap = /* @__PURE__ */ new Map();
|
|
3765
3739
|
let size = 0;
|
|
3766
3740
|
function getElementIterator() {
|
|
3767
3741
|
const valueIt = multiMap.values();
|
|
3768
3742
|
let arrayIt;
|
|
3769
|
-
|
|
3743
|
+
const it = {
|
|
3770
3744
|
next: () => {
|
|
3771
3745
|
while (true) {
|
|
3772
3746
|
if (arrayIt) {
|
|
@@ -3786,8 +3760,12 @@ var ts = (() => {
|
|
|
3786
3760
|
arrayIt = arrayIterator(n.value);
|
|
3787
3761
|
}
|
|
3788
3762
|
}
|
|
3763
|
+
},
|
|
3764
|
+
[Symbol.iterator]: () => {
|
|
3765
|
+
return it;
|
|
3789
3766
|
}
|
|
3790
3767
|
};
|
|
3768
|
+
return it;
|
|
3791
3769
|
}
|
|
3792
3770
|
const set = {
|
|
3793
3771
|
has(element) {
|
|
@@ -3866,11 +3844,11 @@ var ts = (() => {
|
|
|
3866
3844
|
for (const elements of arrayFrom(multiMap.values())) {
|
|
3867
3845
|
if (isArray(elements)) {
|
|
3868
3846
|
for (const element of elements) {
|
|
3869
|
-
action(element, element);
|
|
3847
|
+
action(element, element, set);
|
|
3870
3848
|
}
|
|
3871
3849
|
} else {
|
|
3872
3850
|
const element = elements;
|
|
3873
|
-
action(element, element);
|
|
3851
|
+
action(element, element, set);
|
|
3874
3852
|
}
|
|
3875
3853
|
}
|
|
3876
3854
|
},
|
|
@@ -3882,13 +3860,19 @@ var ts = (() => {
|
|
|
3882
3860
|
},
|
|
3883
3861
|
entries() {
|
|
3884
3862
|
const it = getElementIterator();
|
|
3885
|
-
|
|
3863
|
+
const it2 = {
|
|
3886
3864
|
next: () => {
|
|
3887
3865
|
const n = it.next();
|
|
3888
3866
|
return n.done ? n : { value: [n.value, n.value] };
|
|
3889
|
-
}
|
|
3867
|
+
},
|
|
3868
|
+
[Symbol.iterator]: () => it2
|
|
3890
3869
|
};
|
|
3891
|
-
|
|
3870
|
+
return it2;
|
|
3871
|
+
},
|
|
3872
|
+
[Symbol.iterator]: () => {
|
|
3873
|
+
return getElementIterator();
|
|
3874
|
+
},
|
|
3875
|
+
[Symbol.toStringTag]: multiMap[Symbol.toStringTag]
|
|
3892
3876
|
};
|
|
3893
3877
|
return set;
|
|
3894
3878
|
}
|
|
@@ -3951,7 +3935,7 @@ var ts = (() => {
|
|
|
3951
3935
|
};
|
|
3952
3936
|
}
|
|
3953
3937
|
function memoizeOne(callback) {
|
|
3954
|
-
const map2 = new Map();
|
|
3938
|
+
const map2 = /* @__PURE__ */ new Map();
|
|
3955
3939
|
return (arg) => {
|
|
3956
3940
|
const key = `${typeof arg}:${arg}`;
|
|
3957
3941
|
let value = map2.get(key);
|
|
@@ -4663,7 +4647,7 @@ Node ${formatSyntaxKind(node.kind)} was unexpected.`,
|
|
|
4663
4647
|
return value.toString();
|
|
4664
4648
|
}
|
|
4665
4649
|
Debug2.formatEnum = formatEnum;
|
|
4666
|
-
const enumMemberCache = new Map();
|
|
4650
|
+
const enumMemberCache = /* @__PURE__ */ new Map();
|
|
4667
4651
|
function getEnumMembers(enumObject) {
|
|
4668
4652
|
const existing = enumMemberCache.get(enumObject);
|
|
4669
4653
|
if (existing) {
|
|
@@ -5069,7 +5053,7 @@ m2: ${this.mapper2.__debugToString().split("\n").join("\n ")}`;
|
|
|
5069
5053
|
const links = /* @__PURE__ */ Object.create(null);
|
|
5070
5054
|
const nodes = [];
|
|
5071
5055
|
const edges = [];
|
|
5072
|
-
const root = buildGraphNode(flowNode, new Set());
|
|
5056
|
+
const root = buildGraphNode(flowNode, /* @__PURE__ */ new Set());
|
|
5073
5057
|
for (const node of nodes) {
|
|
5074
5058
|
node.text = renderFlowNode(node.flowNode, node.circular);
|
|
5075
5059
|
computeLevel(node);
|
|
@@ -5812,9 +5796,9 @@ ${lanes.join("\n")}
|
|
|
5812
5796
|
var nullTimer = { enter: noop, exit: noop };
|
|
5813
5797
|
var enabled = false;
|
|
5814
5798
|
var timeorigin = timestamp();
|
|
5815
|
-
var marks = new Map();
|
|
5816
|
-
var counts = new Map();
|
|
5817
|
-
var durations = new Map();
|
|
5799
|
+
var marks = /* @__PURE__ */ new Map();
|
|
5800
|
+
var counts = /* @__PURE__ */ new Map();
|
|
5801
|
+
var durations = /* @__PURE__ */ new Map();
|
|
5818
5802
|
function mark(markName) {
|
|
5819
5803
|
var _a2;
|
|
5820
5804
|
if (enabled) {
|
|
@@ -6040,7 +6024,7 @@ ${lanes.join("\n")}
|
|
|
6040
6024
|
mark("beginDumpTypes");
|
|
6041
6025
|
const typesPath = legend[legend.length - 1].typesPath;
|
|
6042
6026
|
const typesFd = fs.openSync(typesPath, "w");
|
|
6043
|
-
const recursionIdentityMap = new Map();
|
|
6027
|
+
const recursionIdentityMap = /* @__PURE__ */ new Map();
|
|
6044
6028
|
fs.writeSync(typesFd, "[");
|
|
6045
6029
|
const numTypes = types.length;
|
|
6046
6030
|
for (let i = 0; i < numTypes; i++) {
|
|
@@ -8027,7 +8011,7 @@ ${lanes.join("\n")}
|
|
|
8027
8011
|
}
|
|
8028
8012
|
function createUseFsEventsOnParentDirectoryWatchFile(fsWatch, useCaseSensitiveFileNames) {
|
|
8029
8013
|
const fileWatcherCallbacks = createMultiMap();
|
|
8030
|
-
const dirWatchers = new Map();
|
|
8014
|
+
const dirWatchers = /* @__PURE__ */ new Map();
|
|
8031
8015
|
const toCanonicalName = createGetCanonicalFileName(useCaseSensitiveFileNames);
|
|
8032
8016
|
return nonPollingWatchFile;
|
|
8033
8017
|
function nonPollingWatchFile(fileName, callback, _pollingInterval, fallbackOptions) {
|
|
@@ -8161,9 +8145,9 @@ ${lanes.join("\n")}
|
|
|
8161
8145
|
setTimeout: setTimeout2,
|
|
8162
8146
|
clearTimeout: clearTimeout2
|
|
8163
8147
|
}) {
|
|
8164
|
-
const cache = new Map();
|
|
8148
|
+
const cache = /* @__PURE__ */ new Map();
|
|
8165
8149
|
const callbackCache = createMultiMap();
|
|
8166
|
-
const cacheToUpdateChildWatches = new Map();
|
|
8150
|
+
const cacheToUpdateChildWatches = /* @__PURE__ */ new Map();
|
|
8167
8151
|
let timerToUpdateChildWatches;
|
|
8168
8152
|
const filePathComparer = getStringComparer(!useCaseSensitiveFileNames);
|
|
8169
8153
|
const toCanonicalFilePath = createGetCanonicalFileName(useCaseSensitiveFileNames);
|
|
@@ -8265,7 +8249,7 @@ ${lanes.join("\n")}
|
|
|
8265
8249
|
timerToUpdateChildWatches = void 0;
|
|
8266
8250
|
sysLog(`sysLog:: onTimerToUpdateChildWatches:: ${cacheToUpdateChildWatches.size}`);
|
|
8267
8251
|
const start2 = timestamp();
|
|
8268
|
-
const invokeMap = new Map();
|
|
8252
|
+
const invokeMap = /* @__PURE__ */ new Map();
|
|
8269
8253
|
while (!timerToUpdateChildWatches && cacheToUpdateChildWatches.size) {
|
|
8270
8254
|
const result = cacheToUpdateChildWatches.entries().next();
|
|
8271
8255
|
Debug.assert(!result.done);
|
|
@@ -8386,9 +8370,9 @@ ${lanes.join("\n")}
|
|
|
8386
8370
|
inodeWatching,
|
|
8387
8371
|
sysLog: sysLog2
|
|
8388
8372
|
}) {
|
|
8389
|
-
const pollingWatches = new Map();
|
|
8390
|
-
const fsWatches = new Map();
|
|
8391
|
-
const fsWatchesRecursive = new Map();
|
|
8373
|
+
const pollingWatches = /* @__PURE__ */ new Map();
|
|
8374
|
+
const fsWatches = /* @__PURE__ */ new Map();
|
|
8375
|
+
const fsWatchesRecursive = /* @__PURE__ */ new Map();
|
|
8392
8376
|
let dynamicPollingWatchFile;
|
|
8393
8377
|
let fixedChunkSizePollingWatchFile;
|
|
8394
8378
|
let nonPollingWatchFile;
|
|
@@ -8842,7 +8826,7 @@ ${lanes.join("\n")}
|
|
|
8842
8826
|
}
|
|
8843
8827
|
function cleanupPaths(profile) {
|
|
8844
8828
|
let externalFileCounter = 0;
|
|
8845
|
-
const remappedPaths = new Map();
|
|
8829
|
+
const remappedPaths = /* @__PURE__ */ new Map();
|
|
8846
8830
|
const normalizedDir = normalizeSlashes(_path.dirname(executingFilePath));
|
|
8847
8831
|
const fileUrlRoot = `file://${getRootLength(normalizedDir) === 1 ? "" : "/"}${normalizedDir}`;
|
|
8848
8832
|
for (const node of profile.nodes) {
|
|
@@ -14715,7 +14699,7 @@ ${lanes.join("\n")}
|
|
|
14715
14699
|
return filter(symbol.declarations || emptyArray, (d) => d.kind === kind);
|
|
14716
14700
|
}
|
|
14717
14701
|
function createSymbolTable(symbols) {
|
|
14718
|
-
const result = new Map();
|
|
14702
|
+
const result = /* @__PURE__ */ new Map();
|
|
14719
14703
|
if (symbols) {
|
|
14720
14704
|
for (const symbol of symbols) {
|
|
14721
14705
|
result.set(symbol.escapedName, symbol);
|
|
@@ -15007,7 +14991,7 @@ ${lanes.join("\n")}
|
|
|
15007
14991
|
commentDirective
|
|
15008
14992
|
])
|
|
15009
14993
|
);
|
|
15010
|
-
const usedLines = new Map();
|
|
14994
|
+
const usedLines = /* @__PURE__ */ new Map();
|
|
15011
14995
|
return { getUnusedExpectations, markUsed };
|
|
15012
14996
|
function getUnusedExpectations() {
|
|
15013
14997
|
return arrayFrom(directivesByLine.entries()).filter(([line, directive]) => directive.type === 0 /* ExpectError */ && !usedLines.get(line)).map(([_, directive]) => directive);
|
|
@@ -17444,7 +17428,7 @@ ${lanes.join("\n")}
|
|
|
17444
17428
|
function createDiagnosticCollection() {
|
|
17445
17429
|
let nonFileDiagnostics = [];
|
|
17446
17430
|
const filesWithDiagnostics = [];
|
|
17447
|
-
const fileDiagnostics = new Map();
|
|
17431
|
+
const fileDiagnostics = /* @__PURE__ */ new Map();
|
|
17448
17432
|
let hasReadNonFileDiagnostics = false;
|
|
17449
17433
|
return {
|
|
17450
17434
|
add,
|
|
@@ -19313,7 +19297,7 @@ ${lanes.join("\n")}
|
|
|
19313
19297
|
getSymlinkedFiles: () => symlinkedFiles,
|
|
19314
19298
|
getSymlinkedDirectories: () => symlinkedDirectories,
|
|
19315
19299
|
getSymlinkedDirectoriesByRealpath: () => symlinkedDirectoriesByRealpath,
|
|
19316
|
-
setSymlinkedFile: (path, real) => (symlinkedFiles || (symlinkedFiles = new Map())).set(path, real),
|
|
19300
|
+
setSymlinkedFile: (path, real) => (symlinkedFiles || (symlinkedFiles = /* @__PURE__ */ new Map())).set(path, real),
|
|
19317
19301
|
setSymlinkedDirectory: (symlink, real) => {
|
|
19318
19302
|
let symlinkPath = toPath(symlink, cwd, getCanonicalFileName);
|
|
19319
19303
|
if (!containsIgnoredPath(symlinkPath)) {
|
|
@@ -19321,7 +19305,7 @@ ${lanes.join("\n")}
|
|
|
19321
19305
|
if (real !== false && !(symlinkedDirectories == null ? void 0 : symlinkedDirectories.has(symlinkPath))) {
|
|
19322
19306
|
(symlinkedDirectoriesByRealpath || (symlinkedDirectoriesByRealpath = createMultiMap())).add(ensureTrailingDirectorySeparator(real.realPath), symlink);
|
|
19323
19307
|
}
|
|
19324
|
-
(symlinkedDirectories || (symlinkedDirectories = new Map())).set(symlinkPath, real);
|
|
19308
|
+
(symlinkedDirectories || (symlinkedDirectories = /* @__PURE__ */ new Map())).set(symlinkPath, real);
|
|
19325
19309
|
}
|
|
19326
19310
|
},
|
|
19327
19311
|
setSymlinksFromResolutions(files, typeReferenceDirectives) {
|
|
@@ -19498,7 +19482,7 @@ ${lanes.join("\n")}
|
|
|
19498
19482
|
const includeDirectoryRegex = patterns.includeDirectoryPattern && getRegexFromPattern(patterns.includeDirectoryPattern, useCaseSensitiveFileNames);
|
|
19499
19483
|
const excludeRegex = patterns.excludePattern && getRegexFromPattern(patterns.excludePattern, useCaseSensitiveFileNames);
|
|
19500
19484
|
const results = includeFileRegexes ? includeFileRegexes.map(() => []) : [[]];
|
|
19501
|
-
const visited = new Map();
|
|
19485
|
+
const visited = /* @__PURE__ */ new Map();
|
|
19502
19486
|
const toCanonical = createGetCanonicalFileName(useCaseSensitiveFileNames);
|
|
19503
19487
|
for (const basePath of patterns.basePaths) {
|
|
19504
19488
|
visitDirectory(basePath, combinePaths(currentDirectory, basePath), depth);
|
|
@@ -20218,7 +20202,7 @@ ${lanes.join("\n")}
|
|
|
20218
20202
|
parenthesizeLeadingTypeArgument
|
|
20219
20203
|
};
|
|
20220
20204
|
function getParenthesizeLeftSideOfBinaryForOperator(operatorKind) {
|
|
20221
|
-
binaryLeftOperandParenthesizerCache || (binaryLeftOperandParenthesizerCache = new Map());
|
|
20205
|
+
binaryLeftOperandParenthesizerCache || (binaryLeftOperandParenthesizerCache = /* @__PURE__ */ new Map());
|
|
20222
20206
|
let parenthesizerRule = binaryLeftOperandParenthesizerCache.get(operatorKind);
|
|
20223
20207
|
if (!parenthesizerRule) {
|
|
20224
20208
|
parenthesizerRule = (node) => parenthesizeLeftSideOfBinary(operatorKind, node);
|
|
@@ -20227,7 +20211,7 @@ ${lanes.join("\n")}
|
|
|
20227
20211
|
return parenthesizerRule;
|
|
20228
20212
|
}
|
|
20229
20213
|
function getParenthesizeRightSideOfBinaryForOperator(operatorKind) {
|
|
20230
|
-
binaryRightOperandParenthesizerCache || (binaryRightOperandParenthesizerCache = new Map());
|
|
20214
|
+
binaryRightOperandParenthesizerCache || (binaryRightOperandParenthesizerCache = /* @__PURE__ */ new Map());
|
|
20231
20215
|
let parenthesizerRule = binaryRightOperandParenthesizerCache.get(operatorKind);
|
|
20232
20216
|
if (!parenthesizerRule) {
|
|
20233
20217
|
parenthesizerRule = (node) => parenthesizeRightSideOfBinary(operatorKind, void 0, node);
|
|
@@ -24522,7 +24506,7 @@ ${lanes.join("\n")}
|
|
|
24522
24506
|
if (leftStandardPrologueEnd === 0) {
|
|
24523
24507
|
left.splice(0, 0, ...declarations.slice(0, rightStandardPrologueEnd));
|
|
24524
24508
|
} else {
|
|
24525
|
-
const leftPrologues = new Map();
|
|
24509
|
+
const leftPrologues = /* @__PURE__ */ new Map();
|
|
24526
24510
|
for (let i = 0; i < leftStandardPrologueEnd; i++) {
|
|
24527
24511
|
const leftPrologue = statements[i];
|
|
24528
24512
|
leftPrologues.set(leftPrologue.expression.text, true);
|
|
@@ -24946,7 +24930,7 @@ ${lanes.join("\n")}
|
|
|
24946
24930
|
node.declarationPath = declarationPath;
|
|
24947
24931
|
node.declarationMapPath = declarationMapPath;
|
|
24948
24932
|
node.buildInfoPath = buildInfoPath;
|
|
24949
|
-
const cache = new Map();
|
|
24933
|
+
const cache = /* @__PURE__ */ new Map();
|
|
24950
24934
|
const textGetter = (path) => {
|
|
24951
24935
|
if (path === void 0)
|
|
24952
24936
|
return void 0;
|
|
@@ -28297,8 +28281,8 @@ ${lanes.join("\n")}
|
|
|
28297
28281
|
languageVariant = getLanguageVariant(_scriptKind);
|
|
28298
28282
|
parseDiagnostics = [];
|
|
28299
28283
|
parsingContext = 0;
|
|
28300
|
-
identifiers = new Map();
|
|
28301
|
-
privateIdentifiers = new Map();
|
|
28284
|
+
identifiers = /* @__PURE__ */ new Map();
|
|
28285
|
+
privateIdentifiers = /* @__PURE__ */ new Map();
|
|
28302
28286
|
identifierCount = 0;
|
|
28303
28287
|
nodeCount = 0;
|
|
28304
28288
|
sourceFlags = 0;
|
|
@@ -30783,7 +30767,7 @@ ${lanes.join("\n")}
|
|
|
30783
30767
|
}
|
|
30784
30768
|
const result = parseParenthesizedArrowFunctionExpression(false, allowReturnTypeInArrowFunction);
|
|
30785
30769
|
if (!result) {
|
|
30786
|
-
(notParenthesizedArrow || (notParenthesizedArrow = new Set())).add(tokenPos);
|
|
30770
|
+
(notParenthesizedArrow || (notParenthesizedArrow = /* @__PURE__ */ new Set())).add(tokenPos);
|
|
30787
30771
|
}
|
|
30788
30772
|
return result;
|
|
30789
30773
|
}
|
|
@@ -34241,7 +34225,7 @@ ${lanes.join("\n")}
|
|
|
34241
34225
|
const comment = sourceText.substring(range.pos, range.end);
|
|
34242
34226
|
extractPragmas(pragmas, range, comment);
|
|
34243
34227
|
}
|
|
34244
|
-
context.pragmas = new Map();
|
|
34228
|
+
context.pragmas = /* @__PURE__ */ new Map();
|
|
34245
34229
|
for (const pragma of pragmas) {
|
|
34246
34230
|
if (context.pragmas.has(pragma.name)) {
|
|
34247
34231
|
const currentValue = context.pragmas.get(pragma.name);
|
|
@@ -34328,7 +34312,7 @@ ${lanes.join("\n")}
|
|
|
34328
34312
|
}
|
|
34329
34313
|
});
|
|
34330
34314
|
}
|
|
34331
|
-
var namedArgRegExCache = new Map();
|
|
34315
|
+
var namedArgRegExCache = /* @__PURE__ */ new Map();
|
|
34332
34316
|
function getNamedArgRegEx(name) {
|
|
34333
34317
|
if (namedArgRegExCache.has(name)) {
|
|
34334
34318
|
return namedArgRegExCache.get(name);
|
|
@@ -35791,8 +35775,8 @@ ${lanes.join("\n")}
|
|
|
35791
35775
|
}
|
|
35792
35776
|
];
|
|
35793
35777
|
function createOptionNameMap(optionDeclarations2) {
|
|
35794
|
-
const optionsNameMap = new Map();
|
|
35795
|
-
const shortOptionNames = new Map();
|
|
35778
|
+
const optionsNameMap = /* @__PURE__ */ new Map();
|
|
35779
|
+
const shortOptionNames = /* @__PURE__ */ new Map();
|
|
35796
35780
|
forEach(optionDeclarations2, (option) => {
|
|
35797
35781
|
optionsNameMap.set(option.name.toLowerCase(), option);
|
|
35798
35782
|
if (option.shortName) {
|
|
@@ -36517,7 +36501,7 @@ ${lanes.join("\n")}
|
|
|
36517
36501
|
return serializeOptionBaseObject(options, getWatchOptionsNameMap());
|
|
36518
36502
|
}
|
|
36519
36503
|
function serializeOptionBaseObject(options, { optionsNameMap }, pathOptions) {
|
|
36520
|
-
const result = new Map();
|
|
36504
|
+
const result = /* @__PURE__ */ new Map();
|
|
36521
36505
|
const getCanonicalFileName = pathOptions && createGetCanonicalFileName(pathOptions.useCaseSensitiveFileNames);
|
|
36522
36506
|
for (const name in options) {
|
|
36523
36507
|
if (hasProperty(options, name)) {
|
|
@@ -36585,7 +36569,7 @@ ${lanes.join("\n")}
|
|
|
36585
36569
|
return !isCommandLineOnly && category !== void 0 && (!categoriesToSkip.includes(category) || compilerOptionsMap.has(name));
|
|
36586
36570
|
}
|
|
36587
36571
|
function writeConfigurations() {
|
|
36588
|
-
const categorizedOptions = new Map();
|
|
36572
|
+
const categorizedOptions = /* @__PURE__ */ new Map();
|
|
36589
36573
|
categorizedOptions.set(Diagnostics.Projects, []);
|
|
36590
36574
|
categorizedOptions.set(Diagnostics.Language_and_Environment, []);
|
|
36591
36575
|
categorizedOptions.set(Diagnostics.Modules, []);
|
|
@@ -37160,9 +37144,9 @@ ${lanes.join("\n")}
|
|
|
37160
37144
|
function getFileNamesFromConfigSpecs(configFileSpecs, basePath, options, host, extraFileExtensions = emptyArray) {
|
|
37161
37145
|
basePath = normalizePath(basePath);
|
|
37162
37146
|
const keyMapper = createGetCanonicalFileName(host.useCaseSensitiveFileNames);
|
|
37163
|
-
const literalFileMap = new Map();
|
|
37164
|
-
const wildcardFileMap = new Map();
|
|
37165
|
-
const wildCardJsonFileMap = new Map();
|
|
37147
|
+
const literalFileMap = /* @__PURE__ */ new Map();
|
|
37148
|
+
const wildcardFileMap = /* @__PURE__ */ new Map();
|
|
37149
|
+
const wildCardJsonFileMap = /* @__PURE__ */ new Map();
|
|
37166
37150
|
const { validatedFilesSpec, validatedIncludeSpecs, validatedExcludeSpecs } = configFileSpecs;
|
|
37167
37151
|
const supportedExtensions = getSupportedExtensions(options, extraFileExtensions);
|
|
37168
37152
|
const supportedExtensionsWithJsonIfResolveJsonModule = getSupportedExtensionsWithJsonIfResolveJsonModule(options, supportedExtensions);
|
|
@@ -37774,8 +37758,8 @@ ${lanes.join("\n")}
|
|
|
37774
37758
|
return result;
|
|
37775
37759
|
}
|
|
37776
37760
|
function createCacheWithRedirects(options) {
|
|
37777
|
-
let ownMap = new Map();
|
|
37778
|
-
const redirectsMap = new Map();
|
|
37761
|
+
let ownMap = /* @__PURE__ */ new Map();
|
|
37762
|
+
const redirectsMap = /* @__PURE__ */ new Map();
|
|
37779
37763
|
return {
|
|
37780
37764
|
getOwnMap,
|
|
37781
37765
|
redirectsMap,
|
|
@@ -37800,7 +37784,7 @@ ${lanes.join("\n")}
|
|
|
37800
37784
|
const path = redirectedReference.sourceFile.path;
|
|
37801
37785
|
let redirects = redirectsMap.get(path);
|
|
37802
37786
|
if (!redirects) {
|
|
37803
|
-
redirects = !options || optionsHaveModuleResolutionChanges(options, redirectedReference.commandLine.options) ? new Map() : ownMap;
|
|
37787
|
+
redirects = !options || optionsHaveModuleResolutionChanges(options, redirectedReference.commandLine.options) ? /* @__PURE__ */ new Map() : ownMap;
|
|
37804
37788
|
redirectsMap.set(path, redirects);
|
|
37805
37789
|
}
|
|
37806
37790
|
return redirects;
|
|
@@ -37817,7 +37801,7 @@ ${lanes.join("\n")}
|
|
|
37817
37801
|
return cache == null ? void 0 : cache.get(toPath(packageJsonPath, currentDirectory, getCanonicalFileName));
|
|
37818
37802
|
}
|
|
37819
37803
|
function setPackageJsonInfo(packageJsonPath, info) {
|
|
37820
|
-
(cache || (cache = new Map())).set(toPath(packageJsonPath, currentDirectory, getCanonicalFileName), info);
|
|
37804
|
+
(cache || (cache = /* @__PURE__ */ new Map())).set(toPath(packageJsonPath, currentDirectory, getCanonicalFileName), info);
|
|
37821
37805
|
}
|
|
37822
37806
|
function clear2() {
|
|
37823
37807
|
cache = void 0;
|
|
@@ -37878,8 +37862,8 @@ ${lanes.join("\n")}
|
|
|
37878
37862
|
}
|
|
37879
37863
|
}
|
|
37880
37864
|
function createModeAwareCache() {
|
|
37881
|
-
const underlying = new Map();
|
|
37882
|
-
const memoizedReverseKeys = new Map();
|
|
37865
|
+
const underlying = /* @__PURE__ */ new Map();
|
|
37866
|
+
const memoizedReverseKeys = /* @__PURE__ */ new Map();
|
|
37883
37867
|
const cache = {
|
|
37884
37868
|
get(specifier, mode) {
|
|
37885
37869
|
return underlying.get(getUnderlyingCacheKey(specifier, mode));
|
|
@@ -37956,7 +37940,7 @@ ${lanes.join("\n")}
|
|
|
37956
37940
|
return getOrCreateCache(moduleNameToDirectoryMap, redirectedReference, mode === void 0 ? nonRelativeModuleName : `${mode}|${nonRelativeModuleName}`, createPerModuleNameCache);
|
|
37957
37941
|
}
|
|
37958
37942
|
function createPerModuleNameCache() {
|
|
37959
|
-
const directoryPathMap = new Map();
|
|
37943
|
+
const directoryPathMap = /* @__PURE__ */ new Map();
|
|
37960
37944
|
return { get, set };
|
|
37961
37945
|
function get(directory) {
|
|
37962
37946
|
return directoryPathMap.get(toPath(directory, currentDirectory, getCanonicalFileName));
|
|
@@ -39383,7 +39367,7 @@ ${lanes.join("\n")}
|
|
|
39383
39367
|
}
|
|
39384
39368
|
return node.body ? getModuleInstanceStateCached(node.body, visited) : 1 /* Instantiated */;
|
|
39385
39369
|
}
|
|
39386
|
-
function getModuleInstanceStateCached(node, visited = new Map()) {
|
|
39370
|
+
function getModuleInstanceStateCached(node, visited = /* @__PURE__ */ new Map()) {
|
|
39387
39371
|
const nodeId = getNodeId(node);
|
|
39388
39372
|
if (visited.has(nodeId)) {
|
|
39389
39373
|
return visited.get(nodeId) || 0 /* NonInstantiated */;
|
|
@@ -39535,7 +39519,7 @@ ${lanes.join("\n")}
|
|
|
39535
39519
|
options = opts;
|
|
39536
39520
|
languageVersion = getEmitScriptTarget(options);
|
|
39537
39521
|
inStrictMode = bindInStrictMode(file, opts);
|
|
39538
|
-
classifiableNames = new Set();
|
|
39522
|
+
classifiableNames = /* @__PURE__ */ new Set();
|
|
39539
39523
|
symbolCount = 0;
|
|
39540
39524
|
Symbol46 = objectAllocator.getSymbolConstructor();
|
|
39541
39525
|
Debug.attachFlowNodeDebugInfo(unreachableFlow);
|
|
@@ -41661,7 +41645,7 @@ ${lanes.join("\n")}
|
|
|
41661
41645
|
}
|
|
41662
41646
|
function addLateBoundAssignmentDeclarationToSymbol(node, symbol) {
|
|
41663
41647
|
if (symbol) {
|
|
41664
|
-
(symbol.assignmentDeclarationMembers || (symbol.assignmentDeclarationMembers = new Map())).set(getNodeId(node), node);
|
|
41648
|
+
(symbol.assignmentDeclarationMembers || (symbol.assignmentDeclarationMembers = /* @__PURE__ */ new Map())).set(getNodeId(node), node);
|
|
41665
41649
|
}
|
|
41666
41650
|
}
|
|
41667
41651
|
function bindSpecialPropertyDeclaration(node) {
|
|
@@ -42490,7 +42474,7 @@ ${lanes.join("\n")}
|
|
|
42490
42474
|
}
|
|
42491
42475
|
function getAllModulePathsWorker(importingFileName, importedFileName, host) {
|
|
42492
42476
|
const getCanonicalFileName = hostGetCanonicalFileName(host);
|
|
42493
|
-
const allFileNames = new Map();
|
|
42477
|
+
const allFileNames = /* @__PURE__ */ new Map();
|
|
42494
42478
|
let importedFileFromNodeModules = false;
|
|
42495
42479
|
forEachFileNameOfModule(
|
|
42496
42480
|
importingFileName,
|
|
@@ -43009,7 +42993,7 @@ ${lanes.join("\n")}
|
|
|
43009
42993
|
}
|
|
43010
42994
|
function createTypeChecker(host) {
|
|
43011
42995
|
const getPackagesMap = memoize(() => {
|
|
43012
|
-
const map2 = new Map();
|
|
42996
|
+
const map2 = /* @__PURE__ */ new Map();
|
|
43013
42997
|
host.getSourceFiles().forEach((sf) => {
|
|
43014
42998
|
if (!sf.resolvedModules)
|
|
43015
42999
|
return;
|
|
@@ -43422,26 +43406,26 @@ ${lanes.join("\n")}
|
|
|
43422
43406
|
apparentArgumentCount = void 0;
|
|
43423
43407
|
return res;
|
|
43424
43408
|
}
|
|
43425
|
-
const tupleTypes = new Map();
|
|
43426
|
-
const unionTypes = new Map();
|
|
43427
|
-
const intersectionTypes = new Map();
|
|
43428
|
-
const stringLiteralTypes = new Map();
|
|
43429
|
-
const numberLiteralTypes = new Map();
|
|
43430
|
-
const bigIntLiteralTypes = new Map();
|
|
43431
|
-
const enumLiteralTypes = new Map();
|
|
43432
|
-
const indexedAccessTypes = new Map();
|
|
43433
|
-
const templateLiteralTypes = new Map();
|
|
43434
|
-
const stringMappingTypes = new Map();
|
|
43435
|
-
const substitutionTypes = new Map();
|
|
43436
|
-
const subtypeReductionCache = new Map();
|
|
43437
|
-
const cachedTypes = new Map();
|
|
43409
|
+
const tupleTypes = /* @__PURE__ */ new Map();
|
|
43410
|
+
const unionTypes = /* @__PURE__ */ new Map();
|
|
43411
|
+
const intersectionTypes = /* @__PURE__ */ new Map();
|
|
43412
|
+
const stringLiteralTypes = /* @__PURE__ */ new Map();
|
|
43413
|
+
const numberLiteralTypes = /* @__PURE__ */ new Map();
|
|
43414
|
+
const bigIntLiteralTypes = /* @__PURE__ */ new Map();
|
|
43415
|
+
const enumLiteralTypes = /* @__PURE__ */ new Map();
|
|
43416
|
+
const indexedAccessTypes = /* @__PURE__ */ new Map();
|
|
43417
|
+
const templateLiteralTypes = /* @__PURE__ */ new Map();
|
|
43418
|
+
const stringMappingTypes = /* @__PURE__ */ new Map();
|
|
43419
|
+
const substitutionTypes = /* @__PURE__ */ new Map();
|
|
43420
|
+
const subtypeReductionCache = /* @__PURE__ */ new Map();
|
|
43421
|
+
const cachedTypes = /* @__PURE__ */ new Map();
|
|
43438
43422
|
const evolvingArrayTypes = [];
|
|
43439
|
-
const undefinedProperties = new Map();
|
|
43440
|
-
const markerTypes = new Set();
|
|
43423
|
+
const undefinedProperties = /* @__PURE__ */ new Map();
|
|
43424
|
+
const markerTypes = /* @__PURE__ */ new Set();
|
|
43441
43425
|
const unknownSymbol = createSymbol(4 /* Property */, "unknown");
|
|
43442
43426
|
const resolvingSymbol = createSymbol(0, "__resolving__" /* Resolving */);
|
|
43443
|
-
const unresolvedSymbols = new Map();
|
|
43444
|
-
const errorTypes = new Map();
|
|
43427
|
+
const unresolvedSymbols = /* @__PURE__ */ new Map();
|
|
43428
|
+
const errorTypes = /* @__PURE__ */ new Map();
|
|
43445
43429
|
const anyType = createIntrinsicType(1 /* Any */, "any");
|
|
43446
43430
|
const autoType = createIntrinsicType(1 /* Any */, "any", 262144 /* NonInferrableType */);
|
|
43447
43431
|
const wildcardType = createIntrinsicType(1 /* Any */, "any");
|
|
@@ -43512,7 +43496,7 @@ ${lanes.join("\n")}
|
|
|
43512
43496
|
const unknownEmptyObjectType = createAnonymousType(void 0, emptySymbols, emptyArray, emptyArray, emptyArray);
|
|
43513
43497
|
const unknownUnionType = strictNullChecks ? getUnionType([undefinedType, nullType, unknownEmptyObjectType]) : unknownType;
|
|
43514
43498
|
const emptyGenericType = createAnonymousType(void 0, emptySymbols, emptyArray, emptyArray, emptyArray);
|
|
43515
|
-
emptyGenericType.instantiations = new Map();
|
|
43499
|
+
emptyGenericType.instantiations = /* @__PURE__ */ new Map();
|
|
43516
43500
|
const anyFunctionType = createAnonymousType(void 0, emptySymbols, emptyArray, emptyArray, emptyArray);
|
|
43517
43501
|
anyFunctionType.objectFlags |= 262144 /* NonInferrableType */;
|
|
43518
43502
|
const noConstraintType = createAnonymousType(void 0, emptySymbols, emptyArray, emptyArray, emptyArray);
|
|
@@ -43531,7 +43515,7 @@ ${lanes.join("\n")}
|
|
|
43531
43515
|
const resolvingSignature = createSignature(void 0, void 0, void 0, emptyArray, anyType, void 0, 0, 0 /* None */);
|
|
43532
43516
|
const silentNeverSignature = createSignature(void 0, void 0, void 0, emptyArray, silentNeverType, void 0, 0, 0 /* None */);
|
|
43533
43517
|
const enumNumberIndexInfo = createIndexInfo(numberType, stringType, true);
|
|
43534
|
-
const iterationTypesCache = new Map();
|
|
43518
|
+
const iterationTypesCache = /* @__PURE__ */ new Map();
|
|
43535
43519
|
const noIterationTypes = {
|
|
43536
43520
|
get yieldType() {
|
|
43537
43521
|
return Debug.fail("Not supported");
|
|
@@ -43573,7 +43557,7 @@ ${lanes.join("\n")}
|
|
|
43573
43557
|
mustHaveAValueDiagnostic: Diagnostics.The_type_returned_by_the_0_method_of_an_iterator_must_have_a_value_property
|
|
43574
43558
|
};
|
|
43575
43559
|
let amalgamatedDuplicates;
|
|
43576
|
-
const reverseMappedCache = new Map();
|
|
43560
|
+
const reverseMappedCache = /* @__PURE__ */ new Map();
|
|
43577
43561
|
let inInferTypeForHomomorphicMappedType = false;
|
|
43578
43562
|
let ambientModulesCache;
|
|
43579
43563
|
let patternAmbientModules;
|
|
@@ -43621,7 +43605,7 @@ ${lanes.join("\n")}
|
|
|
43621
43605
|
let deferredGlobalBigIntType;
|
|
43622
43606
|
let deferredGlobalNaNSymbol;
|
|
43623
43607
|
let deferredGlobalRecordSymbol;
|
|
43624
|
-
const allPotentiallyUnusedIdentifiers = new Map();
|
|
43608
|
+
const allPotentiallyUnusedIdentifiers = /* @__PURE__ */ new Map();
|
|
43625
43609
|
let flowLoopStart = 0;
|
|
43626
43610
|
let flowLoopCount = 0;
|
|
43627
43611
|
let sharedFlowCount = 0;
|
|
@@ -43660,12 +43644,12 @@ ${lanes.join("\n")}
|
|
|
43660
43644
|
const typeofType = createTypeofType();
|
|
43661
43645
|
let _jsxNamespace;
|
|
43662
43646
|
let _jsxFactoryEntity;
|
|
43663
|
-
const subtypeRelation = new Map();
|
|
43664
|
-
const strictSubtypeRelation = new Map();
|
|
43665
|
-
const assignableRelation = new Map();
|
|
43666
|
-
const comparableRelation = new Map();
|
|
43667
|
-
const identityRelation = new Map();
|
|
43668
|
-
const enumRelation = new Map();
|
|
43647
|
+
const subtypeRelation = /* @__PURE__ */ new Map();
|
|
43648
|
+
const strictSubtypeRelation = /* @__PURE__ */ new Map();
|
|
43649
|
+
const assignableRelation = /* @__PURE__ */ new Map();
|
|
43650
|
+
const comparableRelation = /* @__PURE__ */ new Map();
|
|
43651
|
+
const identityRelation = /* @__PURE__ */ new Map();
|
|
43652
|
+
const enumRelation = /* @__PURE__ */ new Map();
|
|
43669
43653
|
const builtinGlobals = createSymbolTable();
|
|
43670
43654
|
builtinGlobals.set(undefinedSymbol.escapedName, undefinedSymbol);
|
|
43671
43655
|
const suggestedExtensions = [
|
|
@@ -43946,7 +43930,7 @@ ${lanes.join("\n")}
|
|
|
43946
43930
|
if (sourceSymbolFile && targetSymbolFile && amalgamatedDuplicates && !isEitherEnum && sourceSymbolFile !== targetSymbolFile) {
|
|
43947
43931
|
const firstFile = comparePaths(sourceSymbolFile.path, targetSymbolFile.path) === -1 /* LessThan */ ? sourceSymbolFile : targetSymbolFile;
|
|
43948
43932
|
const secondFile = firstFile === sourceSymbolFile ? targetSymbolFile : sourceSymbolFile;
|
|
43949
|
-
const filesDuplicates = getOrUpdate(amalgamatedDuplicates, `${firstFile.path}|${secondFile.path}`, () => ({ firstFile, secondFile, conflictingSymbols: new Map() }));
|
|
43933
|
+
const filesDuplicates = getOrUpdate(amalgamatedDuplicates, `${firstFile.path}|${secondFile.path}`, () => ({ firstFile, secondFile, conflictingSymbols: /* @__PURE__ */ new Map() }));
|
|
43950
43934
|
const conflictingSymbolInfo = getOrUpdate(filesDuplicates.conflictingSymbols, symbolName2, () => ({ isBlockScoped: isEitherBlockScoped, firstFileLocations: [], secondFileLocations: [] }));
|
|
43951
43935
|
if (!isSourcePlainJs)
|
|
43952
43936
|
addDuplicateLocations(conflictingSymbolInfo.firstFileLocations, source);
|
|
@@ -44024,7 +44008,7 @@ ${lanes.join("\n")}
|
|
|
44024
44008
|
if (some(patternAmbientModules, (module2) => mainModule === module2.symbol)) {
|
|
44025
44009
|
const merged = mergeSymbol(moduleAugmentation.symbol, mainModule, true);
|
|
44026
44010
|
if (!patternAmbientModuleAugmentations) {
|
|
44027
|
-
patternAmbientModuleAugmentations = new Map();
|
|
44011
|
+
patternAmbientModuleAugmentations = /* @__PURE__ */ new Map();
|
|
44028
44012
|
}
|
|
44029
44013
|
patternAmbientModuleAugmentations.set(moduleName.text, merged);
|
|
44030
44014
|
} else {
|
|
@@ -45343,7 +45327,7 @@ ${lanes.join("\n")}
|
|
|
45343
45327
|
if (seenSymbols) {
|
|
45344
45328
|
seenSymbols.add(target);
|
|
45345
45329
|
} else {
|
|
45346
|
-
seenSymbols = new Set([symbol, target]);
|
|
45330
|
+
seenSymbols = /* @__PURE__ */ new Set([symbol, target]);
|
|
45347
45331
|
}
|
|
45348
45332
|
}
|
|
45349
45333
|
flags |= target.flags;
|
|
@@ -45949,7 +45933,7 @@ ${lanes.join("\n")}
|
|
|
45949
45933
|
const exportStars = symbol.exports.get("__export" /* ExportStar */);
|
|
45950
45934
|
if (exportStars) {
|
|
45951
45935
|
const nestedSymbols = createSymbolTable();
|
|
45952
|
-
const lookupTable = new Map();
|
|
45936
|
+
const lookupTable = /* @__PURE__ */ new Map();
|
|
45953
45937
|
if (exportStars.declarations) {
|
|
45954
45938
|
for (const node of exportStars.declarations) {
|
|
45955
45939
|
const resolvedModule = resolveExternalModuleName(node, node.moduleSpecifier);
|
|
@@ -46011,7 +45995,7 @@ ${lanes.join("\n")}
|
|
|
46011
45995
|
results = append(results, resolvedModule);
|
|
46012
45996
|
}
|
|
46013
45997
|
if (length(results)) {
|
|
46014
|
-
(links.extendedContainersByFile || (links.extendedContainersByFile = new Map())).set(id, results);
|
|
45998
|
+
(links.extendedContainersByFile || (links.extendedContainersByFile = /* @__PURE__ */ new Map())).set(id, results);
|
|
46015
45999
|
return results;
|
|
46016
46000
|
}
|
|
46017
46001
|
}
|
|
@@ -46263,12 +46247,12 @@ ${lanes.join("\n")}
|
|
|
46263
46247
|
function getQualifiedLeftMeaning(rightMeaning) {
|
|
46264
46248
|
return rightMeaning === 111551 /* Value */ ? 111551 /* Value */ : 1920 /* Namespace */;
|
|
46265
46249
|
}
|
|
46266
|
-
function getAccessibleSymbolChain(symbol, enclosingDeclaration, meaning, useOnlyExternalAliasing, visitedSymbolTablesMap = new Map()) {
|
|
46250
|
+
function getAccessibleSymbolChain(symbol, enclosingDeclaration, meaning, useOnlyExternalAliasing, visitedSymbolTablesMap = /* @__PURE__ */ new Map()) {
|
|
46267
46251
|
if (!(symbol && !isPropertyOrMethodDeclarationSymbol(symbol))) {
|
|
46268
46252
|
return void 0;
|
|
46269
46253
|
}
|
|
46270
46254
|
const links = getSymbolLinks(symbol);
|
|
46271
|
-
const cache = links.accessibleChainCache || (links.accessibleChainCache = new Map());
|
|
46255
|
+
const cache = links.accessibleChainCache || (links.accessibleChainCache = /* @__PURE__ */ new Map());
|
|
46272
46256
|
const firstRelevantLocation = forEachSymbolTableInScope(enclosingDeclaration, (_, __, ___, node) => node);
|
|
46273
46257
|
const key = `${useOnlyExternalAliasing ? 0 : 1}|${firstRelevantLocation && getNodeId(firstRelevantLocation)}|${meaning}`;
|
|
46274
46258
|
if (cache.has(key)) {
|
|
@@ -46638,22 +46622,25 @@ ${lanes.join("\n")}
|
|
|
46638
46622
|
const context = {
|
|
46639
46623
|
enclosingDeclaration,
|
|
46640
46624
|
flags: flags || 0 /* None */,
|
|
46641
|
-
tracker: tracker && tracker.trackSymbol ? tracker : {
|
|
46642
|
-
|
|
46643
|
-
|
|
46644
|
-
|
|
46645
|
-
|
|
46646
|
-
|
|
46647
|
-
|
|
46648
|
-
|
|
46649
|
-
|
|
46650
|
-
|
|
46651
|
-
|
|
46652
|
-
|
|
46653
|
-
|
|
46654
|
-
|
|
46655
|
-
|
|
46656
|
-
|
|
46625
|
+
tracker: tracker && tracker.trackSymbol ? tracker : {
|
|
46626
|
+
trackSymbol: () => false,
|
|
46627
|
+
moduleResolverHost: flags & 134217728 /* DoNotIncludeSymbolChain */ ? {
|
|
46628
|
+
getCommonSourceDirectory: !!host.getCommonSourceDirectory ? () => host.getCommonSourceDirectory() : () => "",
|
|
46629
|
+
getCurrentDirectory: () => host.getCurrentDirectory(),
|
|
46630
|
+
getSymlinkCache: maybeBind(host, host.getSymlinkCache),
|
|
46631
|
+
getPackageJsonInfoCache: () => {
|
|
46632
|
+
var _a3;
|
|
46633
|
+
return (_a3 = host.getPackageJsonInfoCache) == null ? void 0 : _a3.call(host);
|
|
46634
|
+
},
|
|
46635
|
+
useCaseSensitiveFileNames: maybeBind(host, host.useCaseSensitiveFileNames),
|
|
46636
|
+
redirectTargetsMap: host.redirectTargetsMap,
|
|
46637
|
+
getProjectReferenceRedirect: (fileName) => host.getProjectReferenceRedirect(fileName),
|
|
46638
|
+
isSourceOfProjectReferenceRedirect: (fileName) => host.isSourceOfProjectReferenceRedirect(fileName),
|
|
46639
|
+
fileExists: (fileName) => host.fileExists(fileName),
|
|
46640
|
+
getFileIncludeReasons: () => host.getFileIncludeReasons(),
|
|
46641
|
+
readFile: host.readFile ? (fileName) => host.readFile(fileName) : void 0
|
|
46642
|
+
} : void 0
|
|
46643
|
+
},
|
|
46657
46644
|
encounteredError: false,
|
|
46658
46645
|
reportedDiagnostic: false,
|
|
46659
46646
|
visitedTypes: void 0,
|
|
@@ -47065,15 +47052,15 @@ ${lanes.join("\n")}
|
|
|
47065
47052
|
const isConstructorObject = getObjectFlags(type2) & 16 /* Anonymous */ && type2.symbol && type2.symbol.flags & 32 /* Class */;
|
|
47066
47053
|
const id = getObjectFlags(type2) & 4 /* Reference */ && type2.node ? "N" + getNodeId(type2.node) : type2.flags & 16777216 /* Conditional */ ? "N" + getNodeId(type2.root.node) : type2.symbol ? (isConstructorObject ? "+" : "") + getSymbolId(type2.symbol) : void 0;
|
|
47067
47054
|
if (!context.visitedTypes) {
|
|
47068
|
-
context.visitedTypes = new Set();
|
|
47055
|
+
context.visitedTypes = /* @__PURE__ */ new Set();
|
|
47069
47056
|
}
|
|
47070
47057
|
if (id && !context.symbolDepth) {
|
|
47071
|
-
context.symbolDepth = new Map();
|
|
47058
|
+
context.symbolDepth = /* @__PURE__ */ new Map();
|
|
47072
47059
|
}
|
|
47073
47060
|
const links = context.enclosingDeclaration && getNodeLinks(context.enclosingDeclaration);
|
|
47074
47061
|
const key = `${getTypeId(type2)}|${context.flags}`;
|
|
47075
47062
|
if (links) {
|
|
47076
|
-
links.serializedTypes || (links.serializedTypes = new Map());
|
|
47063
|
+
links.serializedTypes || (links.serializedTypes = /* @__PURE__ */ new Map());
|
|
47077
47064
|
}
|
|
47078
47065
|
const cachedResult = (_a2 = links == null ? void 0 : links.serializedTypes) == null ? void 0 : _a2.get(key);
|
|
47079
47066
|
if (cachedResult) {
|
|
@@ -47716,7 +47703,7 @@ ${lanes.join("\n")}
|
|
|
47716
47703
|
if ((_a2 = context.typeParameterSymbolList) == null ? void 0 : _a2.has(symbolId)) {
|
|
47717
47704
|
return void 0;
|
|
47718
47705
|
}
|
|
47719
|
-
(context.typeParameterSymbolList || (context.typeParameterSymbolList = new Set())).add(symbolId);
|
|
47706
|
+
(context.typeParameterSymbolList || (context.typeParameterSymbolList = /* @__PURE__ */ new Set())).add(symbolId);
|
|
47720
47707
|
let typeParameterNodes;
|
|
47721
47708
|
if (context.flags & 512 /* WriteTypeParametersInQualifiedName */ && index < chain.length - 1) {
|
|
47722
47709
|
const parentSymbol = symbol;
|
|
@@ -47790,7 +47777,7 @@ ${lanes.join("\n")}
|
|
|
47790
47777
|
},
|
|
47791
47778
|
{ overrideImportMode }
|
|
47792
47779
|
));
|
|
47793
|
-
(_a2 = links.specifierCache) != null ? _a2 : links.specifierCache = new Map();
|
|
47780
|
+
(_a2 = links.specifierCache) != null ? _a2 : links.specifierCache = /* @__PURE__ */ new Map();
|
|
47794
47781
|
links.specifierCache.set(cacheKey, specifier);
|
|
47795
47782
|
}
|
|
47796
47783
|
return specifier;
|
|
@@ -47966,9 +47953,9 @@ ${lanes.join("\n")}
|
|
|
47966
47953
|
if (text !== rawtext) {
|
|
47967
47954
|
result = factory.createIdentifier(text, result.typeArguments);
|
|
47968
47955
|
}
|
|
47969
|
-
(context.typeParameterNamesByTextNextNameCount || (context.typeParameterNamesByTextNextNameCount = new Map())).set(rawtext, i);
|
|
47970
|
-
(context.typeParameterNames || (context.typeParameterNames = new Map())).set(getTypeId(type), result);
|
|
47971
|
-
(context.typeParameterNamesByText || (context.typeParameterNamesByText = new Set())).add(rawtext);
|
|
47956
|
+
(context.typeParameterNamesByTextNextNameCount || (context.typeParameterNamesByTextNextNameCount = /* @__PURE__ */ new Map())).set(rawtext, i);
|
|
47957
|
+
(context.typeParameterNames || (context.typeParameterNames = /* @__PURE__ */ new Map())).set(getTypeId(type), result);
|
|
47958
|
+
(context.typeParameterNamesByText || (context.typeParameterNamesByText = /* @__PURE__ */ new Set())).add(rawtext);
|
|
47972
47959
|
}
|
|
47973
47960
|
return result;
|
|
47974
47961
|
}
|
|
@@ -48318,13 +48305,13 @@ ${lanes.join("\n")}
|
|
|
48318
48305
|
const serializePropertySymbolForInterfaceWorker = makeSerializePropertySymbol((mods, name, question, type) => factory.createPropertySignature(mods, name, question, type), 170 /* MethodSignature */, false);
|
|
48319
48306
|
const enclosingDeclaration = context.enclosingDeclaration;
|
|
48320
48307
|
let results = [];
|
|
48321
|
-
const visitedSymbols = new Set();
|
|
48308
|
+
const visitedSymbols = /* @__PURE__ */ new Set();
|
|
48322
48309
|
const deferredPrivatesStack = [];
|
|
48323
48310
|
const oldcontext = context;
|
|
48324
48311
|
context = {
|
|
48325
48312
|
...oldcontext,
|
|
48326
48313
|
usedSymbolNames: new Set(oldcontext.usedSymbolNames),
|
|
48327
|
-
remappedSymbolNames: new Map(),
|
|
48314
|
+
remappedSymbolNames: /* @__PURE__ */ new Map(),
|
|
48328
48315
|
tracker: {
|
|
48329
48316
|
...oldcontext.tracker,
|
|
48330
48317
|
trackSymbol: (sym, decl, meaning) => {
|
|
@@ -48485,7 +48472,7 @@ ${lanes.join("\n")}
|
|
|
48485
48472
|
}
|
|
48486
48473
|
function visitSymbolTable(symbolTable2, suppressNewPrivateContext, propertyAsAlias) {
|
|
48487
48474
|
if (!suppressNewPrivateContext) {
|
|
48488
|
-
deferredPrivatesStack.push(new Map());
|
|
48475
|
+
deferredPrivatesStack.push(/* @__PURE__ */ new Map());
|
|
48489
48476
|
}
|
|
48490
48477
|
symbolTable2.forEach((symbol) => {
|
|
48491
48478
|
serializeSymbol(symbol, false, !!propertyAsAlias);
|
|
@@ -49590,7 +49577,7 @@ ${lanes.join("\n")}
|
|
|
49590
49577
|
let result;
|
|
49591
49578
|
let visited;
|
|
49592
49579
|
if (exportSymbol) {
|
|
49593
|
-
visited = new Set();
|
|
49580
|
+
visited = /* @__PURE__ */ new Set();
|
|
49594
49581
|
visited.add(getSymbolId(exportSymbol));
|
|
49595
49582
|
buildVisibleNodeList(exportSymbol.declarations);
|
|
49596
49583
|
}
|
|
@@ -51075,7 +51062,7 @@ ${lanes.join("\n")}
|
|
|
51075
51062
|
type.typeParameters = concatenate(outerTypeParameters, localTypeParameters);
|
|
51076
51063
|
type.outerTypeParameters = outerTypeParameters;
|
|
51077
51064
|
type.localTypeParameters = localTypeParameters;
|
|
51078
|
-
type.instantiations = new Map();
|
|
51065
|
+
type.instantiations = /* @__PURE__ */ new Map();
|
|
51079
51066
|
type.instantiations.set(getTypeListId(type.typeParameters), type);
|
|
51080
51067
|
type.target = type;
|
|
51081
51068
|
type.resolvedTypeArguments = type.typeParameters;
|
|
@@ -51100,7 +51087,7 @@ ${lanes.join("\n")}
|
|
|
51100
51087
|
const typeParameters = getLocalTypeParametersOfClassOrInterfaceOrTypeAlias(symbol);
|
|
51101
51088
|
if (typeParameters) {
|
|
51102
51089
|
links.typeParameters = typeParameters;
|
|
51103
|
-
links.instantiations = new Map();
|
|
51090
|
+
links.instantiations = /* @__PURE__ */ new Map();
|
|
51104
51091
|
links.instantiations.set(getTypeListId(typeParameters), type);
|
|
51105
51092
|
}
|
|
51106
51093
|
} else {
|
|
@@ -51868,7 +51855,7 @@ ${lanes.join("\n")}
|
|
|
51868
51855
|
if (symbol.exports) {
|
|
51869
51856
|
members = getExportsOfSymbol(symbol);
|
|
51870
51857
|
if (symbol === globalThisSymbol) {
|
|
51871
|
-
const varsOnly = new Map();
|
|
51858
|
+
const varsOnly = /* @__PURE__ */ new Map();
|
|
51872
51859
|
members.forEach((p) => {
|
|
51873
51860
|
var _a2;
|
|
51874
51861
|
if (!(p.flags & 418 /* BlockScoped */) && !(p.flags & 512 /* ValueModule */ && ((_a2 = p.declarations) == null ? void 0 : _a2.length) && every(p.declarations, isAmbientModule))) {
|
|
@@ -51965,7 +51952,7 @@ ${lanes.join("\n")}
|
|
|
51965
51952
|
return type;
|
|
51966
51953
|
}
|
|
51967
51954
|
if (type.flags & 1048576 /* Union */) {
|
|
51968
|
-
return mapType(type, getLowerBoundOfKeyType);
|
|
51955
|
+
return mapType(type, getLowerBoundOfKeyType, true);
|
|
51969
51956
|
}
|
|
51970
51957
|
if (type.flags & 2097152 /* Intersection */) {
|
|
51971
51958
|
const types = type.types;
|
|
@@ -52512,7 +52499,7 @@ ${lanes.join("\n")}
|
|
|
52512
52499
|
mergedInstantiations = !!singleProp.parent && !!length(getLocalTypeParametersOfClassOrInterfaceOrTypeAlias(singleProp.parent));
|
|
52513
52500
|
} else {
|
|
52514
52501
|
if (!propSet) {
|
|
52515
|
-
propSet = new Map();
|
|
52502
|
+
propSet = /* @__PURE__ */ new Map();
|
|
52516
52503
|
propSet.set(getSymbolId(singleProp), singleProp);
|
|
52517
52504
|
}
|
|
52518
52505
|
const id = getSymbolId(prop);
|
|
@@ -53167,7 +53154,7 @@ ${lanes.join("\n")}
|
|
|
53167
53154
|
return instantiatedSignature;
|
|
53168
53155
|
}
|
|
53169
53156
|
function getSignatureInstantiationWithoutFillingInTypeArguments(signature, typeArguments) {
|
|
53170
|
-
const instantiations = signature.instantiations || (signature.instantiations = new Map());
|
|
53157
|
+
const instantiations = signature.instantiations || (signature.instantiations = /* @__PURE__ */ new Map());
|
|
53171
53158
|
const id = getTypeListId(typeArguments);
|
|
53172
53159
|
let instantiation = instantiations.get(id);
|
|
53173
53160
|
if (!instantiation) {
|
|
@@ -54064,7 +54051,7 @@ ${lanes.join("\n")}
|
|
|
54064
54051
|
type.typeParameters = typeParameters;
|
|
54065
54052
|
type.outerTypeParameters = void 0;
|
|
54066
54053
|
type.localTypeParameters = typeParameters;
|
|
54067
|
-
type.instantiations = new Map();
|
|
54054
|
+
type.instantiations = /* @__PURE__ */ new Map();
|
|
54068
54055
|
type.instantiations.set(getTypeListId(type.typeParameters), type);
|
|
54069
54056
|
type.target = type;
|
|
54070
54057
|
type.resolvedTypeArguments = type.typeParameters;
|
|
@@ -54577,7 +54564,7 @@ ${lanes.join("\n")}
|
|
|
54577
54564
|
return result;
|
|
54578
54565
|
}
|
|
54579
54566
|
function getIntersectionType(types, aliasSymbol, aliasTypeArguments, noSupertypeReduction) {
|
|
54580
|
-
const typeMembershipMap = new Map();
|
|
54567
|
+
const typeMembershipMap = /* @__PURE__ */ new Map();
|
|
54581
54568
|
const includes = addTypesToIntersection(typeMembershipMap, 0, types);
|
|
54582
54569
|
const typeSet = arrayFrom(typeMembershipMap.values());
|
|
54583
54570
|
if (includes & 131072 /* Never */) {
|
|
@@ -55504,7 +55491,7 @@ ${lanes.join("\n")}
|
|
|
55504
55491
|
};
|
|
55505
55492
|
links.resolvedType = getConditionalType(root, void 0);
|
|
55506
55493
|
if (outerTypeParameters) {
|
|
55507
|
-
root.instantiations = new Map();
|
|
55494
|
+
root.instantiations = /* @__PURE__ */ new Map();
|
|
55508
55495
|
root.instantiations.set(getTypeListId(outerTypeParameters), links.resolvedType);
|
|
55509
55496
|
}
|
|
55510
55497
|
}
|
|
@@ -55695,7 +55682,7 @@ ${lanes.join("\n")}
|
|
|
55695
55682
|
return getIntersectionType([left, right]);
|
|
55696
55683
|
}
|
|
55697
55684
|
const members = createSymbolTable();
|
|
55698
|
-
const skippedPrivateMembers = new Set();
|
|
55685
|
+
const skippedPrivateMembers = /* @__PURE__ */ new Set();
|
|
55699
55686
|
const indexInfos = left === emptyObjectType ? getIndexInfosOfType(right) : getUnionIndexInfos([left, right]);
|
|
55700
55687
|
for (const rightProp of getPropertiesOfType(right)) {
|
|
55701
55688
|
if (getDeclarationModifierFlagsFromSymbol(rightProp) & (8 /* Private */ | 16 /* Protected */)) {
|
|
@@ -56142,7 +56129,7 @@ ${lanes.join("\n")}
|
|
|
56142
56129
|
const newAliasTypeArguments = aliasSymbol ? aliasTypeArguments : instantiateTypes(type.aliasTypeArguments, mapper);
|
|
56143
56130
|
const id = getTypeListId(typeArguments) + getAliasId(newAliasSymbol, newAliasTypeArguments);
|
|
56144
56131
|
if (!target.instantiations) {
|
|
56145
|
-
target.instantiations = new Map();
|
|
56132
|
+
target.instantiations = /* @__PURE__ */ new Map();
|
|
56146
56133
|
target.instantiations.set(getTypeListId(typeParameters) + getAliasId(target.aliasSymbol, target.aliasTypeArguments), target);
|
|
56147
56134
|
}
|
|
56148
56135
|
let result = target.instantiations.get(id);
|
|
@@ -58385,7 +58372,7 @@ ${lanes.join("\n")}
|
|
|
58385
58372
|
}
|
|
58386
58373
|
}
|
|
58387
58374
|
const sourceDiscriminantTypes = new Array(sourcePropertiesFiltered.length);
|
|
58388
|
-
const excludedProperties = new Set();
|
|
58375
|
+
const excludedProperties = /* @__PURE__ */ new Set();
|
|
58389
58376
|
for (let i = 0; i < sourcePropertiesFiltered.length; i++) {
|
|
58390
58377
|
const sourceProperty = sourcePropertiesFiltered[i];
|
|
58391
58378
|
const sourcePropertyType = getNonMissingTypeOfSymbol(sourceProperty);
|
|
@@ -59620,7 +59607,7 @@ ${lanes.join("\n")}
|
|
|
59620
59607
|
}
|
|
59621
59608
|
function getPropertiesOfContext(context) {
|
|
59622
59609
|
if (!context.resolvedProperties) {
|
|
59623
|
-
const names = new Map();
|
|
59610
|
+
const names = /* @__PURE__ */ new Map();
|
|
59624
59611
|
for (const t of getSiblingsOfContext(context)) {
|
|
59625
59612
|
if (isObjectLiteralType2(t) && !(getObjectFlags(t) & 2097152 /* ContainsSpread */)) {
|
|
59626
59613
|
for (const prop of getPropertiesOfType(t)) {
|
|
@@ -60355,7 +60342,7 @@ ${lanes.join("\n")}
|
|
|
60355
60342
|
inferencePriority = Math.min(inferencePriority, status);
|
|
60356
60343
|
return;
|
|
60357
60344
|
}
|
|
60358
|
-
(visited || (visited = new Map())).set(key, -1 /* Circularity */);
|
|
60345
|
+
(visited || (visited = /* @__PURE__ */ new Map())).set(key, -1 /* Circularity */);
|
|
60359
60346
|
const saveInferencePriority = inferencePriority;
|
|
60360
60347
|
inferencePriority = 2048 /* MaxValue */;
|
|
60361
60348
|
const saveExpandingFlags = expandingFlags;
|
|
@@ -60576,7 +60563,6 @@ ${lanes.join("\n")}
|
|
|
60576
60563
|
}
|
|
60577
60564
|
}
|
|
60578
60565
|
function inferFromObjectTypes(source, target) {
|
|
60579
|
-
var _a2, _b;
|
|
60580
60566
|
if (getObjectFlags(source) & 4 /* Reference */ && getObjectFlags(target) & 4 /* Reference */ && (source.target === target.target || isArrayType(source) && isArrayType(target))) {
|
|
60581
60567
|
inferFromTypeArguments(getTypeArguments(source), getTypeArguments(target), getVariances(source.target));
|
|
60582
60568
|
return;
|
|
@@ -60623,35 +60609,11 @@ ${lanes.join("\n")}
|
|
|
60623
60609
|
}
|
|
60624
60610
|
} else {
|
|
60625
60611
|
const middleLength = targetArity - startLength - endLength;
|
|
60626
|
-
if (middleLength === 2) {
|
|
60627
|
-
|
|
60628
|
-
|
|
60629
|
-
|
|
60630
|
-
|
|
60631
|
-
inferFromTypes(sliceTupleType(source, startLength + targetInfo.impliedArity, endLength), elementTypes[startLength + 1]);
|
|
60632
|
-
}
|
|
60633
|
-
} else if (elementFlags[startLength] & 8 /* Variadic */ && elementFlags[startLength + 1] & 4 /* Rest */) {
|
|
60634
|
-
const param = (_a2 = getInferenceInfoForType(elementTypes[startLength])) == null ? void 0 : _a2.typeParameter;
|
|
60635
|
-
const constraint = param && getBaseConstraintOfType(param);
|
|
60636
|
-
if (constraint && isTupleType(constraint) && !constraint.target.hasRestElement) {
|
|
60637
|
-
const impliedArity = constraint.target.fixedLength;
|
|
60638
|
-
inferFromTypes(sliceTupleType(source, startLength, sourceArity - (startLength + impliedArity)), elementTypes[startLength]);
|
|
60639
|
-
}
|
|
60640
|
-
} else if (elementFlags[startLength] & 4 /* Rest */ && elementFlags[startLength + 1] & 8 /* Variadic */ && isTupleType(source)) {
|
|
60641
|
-
const param = (_b = getInferenceInfoForType(elementTypes[startLength + 1])) == null ? void 0 : _b.typeParameter;
|
|
60642
|
-
const constraint = param && getBaseConstraintOfType(param);
|
|
60643
|
-
if (constraint && isTupleType(constraint) && !constraint.target.hasRestElement) {
|
|
60644
|
-
const impliedArity = constraint.target.fixedLength;
|
|
60645
|
-
const endIndex = sourceArity - getEndElementCount(target.target, 3 /* Fixed */);
|
|
60646
|
-
const startIndex = endIndex - impliedArity;
|
|
60647
|
-
const trailingSlice = createTupleType(
|
|
60648
|
-
getTypeArguments(source).slice(startIndex, endIndex),
|
|
60649
|
-
source.target.elementFlags.slice(startIndex, endIndex),
|
|
60650
|
-
false,
|
|
60651
|
-
source.target.labeledElementDeclarations && source.target.labeledElementDeclarations.slice(startIndex, endIndex)
|
|
60652
|
-
);
|
|
60653
|
-
inferFromTypes(trailingSlice, elementTypes[startLength + 1]);
|
|
60654
|
-
}
|
|
60612
|
+
if (middleLength === 2 && elementFlags[startLength] & elementFlags[startLength + 1] & 8 /* Variadic */ && isTupleType(source)) {
|
|
60613
|
+
const targetInfo = getInferenceInfoForType(elementTypes[startLength]);
|
|
60614
|
+
if (targetInfo && targetInfo.impliedArity !== void 0) {
|
|
60615
|
+
inferFromTypes(sliceTupleType(source, startLength, endLength + sourceArity - targetInfo.impliedArity), elementTypes[startLength]);
|
|
60616
|
+
inferFromTypes(sliceTupleType(source, startLength + targetInfo.impliedArity, endLength), elementTypes[startLength + 1]);
|
|
60655
60617
|
}
|
|
60656
60618
|
} else if (middleLength === 1 && elementFlags[startLength] & 8 /* Variadic */) {
|
|
60657
60619
|
const endsInOptional = target.target.elementFlags[targetArity - 1] & 2 /* Optional */;
|
|
@@ -61045,7 +61007,7 @@ ${lanes.join("\n")}
|
|
|
61045
61007
|
return result;
|
|
61046
61008
|
}
|
|
61047
61009
|
function mapTypesByKeyProperty(types, name) {
|
|
61048
|
-
const map2 = new Map();
|
|
61010
|
+
const map2 = /* @__PURE__ */ new Map();
|
|
61049
61011
|
let count = 0;
|
|
61050
61012
|
for (const type of types) {
|
|
61051
61013
|
if (type.flags & (524288 /* Object */ | 2097152 /* Intersection */ | 58982400 /* InstantiableNonPrimitive */)) {
|
|
@@ -62049,7 +62011,7 @@ ${lanes.join("\n")}
|
|
|
62049
62011
|
}
|
|
62050
62012
|
function getTypeAtFlowLoopLabel(flow) {
|
|
62051
62013
|
const id = getFlowNodeId(flow);
|
|
62052
|
-
const cache = flowLoopCaches[id] || (flowLoopCaches[id] = new Map());
|
|
62014
|
+
const cache = flowLoopCaches[id] || (flowLoopCaches[id] = /* @__PURE__ */ new Map());
|
|
62053
62015
|
const key2 = getOrSetCacheKey();
|
|
62054
62016
|
if (!key2) {
|
|
62055
62017
|
return declaredType;
|
|
@@ -67187,7 +67149,7 @@ ${lanes.join("\n")}
|
|
|
67187
67149
|
if ((_b = source.members) == null ? void 0 : _b.size) {
|
|
67188
67150
|
mergeSymbolTable(inferred.members, source.members);
|
|
67189
67151
|
}
|
|
67190
|
-
(links.inferredClassSymbol || (links.inferredClassSymbol = new Map())).set(getSymbolId(inferred), inferred);
|
|
67152
|
+
(links.inferredClassSymbol || (links.inferredClassSymbol = /* @__PURE__ */ new Map())).set(getSymbolId(inferred), inferred);
|
|
67191
67153
|
return inferred;
|
|
67192
67154
|
}
|
|
67193
67155
|
return links.inferredClassSymbol.get(getSymbolId(target));
|
|
@@ -70042,9 +70004,9 @@ ${lanes.join("\n")}
|
|
|
70042
70004
|
}
|
|
70043
70005
|
}
|
|
70044
70006
|
function checkClassForDuplicateDeclarations(node) {
|
|
70045
|
-
const instanceNames = new Map();
|
|
70046
|
-
const staticNames = new Map();
|
|
70047
|
-
const privateIdentifiers = new Map();
|
|
70007
|
+
const instanceNames = /* @__PURE__ */ new Map();
|
|
70008
|
+
const staticNames = /* @__PURE__ */ new Map();
|
|
70009
|
+
const privateIdentifiers = /* @__PURE__ */ new Map();
|
|
70048
70010
|
for (const member of node.members) {
|
|
70049
70011
|
if (member.kind === 173 /* Constructor */) {
|
|
70050
70012
|
for (const param of member.parameters) {
|
|
@@ -70124,7 +70086,7 @@ ${lanes.join("\n")}
|
|
|
70124
70086
|
}
|
|
70125
70087
|
}
|
|
70126
70088
|
function checkObjectTypeForDuplicateDeclarations(node) {
|
|
70127
|
-
const names = new Map();
|
|
70089
|
+
const names = /* @__PURE__ */ new Map();
|
|
70128
70090
|
for (const member of node.members) {
|
|
70129
70091
|
if (member.kind === 168 /* PropertySignature */) {
|
|
70130
70092
|
let memberName;
|
|
@@ -70158,7 +70120,7 @@ ${lanes.join("\n")}
|
|
|
70158
70120
|
}
|
|
70159
70121
|
const indexSymbol = getIndexSymbol(getSymbolOfNode(node));
|
|
70160
70122
|
if (indexSymbol == null ? void 0 : indexSymbol.declarations) {
|
|
70161
|
-
const indexSignatureMap = new Map();
|
|
70123
|
+
const indexSignatureMap = /* @__PURE__ */ new Map();
|
|
70162
70124
|
for (const declaration of indexSymbol.declarations) {
|
|
70163
70125
|
if (declaration.parameters.length === 1 && declaration.parameters[0].type) {
|
|
70164
70126
|
forEachType(getTypeFromTypeNode(declaration.parameters[0].type), (type) => {
|
|
@@ -71542,7 +71504,7 @@ ${lanes.join("\n")}
|
|
|
71542
71504
|
if (!declarations || last(declarations) !== node)
|
|
71543
71505
|
return;
|
|
71544
71506
|
const typeParameters = getEffectiveTypeParameterDeclarations(node);
|
|
71545
|
-
const seenParentsWithEveryUnused = new Set();
|
|
71507
|
+
const seenParentsWithEveryUnused = /* @__PURE__ */ new Set();
|
|
71546
71508
|
for (const typeParameter of typeParameters) {
|
|
71547
71509
|
if (!isTypeParameterUnused(typeParameter))
|
|
71548
71510
|
continue;
|
|
@@ -71587,9 +71549,9 @@ ${lanes.join("\n")}
|
|
|
71587
71549
|
return isAmbientModule(declaration) || (isVariableDeclaration(declaration) && isForInOrOfStatement(declaration.parent.parent) || isImportedDeclaration(declaration)) && isIdentifierThatStartsWithUnderscore(declaration.name);
|
|
71588
71550
|
}
|
|
71589
71551
|
function checkUnusedLocalsAndParameters(nodeWithLocals, addDiagnostic) {
|
|
71590
|
-
const unusedImports = new Map();
|
|
71591
|
-
const unusedDestructures = new Map();
|
|
71592
|
-
const unusedVariables = new Map();
|
|
71552
|
+
const unusedImports = /* @__PURE__ */ new Map();
|
|
71553
|
+
const unusedDestructures = /* @__PURE__ */ new Map();
|
|
71554
|
+
const unusedVariables = /* @__PURE__ */ new Map();
|
|
71593
71555
|
nodeWithLocals.locals.forEach((local) => {
|
|
71594
71556
|
if (local.flags & 262144 /* TypeParameter */ ? !(local.flags & 3 /* Variable */ && !(local.isReferenced & 3 /* Variable */)) : local.isReferenced || local.exportSymbol) {
|
|
71595
71557
|
return;
|
|
@@ -73042,8 +73004,8 @@ ${lanes.join("\n")}
|
|
|
73042
73004
|
if (!length(jsdocParameters))
|
|
73043
73005
|
return;
|
|
73044
73006
|
const isJs = isInJSFile(node);
|
|
73045
|
-
const parameters = new Set();
|
|
73046
|
-
const excludedParameters = new Set();
|
|
73007
|
+
const parameters = /* @__PURE__ */ new Set();
|
|
73008
|
+
const excludedParameters = /* @__PURE__ */ new Set();
|
|
73047
73009
|
forEach(node.parameters, ({ name }, index) => {
|
|
73048
73010
|
if (isIdentifier(name)) {
|
|
73049
73011
|
parameters.add(name.escapedText);
|
|
@@ -73579,7 +73541,7 @@ ${lanes.join("\n")}
|
|
|
73579
73541
|
if (!length(baseTypes)) {
|
|
73580
73542
|
return properties;
|
|
73581
73543
|
}
|
|
73582
|
-
const seen = new Map();
|
|
73544
|
+
const seen = /* @__PURE__ */ new Map();
|
|
73583
73545
|
forEach(properties, (p) => {
|
|
73584
73546
|
seen.set(p.escapedName, p);
|
|
73585
73547
|
});
|
|
@@ -73599,7 +73561,7 @@ ${lanes.join("\n")}
|
|
|
73599
73561
|
if (baseTypes.length < 2) {
|
|
73600
73562
|
return true;
|
|
73601
73563
|
}
|
|
73602
|
-
const seen = new Map();
|
|
73564
|
+
const seen = /* @__PURE__ */ new Map();
|
|
73603
73565
|
forEach(resolveDeclaredMembers(type).declaredProperties, (p) => {
|
|
73604
73566
|
seen.set(p.escapedName, { prop: p, containingType: type });
|
|
73605
73567
|
});
|
|
@@ -74806,7 +74768,7 @@ ${lanes.join("\n")}
|
|
|
74806
74768
|
const enclosingFile = getSourceFileOfNode(node);
|
|
74807
74769
|
const links = getNodeLinks(enclosingFile);
|
|
74808
74770
|
if (!(links.flags & 1 /* TypeChecked */)) {
|
|
74809
|
-
links.deferredNodes || (links.deferredNodes = new Set());
|
|
74771
|
+
links.deferredNodes || (links.deferredNodes = /* @__PURE__ */ new Set());
|
|
74810
74772
|
links.deferredNodes.add(node);
|
|
74811
74773
|
}
|
|
74812
74774
|
}
|
|
@@ -75240,7 +75202,7 @@ ${lanes.join("\n")}
|
|
|
75240
75202
|
const declarationList = mapDefined(infos, (i) => i.declaration);
|
|
75241
75203
|
const nodeListId = map(declarationList, getNodeId).join(",");
|
|
75242
75204
|
if (!symbolLinks2.filteredIndexSymbolCache) {
|
|
75243
|
-
symbolLinks2.filteredIndexSymbolCache = new Map();
|
|
75205
|
+
symbolLinks2.filteredIndexSymbolCache = /* @__PURE__ */ new Map();
|
|
75244
75206
|
}
|
|
75245
75207
|
if (symbolLinks2.filteredIndexSymbolCache.has(nodeListId)) {
|
|
75246
75208
|
links.resolvedSymbol = symbolLinks2.filteredIndexSymbolCache.get(nodeListId);
|
|
@@ -75973,7 +75935,7 @@ ${lanes.join("\n")}
|
|
|
75973
75935
|
const resolvedTypeReferenceDirectives = host.getResolvedTypeReferenceDirectives();
|
|
75974
75936
|
let fileToDirective;
|
|
75975
75937
|
if (resolvedTypeReferenceDirectives) {
|
|
75976
|
-
fileToDirective = new Map();
|
|
75938
|
+
fileToDirective = /* @__PURE__ */ new Map();
|
|
75977
75939
|
resolvedTypeReferenceDirectives.forEach((resolvedDirective, key, mode) => {
|
|
75978
75940
|
if (!resolvedDirective || !resolvedDirective.resolvedFileName) {
|
|
75979
75941
|
return;
|
|
@@ -76182,7 +76144,7 @@ ${lanes.join("\n")}
|
|
|
76182
76144
|
for (const file of host.getSourceFiles()) {
|
|
76183
76145
|
bindSourceFile(file, compilerOptions);
|
|
76184
76146
|
}
|
|
76185
|
-
amalgamatedDuplicates = new Map();
|
|
76147
|
+
amalgamatedDuplicates = /* @__PURE__ */ new Map();
|
|
76186
76148
|
let augmentations;
|
|
76187
76149
|
for (const file of host.getSourceFiles()) {
|
|
76188
76150
|
if (file.redirectInfo) {
|
|
@@ -76946,7 +76908,7 @@ ${lanes.join("\n")}
|
|
|
76946
76908
|
return !!exclamationToken && grammarErrorOnNode(exclamationToken, message);
|
|
76947
76909
|
}
|
|
76948
76910
|
function checkGrammarObjectLiteralExpression(node, inDestructuring) {
|
|
76949
|
-
const seen = new Map();
|
|
76911
|
+
const seen = /* @__PURE__ */ new Map();
|
|
76950
76912
|
for (const prop of node.properties) {
|
|
76951
76913
|
if (prop.kind === 301 /* SpreadAssignment */) {
|
|
76952
76914
|
if (inDestructuring) {
|
|
@@ -77030,7 +76992,7 @@ ${lanes.join("\n")}
|
|
|
77030
76992
|
function checkGrammarJsxElement(node) {
|
|
77031
76993
|
checkGrammarJsxName(node.tagName);
|
|
77032
76994
|
checkGrammarTypeArguments(node, node.typeArguments);
|
|
77033
|
-
const seen = new Map();
|
|
76995
|
+
const seen = /* @__PURE__ */ new Map();
|
|
77034
76996
|
for (const attr of node.attributes.properties) {
|
|
77035
76997
|
if (attr.kind === 290 /* JsxSpreadAttribute */) {
|
|
77036
76998
|
continue;
|
|
@@ -79097,7 +79059,7 @@ ${lanes.join("\n")}
|
|
|
79097
79059
|
const { enter, exit } = generatorOptions.extendedDiagnostics ? createTimer("Source Map", "beforeSourcemap", "afterSourcemap") : nullTimer;
|
|
79098
79060
|
const rawSources = [];
|
|
79099
79061
|
const sources = [];
|
|
79100
|
-
const sourceToSourceIndexMap = new Map();
|
|
79062
|
+
const sourceToSourceIndexMap = /* @__PURE__ */ new Map();
|
|
79101
79063
|
let sourcesContent;
|
|
79102
79064
|
const names = [];
|
|
79103
79065
|
let nameToNameIndexMap;
|
|
@@ -79163,7 +79125,7 @@ ${lanes.join("\n")}
|
|
|
79163
79125
|
function addName(name) {
|
|
79164
79126
|
enter();
|
|
79165
79127
|
if (!nameToNameIndexMap)
|
|
79166
|
-
nameToNameIndexMap = new Map();
|
|
79128
|
+
nameToNameIndexMap = /* @__PURE__ */ new Map();
|
|
79167
79129
|
let nameIndex = nameToNameIndexMap.get(name);
|
|
79168
79130
|
if (nameIndex === void 0) {
|
|
79169
79131
|
nameIndex = names.length;
|
|
@@ -79689,7 +79651,7 @@ ${lanes.join("\n")}
|
|
|
79689
79651
|
const externalImports = [];
|
|
79690
79652
|
const exportSpecifiers = createMultiMap();
|
|
79691
79653
|
const exportedBindings = [];
|
|
79692
|
-
const uniqueExports = new Map();
|
|
79654
|
+
const uniqueExports = /* @__PURE__ */ new Map();
|
|
79693
79655
|
let exportedNames;
|
|
79694
79656
|
let hasExportDefault = false;
|
|
79695
79657
|
let exportEquals;
|
|
@@ -81456,7 +81418,7 @@ ${lanes.join("\n")}
|
|
|
81456
81418
|
}
|
|
81457
81419
|
function recordEmittedDeclarationInScope(node) {
|
|
81458
81420
|
if (!currentScopeFirstDeclarationsOfName) {
|
|
81459
|
-
currentScopeFirstDeclarationsOfName = new Map();
|
|
81421
|
+
currentScopeFirstDeclarationsOfName = /* @__PURE__ */ new Map();
|
|
81460
81422
|
}
|
|
81461
81423
|
const name = declaredNameInScope(node);
|
|
81462
81424
|
if (!currentScopeFirstDeclarationsOfName.has(name)) {
|
|
@@ -81947,7 +81909,7 @@ ${lanes.join("\n")}
|
|
|
81947
81909
|
let pendingExpressions;
|
|
81948
81910
|
let pendingStatements;
|
|
81949
81911
|
const classLexicalEnvironmentStack = [];
|
|
81950
|
-
const classLexicalEnvironmentMap = new Map();
|
|
81912
|
+
const classLexicalEnvironmentMap = /* @__PURE__ */ new Map();
|
|
81951
81913
|
let currentClassLexicalEnvironment;
|
|
81952
81914
|
let currentClassContainer;
|
|
81953
81915
|
let currentComputedPropertyNameClassLexicalEnvironment;
|
|
@@ -83663,10 +83625,10 @@ ${lanes.join("\n")}
|
|
|
83663
83625
|
function setPrivateIdentifier(privateEnv, name, info) {
|
|
83664
83626
|
var _a2, _b;
|
|
83665
83627
|
if (isGeneratedPrivateIdentifier(name)) {
|
|
83666
|
-
(_a2 = privateEnv.generatedIdentifiers) != null ? _a2 : privateEnv.generatedIdentifiers = new Map();
|
|
83628
|
+
(_a2 = privateEnv.generatedIdentifiers) != null ? _a2 : privateEnv.generatedIdentifiers = /* @__PURE__ */ new Map();
|
|
83667
83629
|
privateEnv.generatedIdentifiers.set(getNodeForGeneratedName(name), info);
|
|
83668
83630
|
} else {
|
|
83669
|
-
(_b = privateEnv.identifiers) != null ? _b : privateEnv.identifiers = new Map();
|
|
83631
|
+
(_b = privateEnv.identifiers) != null ? _b : privateEnv.identifiers = /* @__PURE__ */ new Map();
|
|
83670
83632
|
privateEnv.identifiers.set(name.escapedText, info);
|
|
83671
83633
|
}
|
|
83672
83634
|
}
|
|
@@ -84509,7 +84471,7 @@ ${lanes.join("\n")}
|
|
|
84509
84471
|
return visitor(node);
|
|
84510
84472
|
}
|
|
84511
84473
|
function visitCatchClauseInAsyncBody(node) {
|
|
84512
|
-
const catchClauseNames = new Set();
|
|
84474
|
+
const catchClauseNames = /* @__PURE__ */ new Set();
|
|
84513
84475
|
recordDeclarationName(node.variableDeclaration, catchClauseNames);
|
|
84514
84476
|
let catchClauseUnshadowedNames;
|
|
84515
84477
|
catchClauseNames.forEach((_, escapedName) => {
|
|
@@ -84719,7 +84681,7 @@ ${lanes.join("\n")}
|
|
|
84719
84681
|
Debug.assertIsDefined(node.body);
|
|
84720
84682
|
const savedCapturedSuperProperties = capturedSuperProperties;
|
|
84721
84683
|
const savedHasSuperElementAccess = hasSuperElementAccess;
|
|
84722
|
-
capturedSuperProperties = new Set();
|
|
84684
|
+
capturedSuperProperties = /* @__PURE__ */ new Set();
|
|
84723
84685
|
hasSuperElementAccess = false;
|
|
84724
84686
|
let updated = visitFunctionBody(node.body, visitor, context);
|
|
84725
84687
|
const originalMethod = getOriginalNode(node, isFunctionLikeDeclaration);
|
|
@@ -84753,14 +84715,14 @@ ${lanes.join("\n")}
|
|
|
84753
84715
|
const isArrowFunction2 = node.kind === 216 /* ArrowFunction */;
|
|
84754
84716
|
const hasLexicalArguments = (resolver.getNodeCheckFlags(node) & 8192 /* CaptureArguments */) !== 0;
|
|
84755
84717
|
const savedEnclosingFunctionParameterNames = enclosingFunctionParameterNames;
|
|
84756
|
-
enclosingFunctionParameterNames = new Set();
|
|
84718
|
+
enclosingFunctionParameterNames = /* @__PURE__ */ new Set();
|
|
84757
84719
|
for (const parameter of node.parameters) {
|
|
84758
84720
|
recordDeclarationName(parameter, enclosingFunctionParameterNames);
|
|
84759
84721
|
}
|
|
84760
84722
|
const savedCapturedSuperProperties = capturedSuperProperties;
|
|
84761
84723
|
const savedHasSuperElementAccess = hasSuperElementAccess;
|
|
84762
84724
|
if (!isArrowFunction2) {
|
|
84763
|
-
capturedSuperProperties = new Set();
|
|
84725
|
+
capturedSuperProperties = /* @__PURE__ */ new Set();
|
|
84764
84726
|
hasSuperElementAccess = false;
|
|
84765
84727
|
}
|
|
84766
84728
|
let result;
|
|
@@ -85736,7 +85698,7 @@ ${lanes.join("\n")}
|
|
|
85736
85698
|
if (parameters) {
|
|
85737
85699
|
parameters.add(parameter);
|
|
85738
85700
|
} else if (parameter.transformFlags & 65536 /* ContainsObjectRestOrSpread */) {
|
|
85739
|
-
parameters = new Set();
|
|
85701
|
+
parameters = /* @__PURE__ */ new Set();
|
|
85740
85702
|
}
|
|
85741
85703
|
}
|
|
85742
85704
|
return parameters;
|
|
@@ -85872,7 +85834,7 @@ ${lanes.join("\n")}
|
|
|
85872
85834
|
appendObjectRestAssignmentsIfNeeded(statements, node);
|
|
85873
85835
|
const savedCapturedSuperProperties = capturedSuperProperties;
|
|
85874
85836
|
const savedHasSuperElementAccess = hasSuperElementAccess;
|
|
85875
|
-
capturedSuperProperties = new Set();
|
|
85837
|
+
capturedSuperProperties = /* @__PURE__ */ new Set();
|
|
85876
85838
|
hasSuperElementAccess = false;
|
|
85877
85839
|
const returnStatement = factory2.createReturnStatement(
|
|
85878
85840
|
emitHelpers().createAsyncGeneratorHelper(
|
|
@@ -86474,11 +86436,11 @@ ${lanes.join("\n")}
|
|
|
86474
86436
|
return existing.name;
|
|
86475
86437
|
}
|
|
86476
86438
|
if (!currentFileState.utilizedImplicitRuntimeImports) {
|
|
86477
|
-
currentFileState.utilizedImplicitRuntimeImports = new Map();
|
|
86439
|
+
currentFileState.utilizedImplicitRuntimeImports = /* @__PURE__ */ new Map();
|
|
86478
86440
|
}
|
|
86479
86441
|
let specifierSourceImports = currentFileState.utilizedImplicitRuntimeImports.get(importSource);
|
|
86480
86442
|
if (!specifierSourceImports) {
|
|
86481
|
-
specifierSourceImports = new Map();
|
|
86443
|
+
specifierSourceImports = /* @__PURE__ */ new Map();
|
|
86482
86444
|
currentFileState.utilizedImplicitRuntimeImports.set(importSource, specifierSourceImports);
|
|
86483
86445
|
}
|
|
86484
86446
|
const generatedName = factory2.createUniqueName(`_${name}`, 16 /* Optimistic */ | 32 /* FileLevel */ | 64 /* AllowNameSubstitution */);
|
|
@@ -88488,7 +88450,7 @@ ${lanes.join("\n")}
|
|
|
88488
88450
|
}
|
|
88489
88451
|
function visitLabeledStatement(node) {
|
|
88490
88452
|
if (convertedLoopState && !convertedLoopState.labels) {
|
|
88491
|
-
convertedLoopState.labels = new Map();
|
|
88453
|
+
convertedLoopState.labels = /* @__PURE__ */ new Map();
|
|
88492
88454
|
}
|
|
88493
88455
|
const statement = unwrapInnermostStatementOfLabel(node, convertedLoopState && recordLabel);
|
|
88494
88456
|
return isIterationStatement(statement, false) ? visitIterationStatement(statement, node) : factory2.restoreEnclosingLabel(visitNode(statement, visitor, isStatement, factory2.liftToBlock), node, convertedLoopState && resetLabel);
|
|
@@ -89247,12 +89209,12 @@ ${lanes.join("\n")}
|
|
|
89247
89209
|
function setLabeledJump(state, isBreak, labelText, labelMarker) {
|
|
89248
89210
|
if (isBreak) {
|
|
89249
89211
|
if (!state.labeledNonLocalBreaks) {
|
|
89250
|
-
state.labeledNonLocalBreaks = new Map();
|
|
89212
|
+
state.labeledNonLocalBreaks = /* @__PURE__ */ new Map();
|
|
89251
89213
|
}
|
|
89252
89214
|
state.labeledNonLocalBreaks.set(labelText, labelMarker);
|
|
89253
89215
|
} else {
|
|
89254
89216
|
if (!state.labeledNonLocalContinues) {
|
|
89255
|
-
state.labeledNonLocalContinues = new Map();
|
|
89217
|
+
state.labeledNonLocalContinues = /* @__PURE__ */ new Map();
|
|
89256
89218
|
}
|
|
89257
89219
|
state.labeledNonLocalContinues.set(labelText, labelMarker);
|
|
89258
89220
|
}
|
|
@@ -91101,7 +91063,7 @@ ${lanes.join("\n")}
|
|
|
91101
91063
|
const text = idText(variable.name);
|
|
91102
91064
|
name = declareLocal(text);
|
|
91103
91065
|
if (!renamedCatchVariables) {
|
|
91104
|
-
renamedCatchVariables = new Map();
|
|
91066
|
+
renamedCatchVariables = /* @__PURE__ */ new Map();
|
|
91105
91067
|
renamedCatchVariableDeclarations = [];
|
|
91106
91068
|
context.enableSubstitution(79 /* Identifier */);
|
|
91107
91069
|
}
|
|
@@ -93263,7 +93225,7 @@ ${lanes.join("\n")}
|
|
|
93263
93225
|
return updated;
|
|
93264
93226
|
}
|
|
93265
93227
|
function collectDependencyGroups(externalImports) {
|
|
93266
|
-
const groupIndices = new Map();
|
|
93228
|
+
const groupIndices = /* @__PURE__ */ new Map();
|
|
93267
93229
|
const dependencyGroups = [];
|
|
93268
93230
|
for (const externalImport of externalImports) {
|
|
93269
93231
|
const externalModuleName = getExternalModuleNameLiteral(factory2, externalImport, currentSourceFile, host, resolver, compilerOptions);
|
|
@@ -94513,7 +94475,7 @@ ${lanes.join("\n")}
|
|
|
94513
94475
|
function onEmitNode(hint, node, emitCallback) {
|
|
94514
94476
|
if (isSourceFile(node)) {
|
|
94515
94477
|
if ((isExternalModule(node) || compilerOptions.isolatedModules) && compilerOptions.importHelpers) {
|
|
94516
|
-
helperNameSubstitutions = new Map();
|
|
94478
|
+
helperNameSubstitutions = /* @__PURE__ */ new Map();
|
|
94517
94479
|
}
|
|
94518
94480
|
previousOnEmitNode(hint, node, emitCallback);
|
|
94519
94481
|
helperNameSubstitutions = void 0;
|
|
@@ -94933,7 +94895,7 @@ ${lanes.join("\n")}
|
|
|
94933
94895
|
if (!typeReferenceDirectives) {
|
|
94934
94896
|
return;
|
|
94935
94897
|
}
|
|
94936
|
-
necessaryTypeReferences = necessaryTypeReferences || new Set();
|
|
94898
|
+
necessaryTypeReferences = necessaryTypeReferences || /* @__PURE__ */ new Set();
|
|
94937
94899
|
for (const ref of typeReferenceDirectives) {
|
|
94938
94900
|
necessaryTypeReferences.add(ref);
|
|
94939
94901
|
}
|
|
@@ -95086,8 +95048,8 @@ ${lanes.join("\n")}
|
|
|
95086
95048
|
}
|
|
95087
95049
|
if (node.kind === 309 /* Bundle */) {
|
|
95088
95050
|
isBundledEmit = true;
|
|
95089
|
-
refs = new Map();
|
|
95090
|
-
libs2 = new Map();
|
|
95051
|
+
refs = /* @__PURE__ */ new Map();
|
|
95052
|
+
libs2 = /* @__PURE__ */ new Map();
|
|
95091
95053
|
let hasNoDefaultLib = false;
|
|
95092
95054
|
const bundle = factory2.createBundle(map(
|
|
95093
95055
|
node.sourceFiles,
|
|
@@ -95099,7 +95061,7 @@ ${lanes.join("\n")}
|
|
|
95099
95061
|
enclosingDeclaration = sourceFile;
|
|
95100
95062
|
lateMarkedStatements = void 0;
|
|
95101
95063
|
suppressNewDiagnosticContexts = false;
|
|
95102
|
-
lateStatementReplacementMap = new Map();
|
|
95064
|
+
lateStatementReplacementMap = /* @__PURE__ */ new Map();
|
|
95103
95065
|
getSymbolAccessibilityDiagnostic = throwDiagnostic;
|
|
95104
95066
|
needsScopeFixMarker = false;
|
|
95105
95067
|
resultHasScopeMarker = false;
|
|
@@ -95150,10 +95112,10 @@ ${lanes.join("\n")}
|
|
|
95150
95112
|
resultHasExternalModuleIndicator = false;
|
|
95151
95113
|
suppressNewDiagnosticContexts = false;
|
|
95152
95114
|
lateMarkedStatements = void 0;
|
|
95153
|
-
lateStatementReplacementMap = new Map();
|
|
95115
|
+
lateStatementReplacementMap = /* @__PURE__ */ new Map();
|
|
95154
95116
|
necessaryTypeReferences = void 0;
|
|
95155
|
-
refs = collectReferences(currentSourceFile, new Map());
|
|
95156
|
-
libs2 = collectLibs(currentSourceFile, new Map());
|
|
95117
|
+
refs = collectReferences(currentSourceFile, /* @__PURE__ */ new Map());
|
|
95118
|
+
libs2 = collectLibs(currentSourceFile, /* @__PURE__ */ new Map());
|
|
95157
95119
|
const references = [];
|
|
95158
95120
|
const outputFilePath = getDirectoryPath(normalizeSlashes(getOutputPathsFor(node, host, true).declarationFilePath));
|
|
95159
95121
|
const referenceVisitor = mapReferencesIntoArray(references, outputFilePath);
|
|
@@ -97503,7 +97465,7 @@ ${lanes.join("\n")}
|
|
|
97503
97465
|
const extendedDiagnostics = !!printerOptions.extendedDiagnostics;
|
|
97504
97466
|
const newLine = getNewLineCharacter(printerOptions);
|
|
97505
97467
|
const moduleKind = getEmitModuleKind(printerOptions);
|
|
97506
|
-
const bundledHelpers = new Map();
|
|
97468
|
+
const bundledHelpers = /* @__PURE__ */ new Map();
|
|
97507
97469
|
let currentSourceFile;
|
|
97508
97470
|
let nodeIdToGeneratedName;
|
|
97509
97471
|
let autoGeneratedIdToGeneratedName;
|
|
@@ -97757,9 +97719,9 @@ ${lanes.join("\n")}
|
|
|
97757
97719
|
function reset2() {
|
|
97758
97720
|
nodeIdToGeneratedName = [];
|
|
97759
97721
|
autoGeneratedIdToGeneratedName = [];
|
|
97760
|
-
generatedNames = new Set();
|
|
97722
|
+
generatedNames = /* @__PURE__ */ new Set();
|
|
97761
97723
|
formattedNameTempFlagsStack = [];
|
|
97762
|
-
formattedNameTempFlags = new Map();
|
|
97724
|
+
formattedNameTempFlags = /* @__PURE__ */ new Map();
|
|
97763
97725
|
privateNameTempFlagsStack = [];
|
|
97764
97726
|
privateNameTempFlags = TempFlags.Auto;
|
|
97765
97727
|
tempFlagsStack = [];
|
|
@@ -98311,7 +98273,7 @@ ${lanes.join("\n")}
|
|
|
98311
98273
|
if (moduleKind === 0 /* None */ || printerOptions.noEmitHelpers) {
|
|
98312
98274
|
return void 0;
|
|
98313
98275
|
}
|
|
98314
|
-
const bundledHelpers2 = new Map();
|
|
98276
|
+
const bundledHelpers2 = /* @__PURE__ */ new Map();
|
|
98315
98277
|
for (const sourceFile of bundle.sourceFiles) {
|
|
98316
98278
|
const shouldSkip = getExternalHelpersModuleName(sourceFile) !== void 0;
|
|
98317
98279
|
const helpers = getSortedEmitHelpers(sourceFile);
|
|
@@ -100161,7 +100123,7 @@ ${lanes.join("\n")}
|
|
|
100161
100123
|
if (isSourceFile(sourceFileOrBundle)) {
|
|
100162
100124
|
emitPrologueDirectives(sourceFileOrBundle.statements, sourceFileOrBundle);
|
|
100163
100125
|
} else {
|
|
100164
|
-
const seenPrologueDirectives = new Set();
|
|
100126
|
+
const seenPrologueDirectives = /* @__PURE__ */ new Set();
|
|
100165
100127
|
for (const prepend of sourceFileOrBundle.prepends) {
|
|
100166
100128
|
emitUnparsedPrologues(prepend.prologues, seenPrologueDirectives);
|
|
100167
100129
|
}
|
|
@@ -100172,7 +100134,7 @@ ${lanes.join("\n")}
|
|
|
100172
100134
|
}
|
|
100173
100135
|
}
|
|
100174
100136
|
function getPrologueDirectivesFromBundledSourceFiles(bundle) {
|
|
100175
|
-
const seenPrologueDirectives = new Set();
|
|
100137
|
+
const seenPrologueDirectives = /* @__PURE__ */ new Set();
|
|
100176
100138
|
let prologues;
|
|
100177
100139
|
for (let index = 0; index < bundle.sourceFiles.length; index++) {
|
|
100178
100140
|
const sourceFile = bundle.sourceFiles[index];
|
|
@@ -100832,7 +100794,7 @@ ${lanes.join("\n")}
|
|
|
100832
100794
|
}
|
|
100833
100795
|
function reserveNameInNestedScopes(name) {
|
|
100834
100796
|
if (!reservedNames || reservedNames === lastOrUndefined(reservedNamesStack)) {
|
|
100835
|
-
reservedNames = new Set();
|
|
100797
|
+
reservedNames = /* @__PURE__ */ new Set();
|
|
100836
100798
|
}
|
|
100837
100799
|
reservedNames.add(name);
|
|
100838
100800
|
}
|
|
@@ -100994,7 +100956,7 @@ ${lanes.join("\n")}
|
|
|
100994
100956
|
privateNameTempFlags = flags;
|
|
100995
100957
|
break;
|
|
100996
100958
|
default:
|
|
100997
|
-
formattedNameTempFlags != null ? formattedNameTempFlags : formattedNameTempFlags = new Map();
|
|
100959
|
+
formattedNameTempFlags != null ? formattedNameTempFlags : formattedNameTempFlags = /* @__PURE__ */ new Map();
|
|
100998
100960
|
formattedNameTempFlags.set(formattedNameKey, flags);
|
|
100999
100961
|
break;
|
|
101000
100962
|
}
|
|
@@ -101597,7 +101559,7 @@ ${lanes.join("\n")}
|
|
|
101597
101559
|
if (!host.getDirectories || !host.readDirectory) {
|
|
101598
101560
|
return void 0;
|
|
101599
101561
|
}
|
|
101600
|
-
const cachedReadDirectoryResult = new Map();
|
|
101562
|
+
const cachedReadDirectoryResult = /* @__PURE__ */ new Map();
|
|
101601
101563
|
const getCanonicalFileName = createGetCanonicalFileName(useCaseSensitiveFileNames);
|
|
101602
101564
|
return {
|
|
101603
101565
|
useCaseSensitiveFileNames,
|
|
@@ -101811,7 +101773,7 @@ ${lanes.join("\n")}
|
|
|
101811
101773
|
existing.projects.add(projectPath);
|
|
101812
101774
|
} else {
|
|
101813
101775
|
extendedConfigFilesMap.set(extendedConfigFilePath, {
|
|
101814
|
-
projects: new Set([projectPath]),
|
|
101776
|
+
projects: /* @__PURE__ */ new Set([projectPath]),
|
|
101815
101777
|
watcher: createExtendedConfigFileWatch(extendedConfigFileName, extendedConfigFilePath),
|
|
101816
101778
|
close: () => {
|
|
101817
101779
|
const existing2 = extendedConfigFilesMap.get(extendedConfigFilePath);
|
|
@@ -102124,7 +102086,7 @@ ${lanes.join("\n")}
|
|
|
102124
102086
|
};
|
|
102125
102087
|
}
|
|
102126
102088
|
function createCompilerHostWorker(options, setParentNodes, system = sys) {
|
|
102127
|
-
const existingDirectories = new Map();
|
|
102089
|
+
const existingDirectories = /* @__PURE__ */ new Map();
|
|
102128
102090
|
const getCanonicalFileName = createGetCanonicalFileName(system.useCaseSensitiveFileNames);
|
|
102129
102091
|
function directoryExists(directoryPath) {
|
|
102130
102092
|
if (existingDirectories.has(directoryPath)) {
|
|
@@ -102173,10 +102135,10 @@ ${lanes.join("\n")}
|
|
|
102173
102135
|
const originalDirectoryExists = host.directoryExists;
|
|
102174
102136
|
const originalCreateDirectory = host.createDirectory;
|
|
102175
102137
|
const originalWriteFile = host.writeFile;
|
|
102176
|
-
const readFileCache = new Map();
|
|
102177
|
-
const fileExistsCache = new Map();
|
|
102178
|
-
const directoryExistsCache = new Map();
|
|
102179
|
-
const sourceFileCache = new Map();
|
|
102138
|
+
const readFileCache = /* @__PURE__ */ new Map();
|
|
102139
|
+
const fileExistsCache = /* @__PURE__ */ new Map();
|
|
102140
|
+
const directoryExistsCache = /* @__PURE__ */ new Map();
|
|
102141
|
+
const sourceFileCache = /* @__PURE__ */ new Map();
|
|
102180
102142
|
const readFileWithCache = (fileName) => {
|
|
102181
102143
|
const key = toPath3(fileName);
|
|
102182
102144
|
const value = readFileCache.get(key);
|
|
@@ -102208,7 +102170,7 @@ ${lanes.join("\n")}
|
|
|
102208
102170
|
return value;
|
|
102209
102171
|
const sourceFile = getSourceFile(fileName, languageVersionOrOptions, onError, shouldCreateNewSourceFile);
|
|
102210
102172
|
if (sourceFile && (isDeclarationFileName(fileName) || fileExtensionIs(fileName, ".json" /* Json */))) {
|
|
102211
|
-
sourceFileCache.set(impliedNodeFormat, (forImpliedNodeFormat || new Map()).set(key, sourceFile));
|
|
102173
|
+
sourceFileCache.set(impliedNodeFormat, (forImpliedNodeFormat || /* @__PURE__ */ new Map()).set(key, sourceFile));
|
|
102212
102174
|
}
|
|
102213
102175
|
return sourceFile;
|
|
102214
102176
|
} : void 0;
|
|
@@ -102433,7 +102395,7 @@ ${lanes.join("\n")}
|
|
|
102433
102395
|
return [];
|
|
102434
102396
|
}
|
|
102435
102397
|
const resolutions = [];
|
|
102436
|
-
const cache = new Map();
|
|
102398
|
+
const cache = /* @__PURE__ */ new Map();
|
|
102437
102399
|
for (const name of names) {
|
|
102438
102400
|
let result;
|
|
102439
102401
|
const mode = getModeForFileReference(name, containingFileMode);
|
|
@@ -102518,7 +102480,7 @@ ${lanes.join("\n")}
|
|
|
102518
102480
|
return [];
|
|
102519
102481
|
}
|
|
102520
102482
|
const resolutions = [];
|
|
102521
|
-
const cache = new Map();
|
|
102483
|
+
const cache = /* @__PURE__ */ new Map();
|
|
102522
102484
|
let i = 0;
|
|
102523
102485
|
for (const entry of resolutionInfo ? resolutionInfo.names : names) {
|
|
102524
102486
|
let result;
|
|
@@ -102554,7 +102516,7 @@ ${lanes.join("\n")}
|
|
|
102554
102516
|
const result = cbResolvedRef(resolvedRef, parent2, index);
|
|
102555
102517
|
if (result || !resolvedRef)
|
|
102556
102518
|
return result;
|
|
102557
|
-
(seenResolvedRefs || (seenResolvedRefs = new Set())).add(resolvedRef.sourceFile.path);
|
|
102519
|
+
(seenResolvedRefs || (seenResolvedRefs = /* @__PURE__ */ new Set())).add(resolvedRef.sourceFile.path);
|
|
102558
102520
|
return worker(resolvedRef.commandLine.projectReferences, resolvedRef.references, resolvedRef);
|
|
102559
102521
|
});
|
|
102560
102522
|
}
|
|
@@ -102674,7 +102636,7 @@ ${lanes.join("\n")}
|
|
|
102674
102636
|
return { impliedNodeFormat, packageJsonLocations, packageJsonScope };
|
|
102675
102637
|
}
|
|
102676
102638
|
}
|
|
102677
|
-
var plainJSErrors = new Set([
|
|
102639
|
+
var plainJSErrors = /* @__PURE__ */ new Set([
|
|
102678
102640
|
Diagnostics.Cannot_redeclare_block_scoped_variable_0.code,
|
|
102679
102641
|
Diagnostics.A_module_cannot_have_multiple_default_exports.code,
|
|
102680
102642
|
Diagnostics.Another_export_default_is_here.code,
|
|
@@ -102793,7 +102755,7 @@ ${lanes.join("\n")}
|
|
|
102793
102755
|
let commonSourceDirectory;
|
|
102794
102756
|
let typeChecker;
|
|
102795
102757
|
let classifiableNames;
|
|
102796
|
-
const ambientModuleNameToUnmodifiedFileName = new Map();
|
|
102758
|
+
const ambientModuleNameToUnmodifiedFileName = /* @__PURE__ */ new Map();
|
|
102797
102759
|
let fileReasons = createMultiMap();
|
|
102798
102760
|
const cachedBindAndCheckDiagnosticsForFile = {};
|
|
102799
102761
|
const cachedDeclarationDiagnosticsForFile = {};
|
|
@@ -102801,8 +102763,8 @@ ${lanes.join("\n")}
|
|
|
102801
102763
|
let fileProcessingDiagnostics;
|
|
102802
102764
|
const maxNodeModuleJsDepth = typeof options.maxNodeModuleJsDepth === "number" ? options.maxNodeModuleJsDepth : 0;
|
|
102803
102765
|
let currentNodeModulesDepth = 0;
|
|
102804
|
-
const modulesWithElidedImports = new Map();
|
|
102805
|
-
const sourceFilesFoundSearchingNodeModules = new Map();
|
|
102766
|
+
const modulesWithElidedImports = /* @__PURE__ */ new Map();
|
|
102767
|
+
const sourceFilesFoundSearchingNodeModules = /* @__PURE__ */ new Map();
|
|
102806
102768
|
(_a2 = tracing) == null ? void 0 : _a2.push(tracing.Phase.Program, "createProgram", { configFilePath: options.configFilePath, rootDir: options.rootDir }, true);
|
|
102807
102769
|
mark("beforeProgram");
|
|
102808
102770
|
const host = createProgramOptions.host || createCompilerHost(options);
|
|
@@ -102814,7 +102776,7 @@ ${lanes.join("\n")}
|
|
|
102814
102776
|
const currentDirectory = host.getCurrentDirectory();
|
|
102815
102777
|
const supportedExtensions = getSupportedExtensions(options);
|
|
102816
102778
|
const supportedExtensionsWithJsonIfResolveJsonModule = getSupportedExtensionsWithJsonIfResolveJsonModule(options, supportedExtensions);
|
|
102817
|
-
const hasEmitBlockingDiagnostics = new Map();
|
|
102779
|
+
const hasEmitBlockingDiagnostics = /* @__PURE__ */ new Map();
|
|
102818
102780
|
let _compilerOptionsObjectLiteralSyntax;
|
|
102819
102781
|
let moduleResolutionCache;
|
|
102820
102782
|
let typeReferenceDirectiveResolutionCache;
|
|
@@ -102862,13 +102824,13 @@ ${lanes.join("\n")}
|
|
|
102862
102824
|
).resolvedTypeReferenceDirective;
|
|
102863
102825
|
actualResolveTypeReferenceDirectiveNamesWorker = (typeReferenceDirectiveNames, containingFile, redirectedReference, containingFileMode) => loadWithTypeDirectiveCache(Debug.checkEachDefined(typeReferenceDirectiveNames), containingFile, redirectedReference, containingFileMode, loader);
|
|
102864
102826
|
}
|
|
102865
|
-
const packageIdToSourceFile = new Map();
|
|
102866
|
-
let sourceFileToPackageName = new Map();
|
|
102827
|
+
const packageIdToSourceFile = /* @__PURE__ */ new Map();
|
|
102828
|
+
let sourceFileToPackageName = /* @__PURE__ */ new Map();
|
|
102867
102829
|
let redirectTargetsMap = createMultiMap();
|
|
102868
102830
|
let usesUriStyleNodeCoreModules = false;
|
|
102869
|
-
const filesByName = new Map();
|
|
102831
|
+
const filesByName = /* @__PURE__ */ new Map();
|
|
102870
102832
|
let missingFilePaths;
|
|
102871
|
-
const filesByNameIgnoreCase = host.useCaseSensitiveFileNames() ? new Map() : void 0;
|
|
102833
|
+
const filesByNameIgnoreCase = host.useCaseSensitiveFileNames() ? /* @__PURE__ */ new Map() : void 0;
|
|
102872
102834
|
let resolvedProjectReferences;
|
|
102873
102835
|
let projectReferenceRedirects;
|
|
102874
102836
|
let mapFromFileToProjectReferenceRedirects;
|
|
@@ -103177,7 +103139,7 @@ ${lanes.join("\n")}
|
|
|
103177
103139
|
var _a3;
|
|
103178
103140
|
if (!classifiableNames) {
|
|
103179
103141
|
getTypeChecker();
|
|
103180
|
-
classifiableNames = new Set();
|
|
103142
|
+
classifiableNames = /* @__PURE__ */ new Set();
|
|
103181
103143
|
for (const sourceFile of files) {
|
|
103182
103144
|
(_a3 = sourceFile.classifiableNames) == null ? void 0 : _a3.forEach((value) => classifiableNames.add(value));
|
|
103183
103145
|
}
|
|
@@ -103386,7 +103348,7 @@ ${lanes.join("\n")}
|
|
|
103386
103348
|
SeenPackageName2[SeenPackageName2["Exists"] = 0] = "Exists";
|
|
103387
103349
|
SeenPackageName2[SeenPackageName2["Modified"] = 1] = "Modified";
|
|
103388
103350
|
})(SeenPackageName || (SeenPackageName = {}));
|
|
103389
|
-
const seenPackageNames = new Map();
|
|
103351
|
+
const seenPackageNames = /* @__PURE__ */ new Map();
|
|
103390
103352
|
for (const oldSourceFile of oldSourceFiles) {
|
|
103391
103353
|
const sourceFileOptions = getCreateSourceFileOptions(oldSourceFile.fileName, moduleResolutionCache, host, options);
|
|
103392
103354
|
let newSourceFile = host.getSourceFileByPath ? host.getSourceFileByPath(oldSourceFile.fileName, oldSourceFile.resolvedPath, sourceFileOptions, void 0, shouldCreateNewSourceFile || sourceFileOptions.impliedNodeFormat !== oldSourceFile.impliedNodeFormat) : host.getSourceFile(oldSourceFile.fileName, sourceFileOptions, void 0, shouldCreateNewSourceFile || sourceFileOptions.impliedNodeFormat !== oldSourceFile.impliedNodeFormat);
|
|
@@ -103989,7 +103951,7 @@ ${lanes.join("\n")}
|
|
|
103989
103951
|
}
|
|
103990
103952
|
const result = getDiagnostics2(sourceFile, cancellationToken);
|
|
103991
103953
|
if (sourceFile) {
|
|
103992
|
-
(cache.perFile || (cache.perFile = new Map())).set(sourceFile.path, result);
|
|
103954
|
+
(cache.perFile || (cache.perFile = /* @__PURE__ */ new Map())).set(sourceFile.path, result);
|
|
103993
103955
|
} else {
|
|
103994
103956
|
cache.allDiagnostics = result;
|
|
103995
103957
|
}
|
|
@@ -104397,7 +104359,7 @@ ${lanes.join("\n")}
|
|
|
104397
104359
|
}
|
|
104398
104360
|
function getResolvedProjectReferenceToRedirect(fileName) {
|
|
104399
104361
|
if (mapFromFileToProjectReferenceRedirects === void 0) {
|
|
104400
|
-
mapFromFileToProjectReferenceRedirects = new Map();
|
|
104362
|
+
mapFromFileToProjectReferenceRedirects = /* @__PURE__ */ new Map();
|
|
104401
104363
|
forEachResolvedProjectReference2((referencedProject) => {
|
|
104402
104364
|
if (toPath3(options.configFilePath) !== referencedProject.sourceFile.path) {
|
|
104403
104365
|
referencedProject.commandLine.fileNames.forEach((f) => mapFromFileToProjectReferenceRedirects.set(toPath3(f), referencedProject.sourceFile.path));
|
|
@@ -104414,7 +104376,7 @@ ${lanes.join("\n")}
|
|
|
104414
104376
|
if (!isDeclarationFileName(path))
|
|
104415
104377
|
return void 0;
|
|
104416
104378
|
if (mapFromToProjectReferenceRedirectSource === void 0) {
|
|
104417
|
-
mapFromToProjectReferenceRedirectSource = new Map();
|
|
104379
|
+
mapFromToProjectReferenceRedirectSource = /* @__PURE__ */ new Map();
|
|
104418
104380
|
forEachResolvedProjectReference2((resolvedRef) => {
|
|
104419
104381
|
const out = outFile(resolvedRef.commandLine.options);
|
|
104420
104382
|
if (out) {
|
|
@@ -104615,7 +104577,7 @@ ${lanes.join("\n")}
|
|
|
104615
104577
|
}
|
|
104616
104578
|
function parseProjectReferenceConfigFile(ref) {
|
|
104617
104579
|
if (!projectReferenceRedirects) {
|
|
104618
|
-
projectReferenceRedirects = new Map();
|
|
104580
|
+
projectReferenceRedirects = /* @__PURE__ */ new Map();
|
|
104619
104581
|
}
|
|
104620
104582
|
const refPath = resolveProjectReferencePath(ref);
|
|
104621
104583
|
const sourceFilePath = toPath3(refPath);
|
|
@@ -104873,7 +104835,7 @@ ${lanes.join("\n")}
|
|
|
104873
104835
|
}
|
|
104874
104836
|
if (!options.noEmit && !options.suppressOutputPathCheck) {
|
|
104875
104837
|
const emitHost = getEmitHost();
|
|
104876
|
-
const emitFilesSeen = new Set();
|
|
104838
|
+
const emitFilesSeen = /* @__PURE__ */ new Set();
|
|
104877
104839
|
forEachEmittedFile(emitHost, (emitFileNames) => {
|
|
104878
104840
|
if (!options.emitDeclarationOnly) {
|
|
104879
104841
|
verifyEmitFilePath(emitFileNames.jsFilePath, emitFilesSeen);
|
|
@@ -105229,7 +105191,7 @@ ${lanes.join("\n")}
|
|
|
105229
105191
|
if (!host.getResolvedProjectReferences())
|
|
105230
105192
|
return false;
|
|
105231
105193
|
if (!setOfDeclarationDirectories) {
|
|
105232
|
-
setOfDeclarationDirectories = new Set();
|
|
105194
|
+
setOfDeclarationDirectories = /* @__PURE__ */ new Set();
|
|
105233
105195
|
host.forEachResolvedProjectReference((ref) => {
|
|
105234
105196
|
const out = outFile(ref.commandLine.options);
|
|
105235
105197
|
if (out) {
|
|
@@ -105468,7 +105430,7 @@ ${lanes.join("\n")}
|
|
|
105468
105430
|
getValues: (k) => forward.get(k),
|
|
105469
105431
|
keys: () => forward.keys(),
|
|
105470
105432
|
deleteKey: (k) => {
|
|
105471
|
-
(deleted || (deleted = new Set())).add(k);
|
|
105433
|
+
(deleted || (deleted = /* @__PURE__ */ new Set())).add(k);
|
|
105472
105434
|
const set = forward.get(k);
|
|
105473
105435
|
if (!set) {
|
|
105474
105436
|
return false;
|
|
@@ -105496,13 +105458,13 @@ ${lanes.join("\n")}
|
|
|
105496
105458
|
};
|
|
105497
105459
|
return map2;
|
|
105498
105460
|
}
|
|
105499
|
-
return create2(new Map(), new Map(), void 0);
|
|
105461
|
+
return create2(/* @__PURE__ */ new Map(), /* @__PURE__ */ new Map(), void 0);
|
|
105500
105462
|
}
|
|
105501
105463
|
BuilderState2.createManyToManyPathMap = createManyToManyPathMap;
|
|
105502
105464
|
function addToMultimap(map2, k, v) {
|
|
105503
105465
|
let set = map2.get(k);
|
|
105504
105466
|
if (!set) {
|
|
105505
|
-
set = new Set();
|
|
105467
|
+
set = /* @__PURE__ */ new Set();
|
|
105506
105468
|
map2.set(k, set);
|
|
105507
105469
|
}
|
|
105508
105470
|
set.add(v);
|
|
@@ -105585,7 +105547,7 @@ ${lanes.join("\n")}
|
|
|
105585
105547
|
}
|
|
105586
105548
|
}
|
|
105587
105549
|
function addReferencedFile(referencedPath) {
|
|
105588
|
-
(referencedFiles || (referencedFiles = new Set())).add(referencedPath);
|
|
105550
|
+
(referencedFiles || (referencedFiles = /* @__PURE__ */ new Set())).add(referencedPath);
|
|
105589
105551
|
}
|
|
105590
105552
|
}
|
|
105591
105553
|
function canReuseOldState(newReferencedMap, oldState) {
|
|
@@ -105594,7 +105556,7 @@ ${lanes.join("\n")}
|
|
|
105594
105556
|
BuilderState2.canReuseOldState = canReuseOldState;
|
|
105595
105557
|
function create(newProgram, getCanonicalFileName, oldState, disableUseFileVersionAsSignature) {
|
|
105596
105558
|
var _a2, _b, _c;
|
|
105597
|
-
const fileInfos = new Map();
|
|
105559
|
+
const fileInfos = /* @__PURE__ */ new Map();
|
|
105598
105560
|
const options = newProgram.getCompilerOptions();
|
|
105599
105561
|
const isOutFile = outFile(options);
|
|
105600
105562
|
const referencedMap = options.module !== 0 /* None */ && !isOutFile ? createManyToManyPathMap() : void 0;
|
|
@@ -105666,7 +105628,7 @@ ${lanes.join("\n")}
|
|
|
105666
105628
|
BuilderState2.getFilesAffectedByWithOldState = getFilesAffectedByWithOldState;
|
|
105667
105629
|
function updateSignatureOfFile(state, signature, path) {
|
|
105668
105630
|
state.fileInfos.get(path).signature = signature;
|
|
105669
|
-
(state.hasCalledUpdateShapeSignature || (state.hasCalledUpdateShapeSignature = new Set())).add(path);
|
|
105631
|
+
(state.hasCalledUpdateShapeSignature || (state.hasCalledUpdateShapeSignature = /* @__PURE__ */ new Set())).add(path);
|
|
105670
105632
|
}
|
|
105671
105633
|
BuilderState2.updateSignatureOfFile = updateSignatureOfFile;
|
|
105672
105634
|
function updateShapeSignature(state, programOfThisState, sourceFile, cancellationToken, computeHash, getCanonicalFileName, useFileVersionAsSignature = state.useFileVersionAsSignature) {
|
|
@@ -105701,7 +105663,7 @@ ${lanes.join("\n")}
|
|
|
105701
105663
|
if (latestSignature === void 0) {
|
|
105702
105664
|
latestSignature = sourceFile.version;
|
|
105703
105665
|
if (state.exportedModulesMap && latestSignature !== prevSignature) {
|
|
105704
|
-
(state.oldExportedModulesMap || (state.oldExportedModulesMap = new Map())).set(sourceFile.resolvedPath, state.exportedModulesMap.getValues(sourceFile.resolvedPath) || false);
|
|
105666
|
+
(state.oldExportedModulesMap || (state.oldExportedModulesMap = /* @__PURE__ */ new Map())).set(sourceFile.resolvedPath, state.exportedModulesMap.getValues(sourceFile.resolvedPath) || false);
|
|
105705
105667
|
const references = state.referencedMap ? state.referencedMap.getValues(sourceFile.resolvedPath) : void 0;
|
|
105706
105668
|
if (references) {
|
|
105707
105669
|
state.exportedModulesMap.set(sourceFile.resolvedPath, references);
|
|
@@ -105710,8 +105672,8 @@ ${lanes.join("\n")}
|
|
|
105710
105672
|
}
|
|
105711
105673
|
}
|
|
105712
105674
|
}
|
|
105713
|
-
(state.oldSignatures || (state.oldSignatures = new Map())).set(sourceFile.resolvedPath, prevSignature || false);
|
|
105714
|
-
(state.hasCalledUpdateShapeSignature || (state.hasCalledUpdateShapeSignature = new Set())).add(sourceFile.resolvedPath);
|
|
105675
|
+
(state.oldSignatures || (state.oldSignatures = /* @__PURE__ */ new Map())).set(sourceFile.resolvedPath, prevSignature || false);
|
|
105676
|
+
(state.hasCalledUpdateShapeSignature || (state.hasCalledUpdateShapeSignature = /* @__PURE__ */ new Set())).add(sourceFile.resolvedPath);
|
|
105715
105677
|
info.signature = latestSignature;
|
|
105716
105678
|
return latestSignature !== prevSignature;
|
|
105717
105679
|
}
|
|
@@ -105719,7 +105681,7 @@ ${lanes.join("\n")}
|
|
|
105719
105681
|
function updateExportedModules(state, sourceFile, exportedModulesFromDeclarationEmit) {
|
|
105720
105682
|
if (!state.exportedModulesMap)
|
|
105721
105683
|
return;
|
|
105722
|
-
(state.oldExportedModulesMap || (state.oldExportedModulesMap = new Map())).set(sourceFile.resolvedPath, state.exportedModulesMap.getValues(sourceFile.resolvedPath) || false);
|
|
105684
|
+
(state.oldExportedModulesMap || (state.oldExportedModulesMap = /* @__PURE__ */ new Map())).set(sourceFile.resolvedPath, state.exportedModulesMap.getValues(sourceFile.resolvedPath) || false);
|
|
105723
105685
|
if (!exportedModulesFromDeclarationEmit) {
|
|
105724
105686
|
state.exportedModulesMap.deleteKey(sourceFile.resolvedPath);
|
|
105725
105687
|
return;
|
|
@@ -105734,7 +105696,7 @@ ${lanes.join("\n")}
|
|
|
105734
105696
|
function addExportedModule(exportedModulePaths) {
|
|
105735
105697
|
if (exportedModulePaths == null ? void 0 : exportedModulePaths.length) {
|
|
105736
105698
|
if (!exportedModules) {
|
|
105737
|
-
exportedModules = new Set();
|
|
105699
|
+
exportedModules = /* @__PURE__ */ new Set();
|
|
105738
105700
|
}
|
|
105739
105701
|
exportedModulePaths.forEach((path) => exportedModules.add(path));
|
|
105740
105702
|
}
|
|
@@ -105749,7 +105711,7 @@ ${lanes.join("\n")}
|
|
|
105749
105711
|
if (!state.referencedMap || isFileAffectingGlobalScope(sourceFile)) {
|
|
105750
105712
|
return getAllFileNames(state, programOfThisState);
|
|
105751
105713
|
}
|
|
105752
|
-
const seenMap = new Set();
|
|
105714
|
+
const seenMap = /* @__PURE__ */ new Set();
|
|
105753
105715
|
const queue = [sourceFile.resolvedPath];
|
|
105754
105716
|
while (queue.length) {
|
|
105755
105717
|
const path = queue.pop();
|
|
@@ -105832,7 +105794,7 @@ ${lanes.join("\n")}
|
|
|
105832
105794
|
if (compilerOptions && (compilerOptions.isolatedModules || outFile(compilerOptions))) {
|
|
105833
105795
|
return [sourceFileWithUpdatedShape];
|
|
105834
105796
|
}
|
|
105835
|
-
const seenFileNamesMap = new Map();
|
|
105797
|
+
const seenFileNamesMap = /* @__PURE__ */ new Map();
|
|
105836
105798
|
seenFileNamesMap.set(sourceFileWithUpdatedShape.resolvedPath, sourceFileWithUpdatedShape);
|
|
105837
105799
|
const queue = getReferencedByPaths(state, sourceFileWithUpdatedShape.resolvedPath);
|
|
105838
105800
|
while (queue.length > 0) {
|
|
@@ -105902,11 +105864,11 @@ ${lanes.join("\n")}
|
|
|
105902
105864
|
state.compilerOptions = compilerOptions;
|
|
105903
105865
|
const outFilePath = outFile(compilerOptions);
|
|
105904
105866
|
if (!outFilePath) {
|
|
105905
|
-
state.semanticDiagnosticsPerFile = new Map();
|
|
105867
|
+
state.semanticDiagnosticsPerFile = /* @__PURE__ */ new Map();
|
|
105906
105868
|
} else if (compilerOptions.composite && (oldState == null ? void 0 : oldState.outSignature) && outFilePath === outFile(oldState == null ? void 0 : oldState.compilerOptions)) {
|
|
105907
105869
|
state.outSignature = oldState.outSignature && getEmitSignatureFromOldSignature(compilerOptions, oldState.compilerOptions, oldState.outSignature);
|
|
105908
105870
|
}
|
|
105909
|
-
state.changedFilesSet = new Set();
|
|
105871
|
+
state.changedFilesSet = /* @__PURE__ */ new Set();
|
|
105910
105872
|
state.latestChangedDtsFile = compilerOptions.composite ? oldState == null ? void 0 : oldState.latestChangedDtsFile : void 0;
|
|
105911
105873
|
const useOldState = BuilderState.canReuseOldState(state.referencedMap, oldState);
|
|
105912
105874
|
const oldCompilerOptions = useOldState ? oldState.compilerOptions : void 0;
|
|
@@ -105916,7 +105878,7 @@ ${lanes.join("\n")}
|
|
|
105916
105878
|
(_a2 = oldState.changedFilesSet) == null ? void 0 : _a2.forEach((value) => state.changedFilesSet.add(value));
|
|
105917
105879
|
if (!outFilePath && ((_b = oldState.affectedFilesPendingEmit) == null ? void 0 : _b.size)) {
|
|
105918
105880
|
state.affectedFilesPendingEmit = new Map(oldState.affectedFilesPendingEmit);
|
|
105919
|
-
state.seenAffectedFiles = new Set();
|
|
105881
|
+
state.seenAffectedFiles = /* @__PURE__ */ new Set();
|
|
105920
105882
|
}
|
|
105921
105883
|
state.programEmitPending = oldState.programEmitPending;
|
|
105922
105884
|
} else {
|
|
@@ -105942,7 +105904,7 @@ ${lanes.join("\n")}
|
|
|
105942
105904
|
if (diagnostics) {
|
|
105943
105905
|
state.semanticDiagnosticsPerFile.set(sourceFilePath, oldState.hasReusableDiagnostic ? convertToDiagnostics(diagnostics, newProgram, getCanonicalFileName) : diagnostics);
|
|
105944
105906
|
if (!state.semanticDiagnosticsFromOldState) {
|
|
105945
|
-
state.semanticDiagnosticsFromOldState = new Set();
|
|
105907
|
+
state.semanticDiagnosticsFromOldState = /* @__PURE__ */ new Set();
|
|
105946
105908
|
}
|
|
105947
105909
|
state.semanticDiagnosticsFromOldState.add(sourceFilePath);
|
|
105948
105910
|
}
|
|
@@ -105950,11 +105912,18 @@ ${lanes.join("\n")}
|
|
|
105950
105912
|
if (canCopyEmitSignatures) {
|
|
105951
105913
|
const oldEmitSignature = oldState.emitSignatures.get(sourceFilePath);
|
|
105952
105914
|
if (oldEmitSignature) {
|
|
105953
|
-
((_a3 = state.emitSignatures) != null ? _a3 : state.emitSignatures = new Map()).set(sourceFilePath, getEmitSignatureFromOldSignature(compilerOptions, oldState.compilerOptions, oldEmitSignature));
|
|
105915
|
+
((_a3 = state.emitSignatures) != null ? _a3 : state.emitSignatures = /* @__PURE__ */ new Map()).set(sourceFilePath, getEmitSignatureFromOldSignature(compilerOptions, oldState.compilerOptions, oldEmitSignature));
|
|
105954
105916
|
}
|
|
105955
105917
|
}
|
|
105956
105918
|
});
|
|
105957
|
-
if (useOldState && forEachEntry(oldState.fileInfos, (info, sourceFilePath) =>
|
|
105919
|
+
if (useOldState && forEachEntry(oldState.fileInfos, (info, sourceFilePath) => {
|
|
105920
|
+
if (state.fileInfos.has(sourceFilePath))
|
|
105921
|
+
return false;
|
|
105922
|
+
if (outFilePath || info.affectsGlobalScope)
|
|
105923
|
+
return true;
|
|
105924
|
+
state.buildInfoEmitPending = true;
|
|
105925
|
+
return false;
|
|
105926
|
+
})) {
|
|
105958
105927
|
BuilderState.getAllFilesExcludingDefaultLibraryFile(state, newProgram, void 0).forEach((file) => addFileToChangeSet(state, file.resolvedPath));
|
|
105959
105928
|
} else if (oldCompilerOptions) {
|
|
105960
105929
|
const pendingEmitKind = compilerOptionsAffectEmit(compilerOptions, oldCompilerOptions) ? getBuilderFileEmit(compilerOptions) : getPendingEmitKind(compilerOptions, oldCompilerOptions);
|
|
@@ -105970,7 +105939,7 @@ ${lanes.join("\n")}
|
|
|
105970
105939
|
}
|
|
105971
105940
|
});
|
|
105972
105941
|
Debug.assert(!state.seenAffectedFiles || !state.seenAffectedFiles.size);
|
|
105973
|
-
state.seenAffectedFiles = state.seenAffectedFiles || new Set();
|
|
105942
|
+
state.seenAffectedFiles = state.seenAffectedFiles || /* @__PURE__ */ new Set();
|
|
105974
105943
|
state.buildInfoEmitPending = true;
|
|
105975
105944
|
} else {
|
|
105976
105945
|
state.programEmitPending = state.programEmitPending ? state.programEmitPending | pendingEmitKind : pendingEmitKind;
|
|
@@ -106101,7 +106070,7 @@ ${lanes.join("\n")}
|
|
|
106101
106070
|
state.currentChangedFilePath = nextKey.value;
|
|
106102
106071
|
state.affectedFilesIndex = 0;
|
|
106103
106072
|
if (!state.seenAffectedFiles)
|
|
106104
|
-
state.seenAffectedFiles = new Set();
|
|
106073
|
+
state.seenAffectedFiles = /* @__PURE__ */ new Set();
|
|
106105
106074
|
}
|
|
106106
106075
|
}
|
|
106107
106076
|
function clearAffectedFilesPendingEmit(state, emitOnlyDtsFiles) {
|
|
@@ -106229,7 +106198,7 @@ ${lanes.join("\n")}
|
|
|
106229
106198
|
if (!isChangedSignature(state, affectedFile.resolvedPath))
|
|
106230
106199
|
return;
|
|
106231
106200
|
if (state.compilerOptions.isolatedModules) {
|
|
106232
|
-
const seenFileNamesMap = new Map();
|
|
106201
|
+
const seenFileNamesMap = /* @__PURE__ */ new Map();
|
|
106233
106202
|
seenFileNamesMap.set(affectedFile.resolvedPath, true);
|
|
106234
106203
|
const queue = BuilderState.getReferencedByPaths(state, affectedFile.resolvedPath);
|
|
106235
106204
|
while (queue.length > 0) {
|
|
@@ -106246,7 +106215,7 @@ ${lanes.join("\n")}
|
|
|
106246
106215
|
}
|
|
106247
106216
|
}
|
|
106248
106217
|
}
|
|
106249
|
-
const seenFileAndExportsOfFile = new Set();
|
|
106218
|
+
const seenFileAndExportsOfFile = /* @__PURE__ */ new Set();
|
|
106250
106219
|
(_a2 = state.exportedModulesMap.getKeys(affectedFile.resolvedPath)) == null ? void 0 : _a2.forEach((exportedFromPath) => {
|
|
106251
106220
|
if (handleDtsMayChangeOfGlobalScope(state, exportedFromPath, cancellationToken, computeHash, getCanonicalFileName, host))
|
|
106252
106221
|
return true;
|
|
@@ -106324,7 +106293,7 @@ ${lanes.join("\n")}
|
|
|
106324
106293
|
const buildInfoDirectory = getDirectoryPath(getNormalizedAbsolutePath(getTsBuildInfoEmitOutputFilePath(state.compilerOptions), currentDirectory));
|
|
106325
106294
|
const latestChangedDtsFile = state.latestChangedDtsFile ? relativeToBuildInfoEnsuringAbsolutePath(state.latestChangedDtsFile) : void 0;
|
|
106326
106295
|
const fileNames = [];
|
|
106327
|
-
const fileNameToFileId = new Map();
|
|
106296
|
+
const fileNameToFileId = /* @__PURE__ */ new Map();
|
|
106328
106297
|
if (outFile(state.compilerOptions)) {
|
|
106329
106298
|
const fileInfos2 = arrayFrom(state.fileInfos.entries(), ([key, value]) => {
|
|
106330
106299
|
toFileId(key);
|
|
@@ -106401,7 +106370,7 @@ ${lanes.join("\n")}
|
|
|
106401
106370
|
let affectedFilesPendingEmit;
|
|
106402
106371
|
if ((_c = state.affectedFilesPendingEmit) == null ? void 0 : _c.size) {
|
|
106403
106372
|
const fullEmitForOptions = getBuilderFileEmit(state.compilerOptions);
|
|
106404
|
-
const seenFiles = new Set();
|
|
106373
|
+
const seenFiles = /* @__PURE__ */ new Set();
|
|
106405
106374
|
for (const path of arrayFrom(state.affectedFilesPendingEmit.keys()).sort(compareStringsCaseSensitive)) {
|
|
106406
106375
|
if (tryAddToSet(seenFiles, path)) {
|
|
106407
106376
|
const file = state.program.getSourceFileByPath(path);
|
|
@@ -106454,7 +106423,7 @@ ${lanes.join("\n")}
|
|
|
106454
106423
|
let fileIdListId = fileNamesToFileIdListId == null ? void 0 : fileNamesToFileIdListId.get(key);
|
|
106455
106424
|
if (fileIdListId === void 0) {
|
|
106456
106425
|
(fileIdsList || (fileIdsList = [])).push(fileIds);
|
|
106457
|
-
(fileNamesToFileIdListId || (fileNamesToFileIdListId = new Map())).set(key, fileIdListId = fileIdsList.length);
|
|
106426
|
+
(fileNamesToFileIdListId || (fileNamesToFileIdListId = /* @__PURE__ */ new Map())).set(key, fileIdListId = fileIdsList.length);
|
|
106458
106427
|
}
|
|
106459
106428
|
return fileIdListId;
|
|
106460
106429
|
}
|
|
@@ -106660,11 +106629,11 @@ ${lanes.join("\n")}
|
|
|
106660
106629
|
state.affectedFilesIndex++;
|
|
106661
106630
|
state.buildInfoEmitPending = true;
|
|
106662
106631
|
const existing = ((_a2 = state.seenEmittedFiles) == null ? void 0 : _a2.get(affectedSourceFile.resolvedPath)) || 0 /* None */;
|
|
106663
|
-
((_b = state.seenEmittedFiles) != null ? _b : state.seenEmittedFiles = new Map()).set(affectedSourceFile.resolvedPath, emitKind | existing);
|
|
106632
|
+
((_b = state.seenEmittedFiles) != null ? _b : state.seenEmittedFiles = /* @__PURE__ */ new Map()).set(affectedSourceFile.resolvedPath, emitKind | existing);
|
|
106664
106633
|
const existingPending = ((_c = state.affectedFilesPendingEmit) == null ? void 0 : _c.get(affectedSourceFile.resolvedPath)) || programEmitKind;
|
|
106665
106634
|
const pendingKind = getPendingEmitKind(existingPending, emitKind | existing);
|
|
106666
106635
|
if (pendingKind)
|
|
106667
|
-
((_d = state.affectedFilesPendingEmit) != null ? _d : state.affectedFilesPendingEmit = new Map()).set(affectedSourceFile.resolvedPath, pendingKind);
|
|
106636
|
+
((_d = state.affectedFilesPendingEmit) != null ? _d : state.affectedFilesPendingEmit = /* @__PURE__ */ new Map()).set(affectedSourceFile.resolvedPath, pendingKind);
|
|
106668
106637
|
else
|
|
106669
106638
|
(_e = state.affectedFilesPendingEmit) == null ? void 0 : _e.delete(affectedSourceFile.resolvedPath);
|
|
106670
106639
|
} else {
|
|
@@ -106696,13 +106665,13 @@ ${lanes.join("\n")}
|
|
|
106696
106665
|
emitSignature = signature;
|
|
106697
106666
|
if (signature !== file.version) {
|
|
106698
106667
|
if (host.storeFilesChangingSignatureDuringEmit)
|
|
106699
|
-
((_b = state.filesChangingSignature) != null ? _b : state.filesChangingSignature = new Set()).add(file.resolvedPath);
|
|
106668
|
+
((_b = state.filesChangingSignature) != null ? _b : state.filesChangingSignature = /* @__PURE__ */ new Set()).add(file.resolvedPath);
|
|
106700
106669
|
if (state.exportedModulesMap)
|
|
106701
106670
|
BuilderState.updateExportedModules(state, file, file.exportedModulesFromDeclarationEmit);
|
|
106702
106671
|
if (state.affectedFiles) {
|
|
106703
106672
|
const existing = (_c = state.oldSignatures) == null ? void 0 : _c.get(file.resolvedPath);
|
|
106704
106673
|
if (existing === void 0)
|
|
106705
|
-
((_d = state.oldSignatures) != null ? _d : state.oldSignatures = new Map()).set(file.resolvedPath, info.signature || false);
|
|
106674
|
+
((_d = state.oldSignatures) != null ? _d : state.oldSignatures = /* @__PURE__ */ new Map()).set(file.resolvedPath, info.signature || false);
|
|
106706
106675
|
info.signature = signature;
|
|
106707
106676
|
} else {
|
|
106708
106677
|
info.signature = signature;
|
|
@@ -106716,7 +106685,7 @@ ${lanes.join("\n")}
|
|
|
106716
106685
|
emitSignature = handleNewSignature((_f = state.emitSignatures) == null ? void 0 : _f.get(filePath), emitSignature);
|
|
106717
106686
|
if (!emitSignature)
|
|
106718
106687
|
return;
|
|
106719
|
-
((_g = state.emitSignatures) != null ? _g : state.emitSignatures = new Map()).set(filePath, emitSignature);
|
|
106688
|
+
((_g = state.emitSignatures) != null ? _g : state.emitSignatures = /* @__PURE__ */ new Map()).set(filePath, emitSignature);
|
|
106720
106689
|
}
|
|
106721
106690
|
} else if (state.compilerOptions.composite) {
|
|
106722
106691
|
const newSignature = handleNewSignature(state.outSignature, void 0);
|
|
@@ -106833,7 +106802,7 @@ ${lanes.join("\n")}
|
|
|
106833
106802
|
function addToAffectedFilesPendingEmit(state, affectedFilePendingEmit, kind) {
|
|
106834
106803
|
var _a2, _b;
|
|
106835
106804
|
const existingKind = ((_a2 = state.affectedFilesPendingEmit) == null ? void 0 : _a2.get(affectedFilePendingEmit)) || 0 /* None */;
|
|
106836
|
-
((_b = state.affectedFilesPendingEmit) != null ? _b : state.affectedFilesPendingEmit = new Map()).set(affectedFilePendingEmit, existingKind | kind);
|
|
106805
|
+
((_b = state.affectedFilesPendingEmit) != null ? _b : state.affectedFilesPendingEmit = /* @__PURE__ */ new Map()).set(affectedFilePendingEmit, existingKind | kind);
|
|
106837
106806
|
}
|
|
106838
106807
|
function toBuilderStateFileInfoForMultiEmit(fileInfo) {
|
|
106839
106808
|
return isString(fileInfo) ? { version: fileInfo, signature: fileInfo, affectsGlobalScope: void 0, impliedFormat: void 0 } : isString(fileInfo.signature) ? fileInfo : { version: fileInfo.version, signature: fileInfo.signature === false ? void 0 : fileInfo.version, affectsGlobalScope: fileInfo.affectsGlobalScope, impliedFormat: fileInfo.impliedFormat };
|
|
@@ -106854,7 +106823,7 @@ ${lanes.join("\n")}
|
|
|
106854
106823
|
let filePathsSetList;
|
|
106855
106824
|
const latestChangedDtsFile = program.latestChangedDtsFile ? toAbsolutePath(program.latestChangedDtsFile) : void 0;
|
|
106856
106825
|
if (isProgramBundleEmitBuildInfo(program)) {
|
|
106857
|
-
const fileInfos = new Map();
|
|
106826
|
+
const fileInfos = /* @__PURE__ */ new Map();
|
|
106858
106827
|
program.fileInfos.forEach((fileInfo, index) => {
|
|
106859
106828
|
const path = toFilePath(index + 1);
|
|
106860
106829
|
fileInfos.set(path, isString(fileInfo) ? { version: fileInfo, signature: void 0, affectsGlobalScope: void 0, impliedFormat: void 0 } : fileInfo);
|
|
@@ -106869,8 +106838,8 @@ ${lanes.join("\n")}
|
|
|
106869
106838
|
};
|
|
106870
106839
|
} else {
|
|
106871
106840
|
filePathsSetList = (_b = program.fileIdsList) == null ? void 0 : _b.map((fileIds) => new Set(fileIds.map(toFilePath)));
|
|
106872
|
-
const fileInfos = new Map();
|
|
106873
|
-
const emitSignatures = ((_c = program.options) == null ? void 0 : _c.composite) && !outFile(program.options) ? new Map() : void 0;
|
|
106841
|
+
const fileInfos = /* @__PURE__ */ new Map();
|
|
106842
|
+
const emitSignatures = ((_c = program.options) == null ? void 0 : _c.composite) && !outFile(program.options) ? /* @__PURE__ */ new Map() : void 0;
|
|
106874
106843
|
program.fileInfos.forEach((fileInfo, index) => {
|
|
106875
106844
|
const path = toFilePath(index + 1);
|
|
106876
106845
|
const stateFileInfo = toBuilderStateFileInfoForMultiEmit(fileInfo);
|
|
@@ -106954,7 +106923,7 @@ ${lanes.join("\n")}
|
|
|
106954
106923
|
function getBuildInfoFileVersionMap(program, buildInfoPath, host) {
|
|
106955
106924
|
const buildInfoDirectory = getDirectoryPath(getNormalizedAbsolutePath(buildInfoPath, host.getCurrentDirectory()));
|
|
106956
106925
|
const getCanonicalFileName = createGetCanonicalFileName(host.useCaseSensitiveFileNames());
|
|
106957
|
-
const fileInfos = new Map();
|
|
106926
|
+
const fileInfos = /* @__PURE__ */ new Map();
|
|
106958
106927
|
program.fileInfos.forEach((fileInfo, index) => {
|
|
106959
106928
|
const path = toPath(program.fileNames[index], buildInfoDirectory, getCanonicalFileName);
|
|
106960
106929
|
const version2 = isString(fileInfo) ? fileInfo : fileInfo.version;
|
|
@@ -107046,7 +107015,7 @@ ${lanes.join("\n")}
|
|
|
107046
107015
|
const resolutionsWithFailedLookups = [];
|
|
107047
107016
|
const resolutionsWithOnlyAffectingLocations = [];
|
|
107048
107017
|
const resolvedFileToResolution = createMultiMap();
|
|
107049
|
-
const impliedFormatPackageJsons = new Map();
|
|
107018
|
+
const impliedFormatPackageJsons = /* @__PURE__ */ new Map();
|
|
107050
107019
|
let hasChangedAutomaticTypeDirectiveNames = false;
|
|
107051
107020
|
let affectingPathChecksForFile;
|
|
107052
107021
|
let affectingPathChecks;
|
|
@@ -107055,7 +107024,7 @@ ${lanes.join("\n")}
|
|
|
107055
107024
|
let isInDirectoryChecks;
|
|
107056
107025
|
const getCurrentDirectory = memoize(() => resolutionHost.getCurrentDirectory());
|
|
107057
107026
|
const cachedDirectoryStructureHost = resolutionHost.getCachedDirectoryStructureHost();
|
|
107058
|
-
const resolvedModuleNames = new Map();
|
|
107027
|
+
const resolvedModuleNames = /* @__PURE__ */ new Map();
|
|
107059
107028
|
const perDirectoryResolvedModuleNames = createCacheWithRedirects();
|
|
107060
107029
|
const nonRelativeModuleNameCache = createCacheWithRedirects();
|
|
107061
107030
|
const moduleResolutionCache = createModuleResolutionCache(
|
|
@@ -107065,7 +107034,7 @@ ${lanes.join("\n")}
|
|
|
107065
107034
|
perDirectoryResolvedModuleNames,
|
|
107066
107035
|
nonRelativeModuleNameCache
|
|
107067
107036
|
);
|
|
107068
|
-
const resolvedTypeReferenceDirectives = new Map();
|
|
107037
|
+
const resolvedTypeReferenceDirectives = /* @__PURE__ */ new Map();
|
|
107069
107038
|
const perDirectoryResolvedTypeReferenceDirectives = createCacheWithRedirects();
|
|
107070
107039
|
const typeReferenceDirectiveResolutionCache = createTypeReferenceDirectiveResolutionCache(
|
|
107071
107040
|
getCurrentDirectory(),
|
|
@@ -107075,13 +107044,13 @@ ${lanes.join("\n")}
|
|
|
107075
107044
|
perDirectoryResolvedTypeReferenceDirectives
|
|
107076
107045
|
);
|
|
107077
107046
|
const failedLookupDefaultExtensions = [".ts" /* Ts */, ".tsx" /* Tsx */, ".js" /* Js */, ".jsx" /* Jsx */, ".json" /* Json */];
|
|
107078
|
-
const customFailedLookupPaths = new Map();
|
|
107079
|
-
const directoryWatchesOfFailedLookups = new Map();
|
|
107080
|
-
const fileWatchesOfAffectingLocations = new Map();
|
|
107047
|
+
const customFailedLookupPaths = /* @__PURE__ */ new Map();
|
|
107048
|
+
const directoryWatchesOfFailedLookups = /* @__PURE__ */ new Map();
|
|
107049
|
+
const fileWatchesOfAffectingLocations = /* @__PURE__ */ new Map();
|
|
107081
107050
|
const rootDir = rootDirForResolution && removeTrailingDirectorySeparator(getNormalizedAbsolutePath(rootDirForResolution, getCurrentDirectory()));
|
|
107082
107051
|
const rootPath = rootDir && resolutionHost.toPath(rootDir);
|
|
107083
107052
|
const rootSplitLength = rootPath !== void 0 ? rootPath.split(directorySeparator).length : 0;
|
|
107084
|
-
const typeRootsWatches = new Map();
|
|
107053
|
+
const typeRootsWatches = /* @__PURE__ */ new Map();
|
|
107085
107054
|
return {
|
|
107086
107055
|
getModuleResolutionCache: () => moduleResolutionCache,
|
|
107087
107056
|
startRecordingFilesWithChangedResolutions,
|
|
@@ -107534,16 +107503,16 @@ ${lanes.join("\n")}
|
|
|
107534
107503
|
}
|
|
107535
107504
|
}
|
|
107536
107505
|
}
|
|
107537
|
-
const paths = new Set();
|
|
107506
|
+
const paths = /* @__PURE__ */ new Set();
|
|
107538
107507
|
paths.add(locationToWatch);
|
|
107539
107508
|
let actualWatcher = canWatchDirectoryOrFile(resolutionHost.toPath(locationToWatch)) ? resolutionHost.watchAffectingFileLocation(locationToWatch, (fileName, eventKind) => {
|
|
107540
107509
|
cachedDirectoryStructureHost == null ? void 0 : cachedDirectoryStructureHost.addOrDeleteFile(fileName, resolutionHost.toPath(locationToWatch), eventKind);
|
|
107541
107510
|
const packageJsonMap = moduleResolutionCache.getPackageJsonInfoCache().getInternalMap();
|
|
107542
107511
|
paths.forEach((path) => {
|
|
107543
107512
|
if (watcher.resolutions)
|
|
107544
|
-
(affectingPathChecks != null ? affectingPathChecks : affectingPathChecks = new Set()).add(path);
|
|
107513
|
+
(affectingPathChecks != null ? affectingPathChecks : affectingPathChecks = /* @__PURE__ */ new Set()).add(path);
|
|
107545
107514
|
if (watcher.files)
|
|
107546
|
-
(affectingPathChecksForFile != null ? affectingPathChecksForFile : affectingPathChecksForFile = new Set()).add(path);
|
|
107515
|
+
(affectingPathChecksForFile != null ? affectingPathChecksForFile : affectingPathChecksForFile = /* @__PURE__ */ new Set()).add(path);
|
|
107547
107516
|
packageJsonMap == null ? void 0 : packageJsonMap.delete(resolutionHost.toPath(path));
|
|
107548
107517
|
});
|
|
107549
107518
|
resolutionHost.scheduleInvalidateResolutionsOfFailedLookupLocations();
|
|
@@ -107671,7 +107640,7 @@ ${lanes.join("\n")}
|
|
|
107671
107640
|
continue;
|
|
107672
107641
|
resolution.isInvalidated = invalidated = true;
|
|
107673
107642
|
for (const containingFilePath of Debug.checkDefined(resolution.files)) {
|
|
107674
|
-
(filesWithInvalidatedResolutions != null ? filesWithInvalidatedResolutions : filesWithInvalidatedResolutions = new Set()).add(containingFilePath);
|
|
107643
|
+
(filesWithInvalidatedResolutions != null ? filesWithInvalidatedResolutions : filesWithInvalidatedResolutions = /* @__PURE__ */ new Set()).add(containingFilePath);
|
|
107675
107644
|
hasChangedAutomaticTypeDirectiveNames = hasChangedAutomaticTypeDirectiveNames || endsWith(containingFilePath, inferredTypesContainingFile);
|
|
107676
107645
|
}
|
|
107677
107646
|
}
|
|
@@ -107690,7 +107659,7 @@ ${lanes.join("\n")}
|
|
|
107690
107659
|
}
|
|
107691
107660
|
function scheduleInvalidateResolutionOfFailedLookupLocation(fileOrDirectoryPath, isCreatingWatchedDirectory) {
|
|
107692
107661
|
if (isCreatingWatchedDirectory) {
|
|
107693
|
-
(isInDirectoryChecks || (isInDirectoryChecks = new Set())).add(fileOrDirectoryPath);
|
|
107662
|
+
(isInDirectoryChecks || (isInDirectoryChecks = /* @__PURE__ */ new Set())).add(fileOrDirectoryPath);
|
|
107694
107663
|
} else {
|
|
107695
107664
|
const updatedPath = removeIgnoredPath(fileOrDirectoryPath);
|
|
107696
107665
|
if (!updatedPath)
|
|
@@ -107701,8 +107670,8 @@ ${lanes.join("\n")}
|
|
|
107701
107670
|
}
|
|
107702
107671
|
const dirOfFileOrDirectory = getDirectoryPath(fileOrDirectoryPath);
|
|
107703
107672
|
if (isNodeModulesAtTypesDirectory(fileOrDirectoryPath) || isNodeModulesDirectory(fileOrDirectoryPath) || isNodeModulesAtTypesDirectory(dirOfFileOrDirectory) || isNodeModulesDirectory(dirOfFileOrDirectory)) {
|
|
107704
|
-
(failedLookupChecks || (failedLookupChecks = new Set())).add(fileOrDirectoryPath);
|
|
107705
|
-
(startsWithPathChecks || (startsWithPathChecks = new Set())).add(fileOrDirectoryPath);
|
|
107673
|
+
(failedLookupChecks || (failedLookupChecks = /* @__PURE__ */ new Set())).add(fileOrDirectoryPath);
|
|
107674
|
+
(startsWithPathChecks || (startsWithPathChecks = /* @__PURE__ */ new Set())).add(fileOrDirectoryPath);
|
|
107706
107675
|
} else {
|
|
107707
107676
|
if (!isPathWithDefaultFailedLookupExtension(fileOrDirectoryPath) && !customFailedLookupPaths.has(fileOrDirectoryPath)) {
|
|
107708
107677
|
return false;
|
|
@@ -107710,10 +107679,10 @@ ${lanes.join("\n")}
|
|
|
107710
107679
|
if (isEmittedFileOfProgram(resolutionHost.getCurrentProgram(), fileOrDirectoryPath)) {
|
|
107711
107680
|
return false;
|
|
107712
107681
|
}
|
|
107713
|
-
(failedLookupChecks || (failedLookupChecks = new Set())).add(fileOrDirectoryPath);
|
|
107682
|
+
(failedLookupChecks || (failedLookupChecks = /* @__PURE__ */ new Set())).add(fileOrDirectoryPath);
|
|
107714
107683
|
const packagePath = parseNodeModuleFromPath(fileOrDirectoryPath);
|
|
107715
107684
|
if (packagePath)
|
|
107716
|
-
(startsWithPathChecks || (startsWithPathChecks = new Set())).add(packagePath);
|
|
107685
|
+
(startsWithPathChecks || (startsWithPathChecks = /* @__PURE__ */ new Set())).add(packagePath);
|
|
107717
107686
|
}
|
|
107718
107687
|
}
|
|
107719
107688
|
resolutionHost.scheduleInvalidateResolutionsOfFailedLookupLocations();
|
|
@@ -107724,7 +107693,7 @@ ${lanes.join("\n")}
|
|
|
107724
107693
|
if (affectingPathChecksForFile) {
|
|
107725
107694
|
(_a2 = resolutionHost.getCurrentProgram()) == null ? void 0 : _a2.getSourceFiles().forEach((f) => {
|
|
107726
107695
|
if (some(f.packageJsonLocations, (location2) => affectingPathChecksForFile.has(location2))) {
|
|
107727
|
-
(filesWithInvalidatedResolutions != null ? filesWithInvalidatedResolutions : filesWithInvalidatedResolutions = new Set()).add(f.path);
|
|
107696
|
+
(filesWithInvalidatedResolutions != null ? filesWithInvalidatedResolutions : filesWithInvalidatedResolutions = /* @__PURE__ */ new Set()).add(f.path);
|
|
107728
107697
|
invalidated = true;
|
|
107729
107698
|
}
|
|
107730
107699
|
});
|
|
@@ -108485,7 +108454,7 @@ ${lanes.join("\n")}
|
|
|
108485
108454
|
let sharedExtendedConfigFileWatchers;
|
|
108486
108455
|
let extendedConfigCache = host.extendedConfigCache;
|
|
108487
108456
|
let reportFileChangeDetectedOnCreateProgram = false;
|
|
108488
|
-
const sourceFilesCache = new Map();
|
|
108457
|
+
const sourceFilesCache = /* @__PURE__ */ new Map();
|
|
108489
108458
|
let missingFilePathsRequestedForRelease;
|
|
108490
108459
|
let hasChangedCompilerOptions = false;
|
|
108491
108460
|
const useCaseSensitiveFileNames = host.useCaseSensitiveFileNames();
|
|
@@ -108660,7 +108629,7 @@ ${lanes.join("\n")}
|
|
|
108660
108629
|
const oldProgram = getCurrentProgram();
|
|
108661
108630
|
builderProgram = createProgram2(rootFileNames, compilerOptions, compilerHost, builderProgram, configFileParsingDiagnostics, projectReferences);
|
|
108662
108631
|
resolutionCache.finishCachingPerDirectoryResolution(builderProgram.getProgram(), oldProgram);
|
|
108663
|
-
updateMissingFilePathsWatch(builderProgram.getProgram(), missingFilesMap || (missingFilesMap = new Map()), watchMissingFilePath);
|
|
108632
|
+
updateMissingFilePathsWatch(builderProgram.getProgram(), missingFilesMap || (missingFilesMap = /* @__PURE__ */ new Map()), watchMissingFilePath);
|
|
108664
108633
|
if (needsUpdateInTypeRootWatch) {
|
|
108665
108634
|
resolutionCache.updateTypeRootsWatch();
|
|
108666
108635
|
}
|
|
@@ -108852,7 +108821,7 @@ ${lanes.join("\n")}
|
|
|
108852
108821
|
configFileName,
|
|
108853
108822
|
optionsToExtendForConfigFile,
|
|
108854
108823
|
parseConfigFileHost,
|
|
108855
|
-
extendedConfigCache || (extendedConfigCache = new Map()),
|
|
108824
|
+
extendedConfigCache || (extendedConfigCache = /* @__PURE__ */ new Map()),
|
|
108856
108825
|
watchOptionsToExtend,
|
|
108857
108826
|
extraFileExtensions
|
|
108858
108827
|
));
|
|
@@ -108892,7 +108861,7 @@ ${lanes.join("\n")}
|
|
|
108892
108861
|
config.parsedCommandLine = parsedCommandLine;
|
|
108893
108862
|
config.reloadLevel = void 0;
|
|
108894
108863
|
} else {
|
|
108895
|
-
(parsedConfigs || (parsedConfigs = new Map())).set(configPath, config = { parsedCommandLine });
|
|
108864
|
+
(parsedConfigs || (parsedConfigs = /* @__PURE__ */ new Map())).set(configPath, config = { parsedCommandLine });
|
|
108896
108865
|
}
|
|
108897
108866
|
watchReferencedProject(configFileName2, configPath, config);
|
|
108898
108867
|
return parsedCommandLine;
|
|
@@ -108904,7 +108873,7 @@ ${lanes.join("\n")}
|
|
|
108904
108873
|
configFileName2,
|
|
108905
108874
|
void 0,
|
|
108906
108875
|
parseConfigFileHost,
|
|
108907
|
-
extendedConfigCache || (extendedConfigCache = new Map()),
|
|
108876
|
+
extendedConfigCache || (extendedConfigCache = /* @__PURE__ */ new Map()),
|
|
108908
108877
|
watchOptionsToExtend
|
|
108909
108878
|
);
|
|
108910
108879
|
parseConfigFileHost.onUnRecoverableConfigFileDiagnostic = onUnRecoverableConfigFileDiagnostic;
|
|
@@ -108953,7 +108922,7 @@ ${lanes.join("\n")}
|
|
|
108953
108922
|
function watchConfigFileWildCardDirectories() {
|
|
108954
108923
|
if (wildcardDirectories) {
|
|
108955
108924
|
updateWatchingWildcardDirectories(
|
|
108956
|
-
watchedWildcardDirectories || (watchedWildcardDirectories = new Map()),
|
|
108925
|
+
watchedWildcardDirectories || (watchedWildcardDirectories = /* @__PURE__ */ new Map()),
|
|
108957
108926
|
new Map(getEntries(wildcardDirectories)),
|
|
108958
108927
|
watchWildcardDirectory
|
|
108959
108928
|
);
|
|
@@ -108999,7 +108968,7 @@ ${lanes.join("\n")}
|
|
|
108999
108968
|
updateSharedExtendedConfigFileWatcher(
|
|
109000
108969
|
forProjectPath,
|
|
109001
108970
|
options,
|
|
109002
|
-
sharedExtendedConfigFileWatchers || (sharedExtendedConfigFileWatchers = new Map()),
|
|
108971
|
+
sharedExtendedConfigFileWatchers || (sharedExtendedConfigFileWatchers = /* @__PURE__ */ new Map()),
|
|
109003
108972
|
(extendedConfigFileName, extendedConfigFilePath) => watchFile2(
|
|
109004
108973
|
extendedConfigFileName,
|
|
109005
108974
|
(_fileName, eventKind) => {
|
|
@@ -109047,7 +109016,7 @@ ${lanes.join("\n")}
|
|
|
109047
109016
|
));
|
|
109048
109017
|
if ((_b = commandLine.parsedCommandLine) == null ? void 0 : _b.wildcardDirectories) {
|
|
109049
109018
|
updateWatchingWildcardDirectories(
|
|
109050
|
-
commandLine.watchedDirectories || (commandLine.watchedDirectories = new Map()),
|
|
109019
|
+
commandLine.watchedDirectories || (commandLine.watchedDirectories = /* @__PURE__ */ new Map()),
|
|
109051
109020
|
new Map(getEntries((_c = commandLine.parsedCommandLine) == null ? void 0 : _c.wildcardDirectories)),
|
|
109052
109021
|
(directory, flags) => {
|
|
109053
109022
|
var _a3;
|
|
@@ -109140,7 +109109,7 @@ ${lanes.join("\n")}
|
|
|
109140
109109
|
return existingValue || newValue;
|
|
109141
109110
|
}
|
|
109142
109111
|
function getOrCreateValueMapFromConfigFileMap(configFileMap, resolved) {
|
|
109143
|
-
return getOrCreateValueFromConfigFileMap(configFileMap, resolved, () => new Map());
|
|
109112
|
+
return getOrCreateValueFromConfigFileMap(configFileMap, resolved, () => /* @__PURE__ */ new Map());
|
|
109144
109113
|
}
|
|
109145
109114
|
function getCurrentTime(host) {
|
|
109146
109115
|
return host.now ? host.now() : new Date();
|
|
@@ -109229,16 +109198,16 @@ ${lanes.join("\n")}
|
|
|
109229
109198
|
baseCompilerOptions,
|
|
109230
109199
|
rootNames,
|
|
109231
109200
|
baseWatchOptions,
|
|
109232
|
-
resolvedConfigFilePaths: new Map(),
|
|
109233
|
-
configFileCache: new Map(),
|
|
109234
|
-
projectStatus: new Map(),
|
|
109235
|
-
extendedConfigCache: new Map(),
|
|
109236
|
-
buildInfoCache: new Map(),
|
|
109237
|
-
outputTimeStamps: new Map(),
|
|
109238
|
-
builderPrograms: new Map(),
|
|
109239
|
-
diagnostics: new Map(),
|
|
109240
|
-
projectPendingBuild: new Map(),
|
|
109241
|
-
projectErrorsReported: new Map(),
|
|
109201
|
+
resolvedConfigFilePaths: /* @__PURE__ */ new Map(),
|
|
109202
|
+
configFileCache: /* @__PURE__ */ new Map(),
|
|
109203
|
+
projectStatus: /* @__PURE__ */ new Map(),
|
|
109204
|
+
extendedConfigCache: /* @__PURE__ */ new Map(),
|
|
109205
|
+
buildInfoCache: /* @__PURE__ */ new Map(),
|
|
109206
|
+
outputTimeStamps: /* @__PURE__ */ new Map(),
|
|
109207
|
+
builderPrograms: /* @__PURE__ */ new Map(),
|
|
109208
|
+
diagnostics: /* @__PURE__ */ new Map(),
|
|
109209
|
+
projectPendingBuild: /* @__PURE__ */ new Map(),
|
|
109210
|
+
projectErrorsReported: /* @__PURE__ */ new Map(),
|
|
109242
109211
|
compilerHost,
|
|
109243
109212
|
moduleResolutionCache,
|
|
109244
109213
|
typeReferenceDirectiveResolutionCache,
|
|
@@ -109250,13 +109219,13 @@ ${lanes.join("\n")}
|
|
|
109250
109219
|
needsSummary: true,
|
|
109251
109220
|
watchAllProjectsPending: watch,
|
|
109252
109221
|
watch,
|
|
109253
|
-
allWatchedWildcardDirectories: new Map(),
|
|
109254
|
-
allWatchedInputFiles: new Map(),
|
|
109255
|
-
allWatchedConfigFiles: new Map(),
|
|
109256
|
-
allWatchedExtendedConfigFiles: new Map(),
|
|
109257
|
-
allWatchedPackageJsonFiles: new Map(),
|
|
109258
|
-
filesWatched: new Map(),
|
|
109259
|
-
lastCachedPackageJsonLookups: new Map(),
|
|
109222
|
+
allWatchedWildcardDirectories: /* @__PURE__ */ new Map(),
|
|
109223
|
+
allWatchedInputFiles: /* @__PURE__ */ new Map(),
|
|
109224
|
+
allWatchedConfigFiles: /* @__PURE__ */ new Map(),
|
|
109225
|
+
allWatchedExtendedConfigFiles: /* @__PURE__ */ new Map(),
|
|
109226
|
+
allWatchedPackageJsonFiles: /* @__PURE__ */ new Map(),
|
|
109227
|
+
filesWatched: /* @__PURE__ */ new Map(),
|
|
109228
|
+
lastCachedPackageJsonLookups: /* @__PURE__ */ new Map(),
|
|
109260
109229
|
timerToBuildInvalidatedProject: void 0,
|
|
109261
109230
|
reportFileChangeDetected: false,
|
|
109262
109231
|
watchFile: watchFile2,
|
|
@@ -109312,8 +109281,8 @@ ${lanes.join("\n")}
|
|
|
109312
109281
|
return resolveConfigFileProjectName(resolvePath(state.currentDirectory, name));
|
|
109313
109282
|
}
|
|
109314
109283
|
function createBuildOrder(state, roots) {
|
|
109315
|
-
const temporaryMarks = new Map();
|
|
109316
|
-
const permanentMarks = new Map();
|
|
109284
|
+
const temporaryMarks = /* @__PURE__ */ new Map();
|
|
109285
|
+
const permanentMarks = /* @__PURE__ */ new Map();
|
|
109317
109286
|
const circularityReportStack = [];
|
|
109318
109287
|
let buildOrder;
|
|
109319
109288
|
let circularDiagnostics;
|
|
@@ -109732,7 +109701,7 @@ ${lanes.join("\n")}
|
|
|
109732
109701
|
const { host, compilerHost } = state;
|
|
109733
109702
|
const resultFlags = ((_c = program.hasChangedEmitSignature) == null ? void 0 : _c.call(program)) ? 0 /* None */ : 2 /* DeclarationOutputUnchanged */;
|
|
109734
109703
|
const emitterDiagnostics = createDiagnosticCollection();
|
|
109735
|
-
const emittedOutputs = new Map();
|
|
109704
|
+
const emittedOutputs = /* @__PURE__ */ new Map();
|
|
109736
109705
|
const options = program.getCompilerOptions();
|
|
109737
109706
|
const isIncremental = isIncrementalCompilation(options);
|
|
109738
109707
|
let outputTimeStampMap;
|
|
@@ -109847,7 +109816,7 @@ ${lanes.join("\n")}
|
|
|
109847
109816
|
}
|
|
109848
109817
|
Debug.assert(!!outputFiles.length);
|
|
109849
109818
|
const emitterDiagnostics = createDiagnosticCollection();
|
|
109850
|
-
const emittedOutputs = new Map();
|
|
109819
|
+
const emittedOutputs = /* @__PURE__ */ new Map();
|
|
109851
109820
|
let resultFlags = 2 /* DeclarationOutputUnchanged */;
|
|
109852
109821
|
const existingBuildInfo = state.buildInfoCache.get(projectPath).buildInfo || void 0;
|
|
109853
109822
|
outputFiles.forEach(({ name, text, writeByteOrderMark, data }) => {
|
|
@@ -110119,7 +110088,7 @@ ${lanes.join("\n")}
|
|
|
110119
110088
|
return void 0;
|
|
110120
110089
|
let result = state.outputTimeStamps.get(resolvedConfigFilePath);
|
|
110121
110090
|
if (!result)
|
|
110122
|
-
state.outputTimeStamps.set(resolvedConfigFilePath, result = new Map());
|
|
110091
|
+
state.outputTimeStamps.set(resolvedConfigFilePath, result = /* @__PURE__ */ new Map());
|
|
110123
110092
|
return result;
|
|
110124
110093
|
}
|
|
110125
110094
|
function setBuildInfo(state, buildInfo, resolvedConfigPath, options, resultFlags) {
|
|
@@ -110417,7 +110386,7 @@ ${lanes.join("\n")}
|
|
|
110417
110386
|
const { host } = state;
|
|
110418
110387
|
const outputs = getAllProjectOutputs(proj, !host.useCaseSensitiveFileNames());
|
|
110419
110388
|
const outputTimeStampMap = getOutputTimeStampMap(state, projectPath);
|
|
110420
|
-
const modifiedOutputs = outputTimeStampMap ? new Set() : void 0;
|
|
110389
|
+
const modifiedOutputs = outputTimeStampMap ? /* @__PURE__ */ new Set() : void 0;
|
|
110421
110390
|
if (!skipOutputs || outputs.length !== skipOutputs.size) {
|
|
110422
110391
|
let reportVerbose = !!state.options.verbose;
|
|
110423
110392
|
for (const file of outputs) {
|
|
@@ -111086,7 +111055,7 @@ ${lanes.join("\n")}
|
|
|
111086
111055
|
if (!typeAcquisition || !typeAcquisition.enable) {
|
|
111087
111056
|
return { cachedTypingPaths: [], newTypingNames: [], filesToWatch: [] };
|
|
111088
111057
|
}
|
|
111089
|
-
const inferredTypings = new Map();
|
|
111058
|
+
const inferredTypings = /* @__PURE__ */ new Map();
|
|
111090
111059
|
fileNames = mapDefined(fileNames, (fileName) => {
|
|
111091
111060
|
const path = normalizePath(fileName);
|
|
111092
111061
|
if (hasJSFileExtension(path)) {
|
|
@@ -111484,7 +111453,6 @@ ${lanes.join("\n")}
|
|
|
111484
111453
|
LexicalEnvironmentFlags: () => LexicalEnvironmentFlags,
|
|
111485
111454
|
ListFormat: () => ListFormat,
|
|
111486
111455
|
LogLevel: () => LogLevel,
|
|
111487
|
-
Map: () => Map,
|
|
111488
111456
|
MemberOverrideStatus: () => MemberOverrideStatus,
|
|
111489
111457
|
ModifierFlags: () => ModifierFlags,
|
|
111490
111458
|
ModuleDetectionKind: () => ModuleDetectionKind,
|
|
@@ -111527,7 +111495,6 @@ ${lanes.join("\n")}
|
|
|
111527
111495
|
SemanticClassificationFormat: () => SemanticClassificationFormat,
|
|
111528
111496
|
SemanticMeaning: () => SemanticMeaning,
|
|
111529
111497
|
SemicolonPreference: () => SemicolonPreference,
|
|
111530
|
-
Set: () => Set,
|
|
111531
111498
|
SignatureCheckMode: () => SignatureCheckMode,
|
|
111532
111499
|
SignatureFlags: () => SignatureFlags,
|
|
111533
111500
|
SignatureHelp: () => ts_SignatureHelp_exports,
|
|
@@ -116460,7 +116427,7 @@ ${lanes.join("\n")}
|
|
|
116460
116427
|
if (!dependencies) {
|
|
116461
116428
|
continue;
|
|
116462
116429
|
}
|
|
116463
|
-
const dependencyMap = new Map();
|
|
116430
|
+
const dependencyMap = /* @__PURE__ */ new Map();
|
|
116464
116431
|
for (const packageName in dependencies) {
|
|
116465
116432
|
dependencyMap.set(packageName, dependencies[packageName]);
|
|
116466
116433
|
}
|
|
@@ -116758,8 +116725,8 @@ ${lanes.join("\n")}
|
|
|
116758
116725
|
function createCacheableExportInfoMap(host) {
|
|
116759
116726
|
let exportInfoId = 1;
|
|
116760
116727
|
const exportInfo = createMultiMap();
|
|
116761
|
-
const symbols = new Map();
|
|
116762
|
-
const packages = new Map();
|
|
116728
|
+
const symbols = /* @__PURE__ */ new Map();
|
|
116729
|
+
const packages = /* @__PURE__ */ new Map();
|
|
116763
116730
|
let usableByFileName;
|
|
116764
116731
|
const cache = {
|
|
116765
116732
|
isUsableByFile: (importingFile) => importingFile === usableByFileName,
|
|
@@ -117021,7 +116988,7 @@ ${lanes.join("\n")}
|
|
|
117021
116988
|
forEachExternalModuleToImportFrom(program, host, preferences, true, (moduleSymbol, moduleFile, program2, isFromPackageJson) => {
|
|
117022
116989
|
if (++moduleCount % 100 === 0)
|
|
117023
116990
|
cancellationToken == null ? void 0 : cancellationToken.throwIfCancellationRequested();
|
|
117024
|
-
const seenExports = new Map();
|
|
116991
|
+
const seenExports = /* @__PURE__ */ new Map();
|
|
117025
116992
|
const checker = program2.getTypeChecker();
|
|
117026
116993
|
const defaultInfo = getDefaultLikeExportInfo(moduleSymbol, checker, compilerOptions);
|
|
117027
116994
|
if (defaultInfo && isImportableSymbol(defaultInfo.symbol, checker)) {
|
|
@@ -118362,7 +118329,7 @@ ${lanes.join("\n")}
|
|
|
118362
118329
|
return createDocumentRegistryInternal(useCaseSensitiveFileNames, currentDirectory);
|
|
118363
118330
|
}
|
|
118364
118331
|
function createDocumentRegistryInternal(useCaseSensitiveFileNames, currentDirectory = "", externalCache) {
|
|
118365
|
-
const buckets = new Map();
|
|
118332
|
+
const buckets = /* @__PURE__ */ new Map();
|
|
118366
118333
|
const getCanonicalFileName = createGetCanonicalFileName(!!useCaseSensitiveFileNames);
|
|
118367
118334
|
function reportStats() {
|
|
118368
118335
|
const bucketInfoArray = arrayFrom(buckets.keys()).filter((name) => name && name.charAt(0) === "_").map((name) => {
|
|
@@ -118428,7 +118395,7 @@ ${lanes.join("\n")}
|
|
|
118428
118395
|
sourceFileOptions.languageVersion = scriptTarget;
|
|
118429
118396
|
const oldBucketCount = buckets.size;
|
|
118430
118397
|
const keyWithMode = getDocumentRegistryBucketKeyWithMode(key, sourceFileOptions.impliedNodeFormat);
|
|
118431
|
-
const bucket = getOrUpdate(buckets, keyWithMode, () => new Map());
|
|
118398
|
+
const bucket = getOrUpdate(buckets, keyWithMode, () => /* @__PURE__ */ new Map());
|
|
118432
118399
|
if (tracing) {
|
|
118433
118400
|
if (buckets.size > oldBucketCount) {
|
|
118434
118401
|
tracing.instant(tracing.Phase.Session, "createdDocumentRegistryBucket", { configFilePath: compilationSettings.configFilePath, key: keyWithMode });
|
|
@@ -118483,7 +118450,7 @@ ${lanes.join("\n")}
|
|
|
118483
118450
|
if (!bucketEntry) {
|
|
118484
118451
|
bucket.set(path, entry);
|
|
118485
118452
|
} else if (isDocumentRegistryEntry(bucketEntry)) {
|
|
118486
|
-
const scriptKindMap = new Map();
|
|
118453
|
+
const scriptKindMap = /* @__PURE__ */ new Map();
|
|
118487
118454
|
scriptKindMap.set(bucketEntry.sourceFile.scriptKind, bucketEntry);
|
|
118488
118455
|
scriptKindMap.set(scriptKind, entry);
|
|
118489
118456
|
bucket.set(path, scriptKindMap);
|
|
@@ -118767,7 +118734,7 @@ ${lanes.join("\n")}
|
|
|
118767
118734
|
};
|
|
118768
118735
|
}
|
|
118769
118736
|
function createPatternMatcher(pattern) {
|
|
118770
|
-
const stringToWordSpans = new Map();
|
|
118737
|
+
const stringToWordSpans = /* @__PURE__ */ new Map();
|
|
118771
118738
|
const dotSeparatedSegments = pattern.trim().split(".").map((p) => createSegment(p.trim()));
|
|
118772
118739
|
if (dotSeparatedSegments.some((segment) => !segment.subWordTextChunks.length))
|
|
118773
118740
|
return void 0;
|
|
@@ -119377,8 +119344,8 @@ ${lanes.join("\n")}
|
|
|
119377
119344
|
function getSourceMapper(host) {
|
|
119378
119345
|
const getCanonicalFileName = createGetCanonicalFileName(host.useCaseSensitiveFileNames());
|
|
119379
119346
|
const currentDirectory = host.getCurrentDirectory();
|
|
119380
|
-
const sourceFileLike = new Map();
|
|
119381
|
-
const documentPositionMappers = new Map();
|
|
119347
|
+
const sourceFileLike = /* @__PURE__ */ new Map();
|
|
119348
|
+
const documentPositionMappers = /* @__PURE__ */ new Map();
|
|
119382
119349
|
return { tryGetSourcePosition, tryGetGeneratedPosition, toLineColumnOffset, clearCache };
|
|
119383
119350
|
function toPath3(fileName) {
|
|
119384
119351
|
return toPath(fileName, currentDirectory, getCanonicalFileName);
|
|
@@ -119514,7 +119481,7 @@ ${lanes.join("\n")}
|
|
|
119514
119481
|
}
|
|
119515
119482
|
|
|
119516
119483
|
// src/services/suggestionDiagnostics.ts
|
|
119517
|
-
var visitedNestedConvertibleFunctions = new Map();
|
|
119484
|
+
var visitedNestedConvertibleFunctions = /* @__PURE__ */ new Map();
|
|
119518
119485
|
function computeSuggestionDiagnostics(sourceFile, program, cancellationToken) {
|
|
119519
119486
|
program.getSemanticDiagnostics(sourceFile, cancellationToken);
|
|
119520
119487
|
const diags = [];
|
|
@@ -119975,7 +119942,7 @@ ${lanes.join("\n")}
|
|
|
119975
119942
|
}
|
|
119976
119943
|
function addTrackedEs5Class(name) {
|
|
119977
119944
|
if (!trackedEs5Classes) {
|
|
119978
|
-
trackedEs5Classes = new Map();
|
|
119945
|
+
trackedEs5Classes = /* @__PURE__ */ new Map();
|
|
119979
119946
|
}
|
|
119980
119947
|
trackedEs5Classes.set(name, true);
|
|
119981
119948
|
}
|
|
@@ -120247,7 +120214,7 @@ ${lanes.join("\n")}
|
|
|
120247
120214
|
}
|
|
120248
120215
|
}
|
|
120249
120216
|
function mergeChildren(children, node) {
|
|
120250
|
-
const nameToItems = new Map();
|
|
120217
|
+
const nameToItems = /* @__PURE__ */ new Map();
|
|
120251
120218
|
filterMutate(children, (child, index) => {
|
|
120252
120219
|
const declName = child.name || getNameOfDeclaration(child.node);
|
|
120253
120220
|
const name = declName && nodeText(declName);
|
|
@@ -121081,7 +121048,7 @@ ${lanes.join("\n")}
|
|
|
121081
121048
|
return emptyArray;
|
|
121082
121049
|
let tags = ts_JsDoc_exports.getJsDocTagsFromDeclarations(declarations, checker);
|
|
121083
121050
|
if (checker && (tags.length === 0 || declarations.some(hasJSDocInheritDocTag))) {
|
|
121084
|
-
const seenSymbols = new Set();
|
|
121051
|
+
const seenSymbols = /* @__PURE__ */ new Set();
|
|
121085
121052
|
for (const declaration of declarations) {
|
|
121086
121053
|
const inheritedTags = findBaseOfDeclaration(checker, declaration, (symbol) => {
|
|
121087
121054
|
var _a2;
|
|
@@ -121105,7 +121072,7 @@ ${lanes.join("\n")}
|
|
|
121105
121072
|
return emptyArray;
|
|
121106
121073
|
let doc = ts_JsDoc_exports.getJsDocCommentsFromDeclarations(declarations, checker);
|
|
121107
121074
|
if (checker && (doc.length === 0 || declarations.some(hasJSDocInheritDocTag))) {
|
|
121108
|
-
const seenSymbols = new Set();
|
|
121075
|
+
const seenSymbols = /* @__PURE__ */ new Set();
|
|
121109
121076
|
for (const declaration of declarations) {
|
|
121110
121077
|
const inheritedDocs = findBaseOfDeclaration(checker, declaration, (symbol) => {
|
|
121111
121078
|
if (!seenSymbols.has(symbol)) {
|
|
@@ -121647,7 +121614,7 @@ ${lanes.join("\n")}
|
|
|
121647
121614
|
if (existing !== void 0)
|
|
121648
121615
|
return existing || void 0;
|
|
121649
121616
|
const result = host.getParsedCommandLine ? host.getParsedCommandLine(fileName) : getParsedCommandLineOfConfigFileUsingSourceFile(fileName);
|
|
121650
|
-
(parsedCommandLines || (parsedCommandLines = new Map())).set(path, result || false);
|
|
121617
|
+
(parsedCommandLines || (parsedCommandLines = /* @__PURE__ */ new Map())).set(path, result || false);
|
|
121651
121618
|
return result;
|
|
121652
121619
|
}
|
|
121653
121620
|
function getParsedCommandLineOfConfigFileUsingSourceFile(configFileName) {
|
|
@@ -122208,7 +122175,7 @@ ${lanes.join("\n")}
|
|
|
122208
122175
|
const { lineStarts, firstLine, lastLine } = getLinesForRange(sourceFile, textRange);
|
|
122209
122176
|
let isCommenting = insertComment || false;
|
|
122210
122177
|
let leftMostPosition = Number.MAX_VALUE;
|
|
122211
|
-
const lineTextStarts = new Map();
|
|
122178
|
+
const lineTextStarts = /* @__PURE__ */ new Map();
|
|
122212
122179
|
const firstNonWhitespaceCharacterRegex = new RegExp(/\S/);
|
|
122213
122180
|
const isJsx = isInsideJsxElement(sourceFile, lineStarts[firstLine]);
|
|
122214
122181
|
const openComment = isJsx ? "{/*" : "//";
|
|
@@ -122608,7 +122575,7 @@ ${lanes.join("\n")}
|
|
|
122608
122575
|
return sourceFile.nameTable;
|
|
122609
122576
|
}
|
|
122610
122577
|
function initializeNameTable(sourceFile) {
|
|
122611
|
-
const nameTable = sourceFile.nameTable = new Map();
|
|
122578
|
+
const nameTable = sourceFile.nameTable = /* @__PURE__ */ new Map();
|
|
122612
122579
|
sourceFile.forEachChild(function walk(node) {
|
|
122613
122580
|
if (isIdentifier(node) && !isTagName(node) && node.escapedText || isStringOrNumericLiteralLike(node) && literalIsName(node)) {
|
|
122614
122581
|
const text = getEscapedTextOfIdentifierOrLiteral(node);
|
|
@@ -124655,7 +124622,7 @@ ${lanes.join("\n")}
|
|
|
124655
124622
|
function isRightSideOfQualifiedNameOrPropertyAccess2(node) {
|
|
124656
124623
|
return isQualifiedName(node.parent) && node.parent.right === node || isPropertyAccessExpression(node.parent) && node.parent.name === node;
|
|
124657
124624
|
}
|
|
124658
|
-
var tokenFromDeclarationMapping = new Map([
|
|
124625
|
+
var tokenFromDeclarationMapping = /* @__PURE__ */ new Map([
|
|
124659
124626
|
[257 /* VariableDeclaration */, 7 /* variable */],
|
|
124660
124627
|
[166 /* Parameter */, 6 /* parameter */],
|
|
124661
124628
|
[169 /* PropertyDeclaration */, 9 /* property */],
|
|
@@ -124723,7 +124690,7 @@ ${lanes.join("\n")}
|
|
|
124723
124690
|
|
|
124724
124691
|
// src/services/codeFixProvider.ts
|
|
124725
124692
|
var errorCodeToFixes = createMultiMap();
|
|
124726
|
-
var fixIdToRegistration = new Map();
|
|
124693
|
+
var fixIdToRegistration = /* @__PURE__ */ new Map();
|
|
124727
124694
|
function createCodeFixActionWithoutFixAll(fixName8, changes, description2) {
|
|
124728
124695
|
return createCodeFixActionWorker(fixName8, diagnosticToString(description2), changes, void 0, void 0);
|
|
124729
124696
|
}
|
|
@@ -124872,7 +124839,7 @@ ${lanes.join("\n")}
|
|
|
124872
124839
|
},
|
|
124873
124840
|
getAllCodeActions: (context) => {
|
|
124874
124841
|
const { sourceFile } = context;
|
|
124875
|
-
const fixedDeclarations = new Set();
|
|
124842
|
+
const fixedDeclarations = /* @__PURE__ */ new Set();
|
|
124876
124843
|
return codeFixAll(context, errorCodes2, (t, diagnostic) => {
|
|
124877
124844
|
const span = diagnostic.relatedInformation && find(diagnostic.relatedInformation, (r) => r.code === Diagnostics.Did_you_mean_to_mark_this_function_as_async.code);
|
|
124878
124845
|
const decl = getFixableErrorSpanDeclaration(sourceFile, span);
|
|
@@ -124966,7 +124933,7 @@ ${lanes.join("\n")}
|
|
|
124966
124933
|
getAllCodeActions: (context) => {
|
|
124967
124934
|
const { sourceFile, program, cancellationToken } = context;
|
|
124968
124935
|
const checker = context.program.getTypeChecker();
|
|
124969
|
-
const fixedDeclarations = new Set();
|
|
124936
|
+
const fixedDeclarations = /* @__PURE__ */ new Set();
|
|
124970
124937
|
return codeFixAll(context, errorCodes3, (t, diagnostic) => {
|
|
124971
124938
|
const expression = getAwaitErrorSpanExpression(sourceFile, diagnostic.code, diagnostic, cancellationToken, program);
|
|
124972
124939
|
if (!expression) {
|
|
@@ -125152,7 +125119,7 @@ ${lanes.join("\n")}
|
|
|
125152
125119
|
},
|
|
125153
125120
|
fixIds: [fixId4],
|
|
125154
125121
|
getAllCodeActions: (context) => {
|
|
125155
|
-
const fixedNodes = new Set();
|
|
125122
|
+
const fixedNodes = /* @__PURE__ */ new Set();
|
|
125156
125123
|
return codeFixAll(context, errorCodes4, (changes, diag2) => makeChange4(changes, diag2.file, diag2.start, context.program, fixedNodes));
|
|
125157
125124
|
}
|
|
125158
125125
|
});
|
|
@@ -125243,7 +125210,7 @@ ${lanes.join("\n")}
|
|
|
125243
125210
|
},
|
|
125244
125211
|
fixIds: [fixId5],
|
|
125245
125212
|
getAllCodeActions: (context) => {
|
|
125246
|
-
const fixedNodes = new Set();
|
|
125213
|
+
const fixedNodes = /* @__PURE__ */ new Set();
|
|
125247
125214
|
return codeFixAll(context, errorCodes5, (changes, diag2) => makeChange5(changes, diag2.file, diag2.start, fixedNodes));
|
|
125248
125215
|
}
|
|
125249
125216
|
});
|
|
@@ -125830,7 +125797,7 @@ ${lanes.join("\n")}
|
|
|
125830
125797
|
if (!functionToConvert) {
|
|
125831
125798
|
return;
|
|
125832
125799
|
}
|
|
125833
|
-
const synthNamesMap = new Map();
|
|
125800
|
+
const synthNamesMap = /* @__PURE__ */ new Map();
|
|
125834
125801
|
const isInJavascript = isInJSFile(functionToConvert);
|
|
125835
125802
|
const setOfExpressionsToReturn = getAllPromiseExpressionsToReturn(functionToConvert, checker);
|
|
125836
125803
|
const functionToConvertRenamed = renameCollidingVarNames(functionToConvert, checker, synthNamesMap);
|
|
@@ -125874,9 +125841,9 @@ ${lanes.join("\n")}
|
|
|
125874
125841
|
}
|
|
125875
125842
|
function getAllPromiseExpressionsToReturn(func, checker) {
|
|
125876
125843
|
if (!func.body) {
|
|
125877
|
-
return new Set();
|
|
125844
|
+
return /* @__PURE__ */ new Set();
|
|
125878
125845
|
}
|
|
125879
|
-
const setOfExpressionsToReturn = new Set();
|
|
125846
|
+
const setOfExpressionsToReturn = /* @__PURE__ */ new Set();
|
|
125880
125847
|
forEachChild(func.body, function visit(node) {
|
|
125881
125848
|
if (isPromiseReturningCallExpression(node, checker, "then")) {
|
|
125882
125849
|
setOfExpressionsToReturn.add(getNodeId(node));
|
|
@@ -125925,7 +125892,7 @@ ${lanes.join("\n")}
|
|
|
125925
125892
|
return !!checker.getPromisedTypeOfPromise(checker.getTypeAtLocation(node));
|
|
125926
125893
|
}
|
|
125927
125894
|
function renameCollidingVarNames(nodeToRename, checker, synthNamesMap) {
|
|
125928
|
-
const identsToRenameMap = new Map();
|
|
125895
|
+
const identsToRenameMap = /* @__PURE__ */ new Map();
|
|
125929
125896
|
const collidingSymbolMap = createMultiMap();
|
|
125930
125897
|
forEachChild(nodeToRename, function visit(node) {
|
|
125931
125898
|
if (!isIdentifier(node)) {
|
|
@@ -126419,7 +126386,7 @@ ${lanes.join("\n")}
|
|
|
126419
126386
|
}
|
|
126420
126387
|
}
|
|
126421
126388
|
function convertFileToEsModule(sourceFile, checker, changes, target, quotePreference) {
|
|
126422
|
-
const identifiers = { original: collectFreeIdentifiers(sourceFile), additional: new Set() };
|
|
126389
|
+
const identifiers = { original: collectFreeIdentifiers(sourceFile), additional: /* @__PURE__ */ new Set() };
|
|
126423
126390
|
const exports = collectExportRenames(sourceFile, checker, identifiers);
|
|
126424
126391
|
convertExportsAccesses(sourceFile, exports, changes);
|
|
126425
126392
|
let moduleExportsChangedToDefault = false;
|
|
@@ -126427,7 +126394,7 @@ ${lanes.join("\n")}
|
|
|
126427
126394
|
for (const statement of filter(sourceFile.statements, isVariableStatement)) {
|
|
126428
126395
|
const newUseSites = convertVariableStatement(sourceFile, statement, changes, checker, identifiers, target, quotePreference);
|
|
126429
126396
|
if (newUseSites) {
|
|
126430
|
-
copyEntries(newUseSites, useSitesToUnqualify != null ? useSitesToUnqualify : useSitesToUnqualify = new Map());
|
|
126397
|
+
copyEntries(newUseSites, useSitesToUnqualify != null ? useSitesToUnqualify : useSitesToUnqualify = /* @__PURE__ */ new Map());
|
|
126431
126398
|
}
|
|
126432
126399
|
}
|
|
126433
126400
|
for (const statement of filter(sourceFile.statements, (s) => !isVariableStatement(s))) {
|
|
@@ -126440,7 +126407,7 @@ ${lanes.join("\n")}
|
|
|
126440
126407
|
return moduleExportsChangedToDefault;
|
|
126441
126408
|
}
|
|
126442
126409
|
function collectExportRenames(sourceFile, checker, identifiers) {
|
|
126443
|
-
const res = new Map();
|
|
126410
|
+
const res = /* @__PURE__ */ new Map();
|
|
126444
126411
|
forEachExportReference(sourceFile, (node) => {
|
|
126445
126412
|
const { text, originalKeywordKind } = node.name;
|
|
126446
126413
|
if (!res.has(text) && (originalKeywordKind !== void 0 && isNonContextualKeyword(originalKeywordKind) || checker.resolveName(text, node, 111551 /* Value */, true))) {
|
|
@@ -126515,7 +126482,7 @@ ${lanes.join("\n")}
|
|
|
126515
126482
|
let combinedUseSites;
|
|
126516
126483
|
forEach(converted, (c) => {
|
|
126517
126484
|
if (c.useSitesToUnqualify) {
|
|
126518
|
-
copyEntries(c.useSitesToUnqualify, combinedUseSites != null ? combinedUseSites : combinedUseSites = new Map());
|
|
126485
|
+
copyEntries(c.useSitesToUnqualify, combinedUseSites != null ? combinedUseSites : combinedUseSites = /* @__PURE__ */ new Map());
|
|
126519
126486
|
}
|
|
126520
126487
|
});
|
|
126521
126488
|
return combinedUseSites;
|
|
@@ -126678,7 +126645,7 @@ ${lanes.join("\n")}
|
|
|
126678
126645
|
}
|
|
126679
126646
|
function convertSingleIdentifierImport(name, moduleSpecifier, checker, identifiers, quotePreference) {
|
|
126680
126647
|
const nameSymbol = checker.getSymbolAtLocation(name);
|
|
126681
|
-
const namedBindingsNames = new Map();
|
|
126648
|
+
const namedBindingsNames = /* @__PURE__ */ new Map();
|
|
126682
126649
|
let needDefaultImport = false;
|
|
126683
126650
|
let useSitesToUnqualify;
|
|
126684
126651
|
for (const use of identifiers.original.get(name.text)) {
|
|
@@ -126691,7 +126658,7 @@ ${lanes.join("\n")}
|
|
|
126691
126658
|
if (propertyName === "default") {
|
|
126692
126659
|
needDefaultImport = true;
|
|
126693
126660
|
const importDefaultName = use.getText();
|
|
126694
|
-
(useSitesToUnqualify != null ? useSitesToUnqualify : useSitesToUnqualify = new Map()).set(parent2, factory.createIdentifier(importDefaultName));
|
|
126661
|
+
(useSitesToUnqualify != null ? useSitesToUnqualify : useSitesToUnqualify = /* @__PURE__ */ new Map()).set(parent2, factory.createIdentifier(importDefaultName));
|
|
126695
126662
|
} else {
|
|
126696
126663
|
Debug.assert(parent2.expression === use, "Didn't expect expression === use");
|
|
126697
126664
|
let idName = namedBindingsNames.get(propertyName);
|
|
@@ -126699,7 +126666,7 @@ ${lanes.join("\n")}
|
|
|
126699
126666
|
idName = makeUniqueName(propertyName, identifiers);
|
|
126700
126667
|
namedBindingsNames.set(propertyName, idName);
|
|
126701
126668
|
}
|
|
126702
|
-
(useSitesToUnqualify != null ? useSitesToUnqualify : useSitesToUnqualify = new Map()).set(parent2, factory.createIdentifier(idName));
|
|
126669
|
+
(useSitesToUnqualify != null ? useSitesToUnqualify : useSitesToUnqualify = /* @__PURE__ */ new Map()).set(parent2, factory.createIdentifier(idName));
|
|
126703
126670
|
}
|
|
126704
126671
|
} else {
|
|
126705
126672
|
needDefaultImport = true;
|
|
@@ -126842,7 +126809,7 @@ ${lanes.join("\n")}
|
|
|
126842
126809
|
},
|
|
126843
126810
|
fixIds: [fixId12],
|
|
126844
126811
|
getAllCodeActions: function getAllCodeActionsToConvertToTypeOnlyExport(context) {
|
|
126845
|
-
const fixedExportDeclarations = new Map();
|
|
126812
|
+
const fixedExportDeclarations = /* @__PURE__ */ new Map();
|
|
126846
126813
|
return codeFixAll(context, errorCodes13, (changes, diag2) => {
|
|
126847
126814
|
const exportSpecifier = getExportSpecifierForDiagnosticSpan(diag2, context.sourceFile);
|
|
126848
126815
|
if (exportSpecifier && addToSeen(fixedExportDeclarations, getNodeId(exportSpecifier.parent.parent))) {
|
|
@@ -127014,7 +126981,7 @@ ${lanes.join("\n")}
|
|
|
127014
126981
|
},
|
|
127015
126982
|
fixIds: [fixId15],
|
|
127016
126983
|
getAllCodeActions(context) {
|
|
127017
|
-
const seenClassDeclarations = new Map();
|
|
126984
|
+
const seenClassDeclarations = /* @__PURE__ */ new Map();
|
|
127018
126985
|
return codeFixAll(context, errorCodes16, (changes, diag2) => {
|
|
127019
126986
|
const classDeclaration = getClass(diag2.file, diag2.start);
|
|
127020
126987
|
if (addToSeen(seenClassDeclarations, getNodeId(classDeclaration))) {
|
|
@@ -127118,8 +127085,8 @@ ${lanes.join("\n")}
|
|
|
127118
127085
|
const compilerOptions = program.getCompilerOptions();
|
|
127119
127086
|
const addToNamespace = [];
|
|
127120
127087
|
const importType = [];
|
|
127121
|
-
const addToExisting = new Map();
|
|
127122
|
-
const newImports = new Map();
|
|
127088
|
+
const addToExisting = /* @__PURE__ */ new Map();
|
|
127089
|
+
const newImports = /* @__PURE__ */ new Map();
|
|
127123
127090
|
return { addImportFromDiagnostic, addImportFromExportedSymbol, writeFixes, hasFixes };
|
|
127124
127091
|
function addImportFromDiagnostic(diagnostic, context) {
|
|
127125
127092
|
const info = getFixInfos(context, diagnostic.code, diagnostic.start, useAutoImportProvider);
|
|
@@ -127154,7 +127121,7 @@ ${lanes.join("\n")}
|
|
|
127154
127121
|
const key = String(getNodeId(importClauseOrBindingPattern));
|
|
127155
127122
|
let entry = addToExisting.get(key);
|
|
127156
127123
|
if (!entry) {
|
|
127157
|
-
addToExisting.set(key, entry = { importClauseOrBindingPattern, defaultImport: void 0, namedImports: new Map() });
|
|
127124
|
+
addToExisting.set(key, entry = { importClauseOrBindingPattern, defaultImport: void 0, namedImports: /* @__PURE__ */ new Map() });
|
|
127158
127125
|
}
|
|
127159
127126
|
if (importKind === 0 /* Named */) {
|
|
127160
127127
|
const prevValue = entry == null ? void 0 : entry.namedImports.get(symbolName2);
|
|
@@ -127178,7 +127145,7 @@ ${lanes.join("\n")}
|
|
|
127178
127145
|
entry.defaultImport = { name: symbolName2, addAsTypeOnly: reduceAddAsTypeOnlyValues((_b = entry.defaultImport) == null ? void 0 : _b.addAsTypeOnly, addAsTypeOnly) };
|
|
127179
127146
|
break;
|
|
127180
127147
|
case 0 /* Named */:
|
|
127181
|
-
const prevValue = (entry.namedImports || (entry.namedImports = new Map())).get(symbolName2);
|
|
127148
|
+
const prevValue = (entry.namedImports || (entry.namedImports = /* @__PURE__ */ new Map())).get(symbolName2);
|
|
127182
127149
|
entry.namedImports.set(symbolName2, reduceAddAsTypeOnlyValues(prevValue, addAsTypeOnly));
|
|
127183
127150
|
break;
|
|
127184
127151
|
case 3 /* CommonJS */:
|
|
@@ -128087,7 +128054,7 @@ ${lanes.join("\n")}
|
|
|
128087
128054
|
fixIds: [fixId16],
|
|
128088
128055
|
getAllCodeActions: (context) => {
|
|
128089
128056
|
const { program, preferences, host } = context;
|
|
128090
|
-
const seen = new Map();
|
|
128057
|
+
const seen = /* @__PURE__ */ new Map();
|
|
128091
128058
|
return createCombinedCodeActions(ts_textChanges_exports.ChangeTracker.with(context, (changes) => {
|
|
128092
128059
|
eachDiagnostic(context, errorCodes18, (diag2) => {
|
|
128093
128060
|
const info = getInfo3(program, diag2.file, createTextSpan(diag2.start, diag2.length));
|
|
@@ -128400,7 +128367,7 @@ ${lanes.join("\n")}
|
|
|
128400
128367
|
getAllCodeActions(context) {
|
|
128401
128368
|
const { program } = context;
|
|
128402
128369
|
return createCombinedCodeActions(ts_textChanges_exports.ChangeTracker.with(context, (changes) => {
|
|
128403
|
-
const exports = new Map();
|
|
128370
|
+
const exports = /* @__PURE__ */ new Map();
|
|
128404
128371
|
eachDiagnostic(context, errorCodes22, (diag2) => {
|
|
128405
128372
|
const info = getInfo4(diag2.file, diag2.start, program);
|
|
128406
128373
|
if (info === void 0)
|
|
@@ -128950,8 +128917,8 @@ ${lanes.join("\n")}
|
|
|
128950
128917
|
getAllCodeActions: (context) => {
|
|
128951
128918
|
const { program, fixId: fixId52 } = context;
|
|
128952
128919
|
const checker = program.getTypeChecker();
|
|
128953
|
-
const seen = new Map();
|
|
128954
|
-
const typeDeclToMembers = new Map();
|
|
128920
|
+
const seen = /* @__PURE__ */ new Map();
|
|
128921
|
+
const typeDeclToMembers = /* @__PURE__ */ new Map();
|
|
128955
128922
|
return createCombinedCodeActions(ts_textChanges_exports.ChangeTracker.with(context, (changes) => {
|
|
128956
128923
|
eachDiagnostic(context, errorCodes26, (diag2) => {
|
|
128957
128924
|
const info = getInfo7(diag2.file, diag2.start, diag2.code, checker, context.program);
|
|
@@ -129385,7 +129352,7 @@ ${lanes.join("\n")}
|
|
|
129385
129352
|
const targetProps = attrsType.getProperties();
|
|
129386
129353
|
if (!length(targetProps))
|
|
129387
129354
|
return emptyArray;
|
|
129388
|
-
const seenNames = new Set();
|
|
129355
|
+
const seenNames = /* @__PURE__ */ new Set();
|
|
129389
129356
|
for (const sourceProp of source.attributes.properties) {
|
|
129390
129357
|
if (isJsxAttribute(sourceProp)) {
|
|
129391
129358
|
seenNames.add(sourceProp.name.escapedText);
|
|
@@ -129519,7 +129486,7 @@ ${lanes.join("\n")}
|
|
|
129519
129486
|
},
|
|
129520
129487
|
fixIds: [fixId24],
|
|
129521
129488
|
getAllCodeActions: function getAllCodeActionsToFixClassDoesntImplementInheritedAbstractMember(context) {
|
|
129522
|
-
const seenClassDeclarations = new Map();
|
|
129489
|
+
const seenClassDeclarations = /* @__PURE__ */ new Map();
|
|
129523
129490
|
return codeFixAll(context, errorCodes29, (changes, diag2) => {
|
|
129524
129491
|
const classDeclaration = getClass2(diag2.file, diag2.start);
|
|
129525
129492
|
if (addToSeen(seenClassDeclarations, getNodeId(classDeclaration))) {
|
|
@@ -129563,7 +129530,7 @@ ${lanes.join("\n")}
|
|
|
129563
129530
|
fixIds: [fixId25],
|
|
129564
129531
|
getAllCodeActions(context) {
|
|
129565
129532
|
const { sourceFile } = context;
|
|
129566
|
-
const seenClasses = new Map();
|
|
129533
|
+
const seenClasses = /* @__PURE__ */ new Map();
|
|
129567
129534
|
return codeFixAll(context, errorCodes30, (changes, diag2) => {
|
|
129568
129535
|
const nodes = getNodes(diag2.file, diag2.start);
|
|
129569
129536
|
if (!nodes)
|
|
@@ -129935,7 +129902,7 @@ ${lanes.join("\n")}
|
|
|
129935
129902
|
return void 0;
|
|
129936
129903
|
},
|
|
129937
129904
|
getAllCodeActions: function getAllCodeActionsToFixUnmatchedParameter(context) {
|
|
129938
|
-
const tagsToSignature = new Map();
|
|
129905
|
+
const tagsToSignature = /* @__PURE__ */ new Map();
|
|
129939
129906
|
return createCombinedCodeActions(ts_textChanges_exports.ChangeTracker.with(context, (changes) => {
|
|
129940
129907
|
eachDiagnostic(context, errorCodes39, ({ file, start: start2 }) => {
|
|
129941
129908
|
const info = getInfo10(file, start2);
|
|
@@ -129967,7 +129934,7 @@ ${lanes.join("\n")}
|
|
|
129967
129934
|
return void 0;
|
|
129968
129935
|
const sourceFile = context.sourceFile;
|
|
129969
129936
|
const tags = getJSDocTags(signature);
|
|
129970
|
-
const names = new Set();
|
|
129937
|
+
const names = /* @__PURE__ */ new Set();
|
|
129971
129938
|
for (const tag of tags) {
|
|
129972
129939
|
if (isJSDocParameterTag(tag) && isIdentifier(tag.name)) {
|
|
129973
129940
|
names.add(tag.name.escapedText);
|
|
@@ -130545,7 +130512,7 @@ ${lanes.join("\n")}
|
|
|
130545
130512
|
},
|
|
130546
130513
|
fixIds: [fixId36],
|
|
130547
130514
|
getAllCodeActions: function getAllCodeActionsToFixAwaitInSyncFunction(context) {
|
|
130548
|
-
const seen = new Map();
|
|
130515
|
+
const seen = /* @__PURE__ */ new Map();
|
|
130549
130516
|
return codeFixAll(context, errorCodes46, (changes, diag2) => {
|
|
130550
130517
|
const nodes = getNodes3(diag2.file, diag2.start);
|
|
130551
130518
|
if (!nodes || !addToSeen(seen, getNodeId(nodes.insertBefore)))
|
|
@@ -131002,7 +130969,7 @@ ${lanes.join("\n")}
|
|
|
131002
130969
|
};
|
|
131003
130970
|
}
|
|
131004
130971
|
function combineUsages(usages) {
|
|
131005
|
-
const combinedProperties = new Map();
|
|
130972
|
+
const combinedProperties = /* @__PURE__ */ new Map();
|
|
131006
130973
|
for (const u of usages) {
|
|
131007
130974
|
if (u.properties) {
|
|
131008
130975
|
u.properties.forEach((p, name) => {
|
|
@@ -131013,7 +130980,7 @@ ${lanes.join("\n")}
|
|
|
131013
130980
|
});
|
|
131014
130981
|
}
|
|
131015
130982
|
}
|
|
131016
|
-
const properties = new Map();
|
|
130983
|
+
const properties = /* @__PURE__ */ new Map();
|
|
131017
130984
|
combinedProperties.forEach((ps, name) => {
|
|
131018
130985
|
properties.set(name, combineUsages(ps));
|
|
131019
130986
|
});
|
|
@@ -131260,7 +131227,7 @@ ${lanes.join("\n")}
|
|
|
131260
131227
|
function inferTypeFromPropertyAccessExpression(parent2, usage) {
|
|
131261
131228
|
const name = escapeLeadingUnderscores(parent2.name.text);
|
|
131262
131229
|
if (!usage.properties) {
|
|
131263
|
-
usage.properties = new Map();
|
|
131230
|
+
usage.properties = /* @__PURE__ */ new Map();
|
|
131264
131231
|
}
|
|
131265
131232
|
const propertyUsage = usage.properties.get(name) || createEmptyUsage();
|
|
131266
131233
|
calculateUsageOfNode(parent2, propertyUsage);
|
|
@@ -131410,7 +131377,7 @@ ${lanes.join("\n")}
|
|
|
131410
131377
|
return types;
|
|
131411
131378
|
}
|
|
131412
131379
|
function inferStructuralType(usage) {
|
|
131413
|
-
const members = new Map();
|
|
131380
|
+
const members = /* @__PURE__ */ new Map();
|
|
131414
131381
|
if (usage.properties) {
|
|
131415
131382
|
usage.properties.forEach((u, name) => {
|
|
131416
131383
|
const symbol = checker.createSymbol(4 /* Property */, name);
|
|
@@ -131628,7 +131595,7 @@ ${lanes.join("\n")}
|
|
|
131628
131595
|
},
|
|
131629
131596
|
fixIds: [fixId40],
|
|
131630
131597
|
getAllCodeActions: (context) => {
|
|
131631
|
-
const seenLines = new Set();
|
|
131598
|
+
const seenLines = /* @__PURE__ */ new Set();
|
|
131632
131599
|
return codeFixAll(context, errorCodes50, (changes, diag2) => {
|
|
131633
131600
|
if (ts_textChanges_exports.isValidLocationToAddComment(diag2.file, diag2.start)) {
|
|
131634
131601
|
makeChange8(changes, diag2.file, diag2.start, seenLines);
|
|
@@ -131969,7 +131936,7 @@ ${lanes.join("\n")}
|
|
|
131969
131936
|
}
|
|
131970
131937
|
function getArgumentTypesAndTypeParameters(checker, importAdder, instanceTypes, contextNode, scriptTarget, flags, tracker) {
|
|
131971
131938
|
const argumentTypeNodes = [];
|
|
131972
|
-
const argumentTypeParameters = new Map();
|
|
131939
|
+
const argumentTypeParameters = /* @__PURE__ */ new Map();
|
|
131973
131940
|
for (let i = 0; i < instanceTypes.length; i += 1) {
|
|
131974
131941
|
const instanceType = instanceTypes[i];
|
|
131975
131942
|
if (instanceType.isUnionOrIntersection() && instanceType.types.some(typeContainsTypeParameter)) {
|
|
@@ -132009,7 +131976,7 @@ ${lanes.join("\n")}
|
|
|
132009
131976
|
}
|
|
132010
131977
|
function createDummyParameters(argCount, names, types, minArgumentCount, inJs) {
|
|
132011
131978
|
const parameters = [];
|
|
132012
|
-
const parameterNameCounts = new Map();
|
|
131979
|
+
const parameterNameCounts = /* @__PURE__ */ new Map();
|
|
132013
131980
|
for (let i = 0; i < argCount; i++) {
|
|
132014
131981
|
const parameterName = (names == null ? void 0 : names[i]) || `arg${i}`;
|
|
132015
131982
|
const parameterNameCount = parameterNameCounts.get(parameterName);
|
|
@@ -132972,7 +132939,7 @@ ${lanes.join("\n")}
|
|
|
132972
132939
|
},
|
|
132973
132940
|
getAllCodeActions: (context) => {
|
|
132974
132941
|
const { program } = context;
|
|
132975
|
-
const seen = new Map();
|
|
132942
|
+
const seen = /* @__PURE__ */ new Map();
|
|
132976
132943
|
return createCombinedCodeActions(ts_textChanges_exports.ChangeTracker.with(context, (changes) => {
|
|
132977
132944
|
eachDiagnostic(context, errorCodes61, (diag2) => {
|
|
132978
132945
|
const info = getInfo17(diag2.file, diag2.start, program);
|
|
@@ -133058,7 +133025,7 @@ ${lanes.join("\n")}
|
|
|
133058
133025
|
}
|
|
133059
133026
|
},
|
|
133060
133027
|
getAllCodeActions(context) {
|
|
133061
|
-
return codeFixAll(context, errorCodes63, (changes, diag2) => makeChange11(changes, diag2.file, diag2, context.program, new Set()));
|
|
133028
|
+
return codeFixAll(context, errorCodes63, (changes, diag2) => makeChange11(changes, diag2.file, diag2, context.program, /* @__PURE__ */ new Set()));
|
|
133062
133029
|
}
|
|
133063
133030
|
});
|
|
133064
133031
|
function makeChange11(changes, sourceFile, span, program, seen) {
|
|
@@ -134057,7 +134024,7 @@ ${lanes.join("\n")}
|
|
|
134057
134024
|
const variableDeclaration = getVariableDeclaration(location2);
|
|
134058
134025
|
const useSemicolons = probablyUsesSemicolons(sourceFile);
|
|
134059
134026
|
const typeChecker = program.getTypeChecker();
|
|
134060
|
-
const uniques = new Map();
|
|
134027
|
+
const uniques = /* @__PURE__ */ new Map();
|
|
134061
134028
|
for (let i = 0; i < symbols.length; i++) {
|
|
134062
134029
|
const symbol = symbols[i];
|
|
134063
134030
|
const origin = symbolToOriginInfoMap == null ? void 0 : symbolToOriginInfoMap[i];
|
|
@@ -134136,7 +134103,7 @@ ${lanes.join("\n")}
|
|
|
134136
134103
|
}
|
|
134137
134104
|
function getLabelStatementCompletions(node) {
|
|
134138
134105
|
const entries = [];
|
|
134139
|
-
const uniques = new Map();
|
|
134106
|
+
const uniques = /* @__PURE__ */ new Map();
|
|
134140
134107
|
let current = node;
|
|
134141
134108
|
while (current) {
|
|
134142
134109
|
if (isFunctionLike(current)) {
|
|
@@ -134562,7 +134529,7 @@ ${lanes.join("\n")}
|
|
|
134562
134529
|
let importSpecifierResolver;
|
|
134563
134530
|
const symbolToOriginInfoMap = [];
|
|
134564
134531
|
const symbolToSortTextMap = [];
|
|
134565
|
-
const seenPropertySymbols = new Map();
|
|
134532
|
+
const seenPropertySymbols = /* @__PURE__ */ new Map();
|
|
134566
134533
|
const isTypeOnlyLocation = isTypeOnlyCompletion();
|
|
134567
134534
|
const getModuleSpecifierResolutionHost = memoizeOne((isFromPackageJson) => {
|
|
134568
134535
|
return createModuleSpecifierResolutionHost(isFromPackageJson ? host.getPackageJsonAutoImportProvider() : program, host);
|
|
@@ -135149,7 +135116,7 @@ ${lanes.join("\n")}
|
|
|
135149
135116
|
const containerActualType = typeChecker.getTypeFromTypeNode(containerTypeNode);
|
|
135150
135117
|
const members = getPropertiesForCompletion(containerExpectedType, typeChecker);
|
|
135151
135118
|
const existingMembers = getPropertiesForCompletion(containerActualType, typeChecker);
|
|
135152
|
-
const existingMemberEscapedNames = new Set();
|
|
135119
|
+
const existingMemberEscapedNames = /* @__PURE__ */ new Set();
|
|
135153
135120
|
existingMembers.forEach((s) => existingMemberEscapedNames.add(s.escapedName));
|
|
135154
135121
|
symbols = concatenate(symbols, filter(members, (s) => !existingMemberEscapedNames.has(s.escapedName)));
|
|
135155
135122
|
completionKind = 0 /* ObjectPropertyDeclaration */;
|
|
@@ -135490,8 +135457,8 @@ ${lanes.join("\n")}
|
|
|
135490
135457
|
if (existingMembers.length === 0) {
|
|
135491
135458
|
return contextualMemberSymbols;
|
|
135492
135459
|
}
|
|
135493
|
-
const membersDeclaredBySpreadAssignment = new Set();
|
|
135494
|
-
const existingMemberNames = new Set();
|
|
135460
|
+
const membersDeclaredBySpreadAssignment = /* @__PURE__ */ new Set();
|
|
135461
|
+
const existingMemberNames = /* @__PURE__ */ new Set();
|
|
135495
135462
|
for (const m of existingMembers) {
|
|
135496
135463
|
if (m.kind !== 299 /* PropertyAssignment */ && m.kind !== 300 /* ShorthandPropertyAssignment */ && m.kind !== 205 /* BindingElement */ && m.kind !== 171 /* MethodDeclaration */ && m.kind !== 174 /* GetAccessor */ && m.kind !== 175 /* SetAccessor */ && m.kind !== 301 /* SpreadAssignment */) {
|
|
135497
135464
|
continue;
|
|
@@ -135570,7 +135537,7 @@ ${lanes.join("\n")}
|
|
|
135570
135537
|
}
|
|
135571
135538
|
}
|
|
135572
135539
|
function filterClassMembersList(baseSymbols, existingMembers, currentClassElementModifierFlags) {
|
|
135573
|
-
const existingMemberNames = new Set();
|
|
135540
|
+
const existingMemberNames = /* @__PURE__ */ new Set();
|
|
135574
135541
|
for (const m of existingMembers) {
|
|
135575
135542
|
if (m.kind !== 169 /* PropertyDeclaration */ && m.kind !== 171 /* MethodDeclaration */ && m.kind !== 174 /* GetAccessor */ && m.kind !== 175 /* SetAccessor */) {
|
|
135576
135543
|
continue;
|
|
@@ -135592,8 +135559,8 @@ ${lanes.join("\n")}
|
|
|
135592
135559
|
return baseSymbols.filter((propertySymbol) => !existingMemberNames.has(propertySymbol.escapedName) && !!propertySymbol.declarations && !(getDeclarationModifierFlagsFromSymbol(propertySymbol) & 8 /* Private */) && !(propertySymbol.valueDeclaration && isPrivateIdentifierClassElementDeclaration(propertySymbol.valueDeclaration)));
|
|
135593
135560
|
}
|
|
135594
135561
|
function filterJsxAttributes(symbols2, attributes) {
|
|
135595
|
-
const seenNames = new Set();
|
|
135596
|
-
const membersDeclaredBySpreadAssignment = new Set();
|
|
135562
|
+
const seenNames = /* @__PURE__ */ new Set();
|
|
135563
|
+
const membersDeclaredBySpreadAssignment = /* @__PURE__ */ new Set();
|
|
135597
135564
|
for (const attr of attributes) {
|
|
135598
135565
|
if (isCurrentlyEditingNode(attr)) {
|
|
135599
135566
|
continue;
|
|
@@ -136070,7 +136037,7 @@ ${lanes.join("\n")}
|
|
|
136070
136037
|
function isArrowFunctionBody(node) {
|
|
136071
136038
|
return node.parent && isArrowFunction(node.parent) && node.parent.body === node;
|
|
136072
136039
|
}
|
|
136073
|
-
function symbolCanBeReferencedAtTypeLocation(symbol, checker, seenModules = new Map()) {
|
|
136040
|
+
function symbolCanBeReferencedAtTypeLocation(symbol, checker, seenModules = /* @__PURE__ */ new Map()) {
|
|
136074
136041
|
return nonAliasCanBeReferencedAtTypeLocation(symbol) || nonAliasCanBeReferencedAtTypeLocation(skipAlias(symbol.exportSymbol || symbol, checker));
|
|
136075
136042
|
function nonAliasCanBeReferencedAtTypeLocation(symbol2) {
|
|
136076
136043
|
return !!(symbol2.flags & 788968 /* Type */) || checker.isUnknownSymbol(symbol2) || !!(symbol2.flags & 1536 /* Module */) && addToSeen(seenModules, getSymbolId(symbol2)) && checker.getExportsOfModule(symbol2).some((e) => symbolCanBeReferencedAtTypeLocation(e, checker, seenModules));
|
|
@@ -136125,7 +136092,7 @@ ${lanes.join("\n")}
|
|
|
136125
136092
|
["external module name" /* externalModuleName */]: 2
|
|
136126
136093
|
};
|
|
136127
136094
|
function createNameAndKindSet() {
|
|
136128
|
-
const map2 = new Map();
|
|
136095
|
+
const map2 = /* @__PURE__ */ new Map();
|
|
136129
136096
|
function add(value) {
|
|
136130
136097
|
const existing = map2.get(value.name);
|
|
136131
136098
|
if (!existing || kindPrecedence[existing.kind] < kindPrecedence[value.kind]) {
|
|
@@ -136339,7 +136306,7 @@ ${lanes.join("\n")}
|
|
|
136339
136306
|
}
|
|
136340
136307
|
function getStringLiteralCompletionsFromSignature(call, arg, argumentInfo, checker) {
|
|
136341
136308
|
let isNewIdentifier = false;
|
|
136342
|
-
const uniques = new Map();
|
|
136309
|
+
const uniques = /* @__PURE__ */ new Map();
|
|
136343
136310
|
const candidates = [];
|
|
136344
136311
|
const editingArgument = isJsxOpeningLikeElement(call) ? Debug.checkDefined(findAncestor(arg.parent, isJsxAttribute)) : arg;
|
|
136345
136312
|
checker.getResolvedSignatureForStringLiteralCompletions(call, editingArgument, candidates);
|
|
@@ -136382,7 +136349,7 @@ ${lanes.join("\n")}
|
|
|
136382
136349
|
hasIndexSignature: hasIndexSignature(contextualType)
|
|
136383
136350
|
};
|
|
136384
136351
|
}
|
|
136385
|
-
function getStringLiteralTypes(type, uniques = new Map()) {
|
|
136352
|
+
function getStringLiteralTypes(type, uniques = /* @__PURE__ */ new Map()) {
|
|
136386
136353
|
if (!type)
|
|
136387
136354
|
return emptyArray;
|
|
136388
136355
|
type = skipConstraint(type);
|
|
@@ -136754,7 +136721,7 @@ ${lanes.join("\n")}
|
|
|
136754
136721
|
return addReplacementSpans(toComplete, range.pos + prefix.length, arrayFrom(names.values()));
|
|
136755
136722
|
}
|
|
136756
136723
|
function getCompletionEntriesFromTypings(host, options, scriptPath, fragmentDirectory, extensionOptions, result = createNameAndKindSet()) {
|
|
136757
|
-
const seen = new Map();
|
|
136724
|
+
const seen = /* @__PURE__ */ new Map();
|
|
136758
136725
|
const typeRoots = tryAndIgnoreErrors(() => getEffectiveTypeRoots(options, host)) || emptyArray;
|
|
136759
136726
|
for (const root of typeRoots) {
|
|
136760
136727
|
getCompletionEntriesFromDirectories(root);
|
|
@@ -137136,7 +137103,7 @@ ${lanes.join("\n")}
|
|
|
137136
137103
|
return refs;
|
|
137137
137104
|
}
|
|
137138
137105
|
function getDirectImportsMap(sourceFiles, checker, cancellationToken) {
|
|
137139
|
-
const map2 = new Map();
|
|
137106
|
+
const map2 = /* @__PURE__ */ new Map();
|
|
137140
137107
|
for (const sourceFile of sourceFiles) {
|
|
137141
137108
|
if (cancellationToken)
|
|
137142
137109
|
cancellationToken.throwIfCancellationRequested();
|
|
@@ -137485,7 +137452,7 @@ ${lanes.join("\n")}
|
|
|
137485
137452
|
referenceEntries = entries && [...entries];
|
|
137486
137453
|
} else if (entries) {
|
|
137487
137454
|
const queue = createQueue(entries);
|
|
137488
|
-
const seenNodes = new Map();
|
|
137455
|
+
const seenNodes = /* @__PURE__ */ new Map();
|
|
137489
137456
|
while (!queue.isEmpty()) {
|
|
137490
137457
|
const entry = queue.dequeue();
|
|
137491
137458
|
if (!addToSeen(seenNodes, getNodeId(entry.node))) {
|
|
@@ -138128,7 +138095,7 @@ ${lanes.join("\n")}
|
|
|
138128
138095
|
this.searchMeaning = searchMeaning;
|
|
138129
138096
|
this.options = options;
|
|
138130
138097
|
this.result = result;
|
|
138131
|
-
this.inheritsFromCache = new Map();
|
|
138098
|
+
this.inheritsFromCache = /* @__PURE__ */ new Map();
|
|
138132
138099
|
this.markSeenContainingTypeReference = nodeSeenTracker();
|
|
138133
138100
|
this.markSeenReExportRHS = nodeSeenTracker();
|
|
138134
138101
|
this.symbolIdToReferences = [];
|
|
@@ -138168,7 +138135,7 @@ ${lanes.join("\n")}
|
|
|
138168
138135
|
}
|
|
138169
138136
|
markSearchedSymbols(sourceFile, symbols) {
|
|
138170
138137
|
const sourceId = getNodeId(sourceFile);
|
|
138171
|
-
const seenSymbols = this.sourceFileToSeenSymbols[sourceId] || (this.sourceFileToSeenSymbols[sourceId] = new Set());
|
|
138138
|
+
const seenSymbols = this.sourceFileToSeenSymbols[sourceId] || (this.sourceFileToSeenSymbols[sourceId] = /* @__PURE__ */ new Set());
|
|
138172
138139
|
let anyNewSymbols = false;
|
|
138173
138140
|
for (const sym of symbols) {
|
|
138174
138141
|
anyNewSymbols = tryAddToSet(seenSymbols, getSymbolId(sym)) || anyNewSymbols;
|
|
@@ -138954,7 +138921,7 @@ ${lanes.join("\n")}
|
|
|
138954
138921
|
}
|
|
138955
138922
|
}
|
|
138956
138923
|
function getPropertySymbolsFromBaseTypes(symbol, propertyName, checker, cb) {
|
|
138957
|
-
const seen = new Map();
|
|
138924
|
+
const seen = /* @__PURE__ */ new Map();
|
|
138958
138925
|
return recur(symbol);
|
|
138959
138926
|
function recur(symbol2) {
|
|
138960
138927
|
if (!(symbol2.flags & (32 /* Class */ | 64 /* Interface */)) || !addToSeen(seen, getSymbolId(symbol2)))
|
|
@@ -140809,7 +140776,7 @@ ${lanes.join("\n")}
|
|
|
140809
140776
|
});
|
|
140810
140777
|
|
|
140811
140778
|
// src/services/refactorProvider.ts
|
|
140812
|
-
var refactors = new Map();
|
|
140779
|
+
var refactors = /* @__PURE__ */ new Map();
|
|
140813
140780
|
function registerRefactor(name, refactor) {
|
|
140814
140781
|
refactors.set(name, refactor);
|
|
140815
140782
|
}
|
|
@@ -141132,7 +141099,7 @@ ${lanes.join("\n")}
|
|
|
141132
141099
|
function doChangeNamespaceToNamed(sourceFile, checker, changes, toConvert, allowSyntheticDefaultImports) {
|
|
141133
141100
|
let usedAsNamespaceOrDefault = false;
|
|
141134
141101
|
const nodesToReplace = [];
|
|
141135
|
-
const conflictingNames = new Map();
|
|
141102
|
+
const conflictingNames = /* @__PURE__ */ new Map();
|
|
141136
141103
|
ts_FindAllReferences_exports.Core.eachSymbolReferenceInFile(toConvert.name, checker, sourceFile, (id) => {
|
|
141137
141104
|
if (!isPropertyAccessOrQualifiedName(id.parent)) {
|
|
141138
141105
|
usedAsNamespaceOrDefault = true;
|
|
@@ -141145,7 +141112,7 @@ ${lanes.join("\n")}
|
|
|
141145
141112
|
nodesToReplace.push(id.parent);
|
|
141146
141113
|
}
|
|
141147
141114
|
});
|
|
141148
|
-
const exportNameToImportName = new Map();
|
|
141115
|
+
const exportNameToImportName = /* @__PURE__ */ new Map();
|
|
141149
141116
|
for (const propertyAccessOrQualifiedName of nodesToReplace) {
|
|
141150
141117
|
const exportName = getRightOfPropertyAccessOrQualifiedName(propertyAccessOrQualifiedName).text;
|
|
141151
141118
|
let importName = exportNameToImportName.get(exportName);
|
|
@@ -141175,7 +141142,7 @@ ${lanes.join("\n")}
|
|
|
141175
141142
|
const checker = program.getTypeChecker();
|
|
141176
141143
|
const importDecl = toConvert.parent.parent;
|
|
141177
141144
|
const { moduleSpecifier } = importDecl;
|
|
141178
|
-
const toConvertSymbols = new Set();
|
|
141145
|
+
const toConvertSymbols = /* @__PURE__ */ new Set();
|
|
141179
141146
|
toConvert.elements.forEach((namedImport) => {
|
|
141180
141147
|
const symbol = checker.getSymbolAtLocation(namedImport.name);
|
|
141181
141148
|
if (symbol) {
|
|
@@ -141197,7 +141164,7 @@ ${lanes.join("\n")}
|
|
|
141197
141164
|
}
|
|
141198
141165
|
const namespaceNameConflicts = toConvert.elements.some(hasNamespaceNameConflict);
|
|
141199
141166
|
const namespaceImportName = namespaceNameConflicts ? getUniqueName(preferredName, sourceFile) : preferredName;
|
|
141200
|
-
const neededNamedImports = new Set();
|
|
141167
|
+
const neededNamedImports = /* @__PURE__ */ new Set();
|
|
141201
141168
|
for (const element of toConvert.elements) {
|
|
141202
141169
|
const propertyName = (element.propertyName || element.name).text;
|
|
141203
141170
|
ts_FindAllReferences_exports.Core.eachSymbolReferenceInFile(element.name, checker, sourceFile, (id) => {
|
|
@@ -141327,7 +141294,7 @@ ${lanes.join("\n")}
|
|
|
141327
141294
|
return void 0;
|
|
141328
141295
|
if (isIntersectionTypeNode(node)) {
|
|
141329
141296
|
const result = [];
|
|
141330
|
-
const seen = new Map();
|
|
141297
|
+
const seen = /* @__PURE__ */ new Map();
|
|
141331
141298
|
for (const type of node.types) {
|
|
141332
141299
|
const flattenedTypeMembers = flattenTypeLiteralNodeReference(checker, type);
|
|
141333
141300
|
if (!flattenedTypeMembers || !flattenedTypeMembers.every((type2) => type2.name && addToSeen(seen, getNameFromPropertyName(type2.name)))) {
|
|
@@ -141979,7 +141946,7 @@ ${lanes.join("\n")}
|
|
|
141979
141946
|
}
|
|
141980
141947
|
var SymbolSet = class {
|
|
141981
141948
|
constructor() {
|
|
141982
|
-
this.map = new Map();
|
|
141949
|
+
this.map = /* @__PURE__ */ new Map();
|
|
141983
141950
|
}
|
|
141984
141951
|
add(symbol) {
|
|
141985
141952
|
this.map.set(String(getSymbolId(symbol)), symbol);
|
|
@@ -143643,10 +143610,10 @@ ${newComment.split("\n").map((c) => ` * ${c}`).join("\n")}
|
|
|
143643
143610
|
return emptyArray;
|
|
143644
143611
|
}
|
|
143645
143612
|
const functionActions = [];
|
|
143646
|
-
const usedFunctionNames = new Map();
|
|
143613
|
+
const usedFunctionNames = /* @__PURE__ */ new Map();
|
|
143647
143614
|
let innermostErrorFunctionAction;
|
|
143648
143615
|
const constantActions = [];
|
|
143649
|
-
const usedConstantNames = new Map();
|
|
143616
|
+
const usedConstantNames = /* @__PURE__ */ new Map();
|
|
143650
143617
|
let innermostErrorConstantAction;
|
|
143651
143618
|
let i = 0;
|
|
143652
143619
|
for (const { functionExtraction, constantExtraction } of extractions) {
|
|
@@ -144755,13 +144722,13 @@ ${newComment.split("\n").map((c) => ` * ${c}`).join("\n")}
|
|
|
144755
144722
|
return Usage2;
|
|
144756
144723
|
})(Usage || {});
|
|
144757
144724
|
function collectReadsAndWrites(targetRange, scopes, enclosingTextRange, sourceFile, checker, cancellationToken) {
|
|
144758
|
-
const allTypeParameterUsages = new Map();
|
|
144725
|
+
const allTypeParameterUsages = /* @__PURE__ */ new Map();
|
|
144759
144726
|
const usagesPerScope = [];
|
|
144760
144727
|
const substitutionsPerScope = [];
|
|
144761
144728
|
const functionErrorsPerScope = [];
|
|
144762
144729
|
const constantErrorsPerScope = [];
|
|
144763
144730
|
const visibleDeclarationsInExtractedRange = [];
|
|
144764
|
-
const exposedVariableSymbolSet = new Map();
|
|
144731
|
+
const exposedVariableSymbolSet = /* @__PURE__ */ new Map();
|
|
144765
144732
|
const exposedVariableDeclarations = [];
|
|
144766
144733
|
let firstExposedNonVariableDeclaration;
|
|
144767
144734
|
const expression = !isReadonlyArray(targetRange.range) ? targetRange.range : targetRange.range.length === 1 && isExpressionStatement(targetRange.range[0]) ? targetRange.range[0].expression : void 0;
|
|
@@ -144775,8 +144742,8 @@ ${newComment.split("\n").map((c) => ` * ${c}`).join("\n")}
|
|
|
144775
144742
|
expressionDiagnostic = createDiagnosticForNode(expression, Messages.uselessConstantType);
|
|
144776
144743
|
}
|
|
144777
144744
|
for (const scope of scopes) {
|
|
144778
|
-
usagesPerScope.push({ usages: new Map(), typeParameterUsages: new Map(), substitutions: new Map() });
|
|
144779
|
-
substitutionsPerScope.push(new Map());
|
|
144745
|
+
usagesPerScope.push({ usages: /* @__PURE__ */ new Map(), typeParameterUsages: /* @__PURE__ */ new Map(), substitutions: /* @__PURE__ */ new Map() });
|
|
144746
|
+
substitutionsPerScope.push(/* @__PURE__ */ new Map());
|
|
144780
144747
|
functionErrorsPerScope.push([]);
|
|
144781
144748
|
const constantErrors = [];
|
|
144782
144749
|
if (expressionDiagnostic) {
|
|
@@ -144790,7 +144757,7 @@ ${newComment.split("\n").map((c) => ` * ${c}`).join("\n")}
|
|
|
144790
144757
|
}
|
|
144791
144758
|
constantErrorsPerScope.push(constantErrors);
|
|
144792
144759
|
}
|
|
144793
|
-
const seenUsages = new Map();
|
|
144760
|
+
const seenUsages = /* @__PURE__ */ new Map();
|
|
144794
144761
|
const target = isReadonlyArray(targetRange.range) ? factory.createBlock(targetRange.range) : targetRange.range;
|
|
144795
144762
|
const unmodifiedNode = isReadonlyArray(targetRange.range) ? first(targetRange.range) : targetRange.range;
|
|
144796
144763
|
const inGenericContext = isInGenericContext(unmodifiedNode);
|
|
@@ -144800,7 +144767,7 @@ ${newComment.split("\n").map((c) => ` * ${c}`).join("\n")}
|
|
|
144800
144767
|
recordTypeParameterUsages(contextualType);
|
|
144801
144768
|
}
|
|
144802
144769
|
if (allTypeParameterUsages.size > 0) {
|
|
144803
|
-
const seenTypeParameterUsages = new Map();
|
|
144770
|
+
const seenTypeParameterUsages = /* @__PURE__ */ new Map();
|
|
144804
144771
|
let i = 0;
|
|
144805
144772
|
for (let curr = unmodifiedNode; curr !== void 0 && i < scopes.length; curr = curr.parent) {
|
|
144806
144773
|
if (curr === scopes[i]) {
|
|
@@ -146818,7 +146785,7 @@ ${newComment.split("\n").map((c) => ` * ${c}`).join("\n")}
|
|
|
146818
146785
|
this.formatContext = formatContext;
|
|
146819
146786
|
this.changes = [];
|
|
146820
146787
|
this.newFiles = [];
|
|
146821
|
-
this.classesWithNodesInsertedAtStart = new Map();
|
|
146788
|
+
this.classesWithNodesInsertedAtStart = /* @__PURE__ */ new Map();
|
|
146822
146789
|
this.deletedNodes = [];
|
|
146823
146790
|
}
|
|
146824
146791
|
static fromContext(context) {
|
|
@@ -147267,7 +147234,7 @@ ${options.prefix}` : "\n" : options.prefix
|
|
|
147267
147234
|
});
|
|
147268
147235
|
}
|
|
147269
147236
|
finishDeleteDeclarations() {
|
|
147270
|
-
const deletedNodesInLists = new Set();
|
|
147237
|
+
const deletedNodesInLists = /* @__PURE__ */ new Set();
|
|
147271
147238
|
for (const { sourceFile, node } of this.deletedNodes) {
|
|
147272
147239
|
if (!this.deletedNodes.some((d) => d.sourceFile === sourceFile && rangeContainsRangeExclusive(d.node, node))) {
|
|
147273
147240
|
if (isArray(node)) {
|
|
@@ -151570,7 +151537,7 @@ ${options.prefix}` : "\n" : options.prefix
|
|
|
151570
151537
|
return fileName;
|
|
151571
151538
|
}
|
|
151572
151539
|
function createNormalizedPathMap() {
|
|
151573
|
-
const map2 = new Map();
|
|
151540
|
+
const map2 = /* @__PURE__ */ new Map();
|
|
151574
151541
|
return {
|
|
151575
151542
|
get(path) {
|
|
151576
151543
|
return map2.get(path);
|
|
@@ -151606,7 +151573,7 @@ ${options.prefix}` : "\n" : options.prefix
|
|
|
151606
151573
|
var ThrottledOperations = class {
|
|
151607
151574
|
constructor(host, logger) {
|
|
151608
151575
|
this.host = host;
|
|
151609
|
-
this.pendingTimeouts = new Map();
|
|
151576
|
+
this.pendingTimeouts = /* @__PURE__ */ new Map();
|
|
151610
151577
|
this.logger = logger.hasLevel(3 /* verbose */) ? logger : void 0;
|
|
151611
151578
|
}
|
|
151612
151579
|
schedule(operationId, delay, cb) {
|
|
@@ -152391,7 +152358,7 @@ ${options.prefix}` : "\n" : options.prefix
|
|
|
152391
152358
|
if ((arr1 || emptyArray2).length === 0 && (arr2 || emptyArray2).length === 0) {
|
|
152392
152359
|
return true;
|
|
152393
152360
|
}
|
|
152394
|
-
const set = new Map();
|
|
152361
|
+
const set = /* @__PURE__ */ new Map();
|
|
152395
152362
|
let unique = 0;
|
|
152396
152363
|
for (const v of arr1) {
|
|
152397
152364
|
if (set.get(v) !== true) {
|
|
@@ -152426,7 +152393,7 @@ ${options.prefix}` : "\n" : options.prefix
|
|
|
152426
152393
|
var TypingsCache = class {
|
|
152427
152394
|
constructor(installer) {
|
|
152428
152395
|
this.installer = installer;
|
|
152429
|
-
this.perProjectCache = new Map();
|
|
152396
|
+
this.perProjectCache = /* @__PURE__ */ new Map();
|
|
152430
152397
|
}
|
|
152431
152398
|
isKnownTypesPackageName(name) {
|
|
152432
152399
|
return this.installer.isKnownTypesPackageName(name);
|
|
@@ -152551,9 +152518,9 @@ ${options.prefix}` : "\n" : options.prefix
|
|
|
152551
152518
|
this.compileOnSaveEnabled = compileOnSaveEnabled;
|
|
152552
152519
|
this.watchOptions = watchOptions;
|
|
152553
152520
|
this.rootFiles = [];
|
|
152554
|
-
this.rootFilesMap = new Map();
|
|
152521
|
+
this.rootFilesMap = /* @__PURE__ */ new Map();
|
|
152555
152522
|
this.plugins = [];
|
|
152556
|
-
this.cachedUnresolvedImportsPerFile = new Map();
|
|
152523
|
+
this.cachedUnresolvedImportsPerFile = /* @__PURE__ */ new Map();
|
|
152557
152524
|
this.hasAddedorRemovedFiles = false;
|
|
152558
152525
|
this.hasAddedOrRemovedSymlinks = false;
|
|
152559
152526
|
this.lastReportedVersion = 0;
|
|
@@ -153167,12 +153134,12 @@ ${options.prefix}` : "\n" : options.prefix
|
|
|
153167
153134
|
this.markAsDirty();
|
|
153168
153135
|
}
|
|
153169
153136
|
registerFileUpdate(fileName) {
|
|
153170
|
-
(this.updatedFileNames || (this.updatedFileNames = new Set())).add(fileName);
|
|
153137
|
+
(this.updatedFileNames || (this.updatedFileNames = /* @__PURE__ */ new Set())).add(fileName);
|
|
153171
153138
|
}
|
|
153172
153139
|
markFileAsDirty(changedFile) {
|
|
153173
153140
|
this.markAsDirty();
|
|
153174
153141
|
if (this.exportMapCache && !this.exportMapCache.isEmpty()) {
|
|
153175
|
-
(this.changedFilesForExportMapCache || (this.changedFilesForExportMapCache = new Set())).add(changedFile);
|
|
153142
|
+
(this.changedFilesForExportMapCache || (this.changedFilesForExportMapCache = /* @__PURE__ */ new Set())).add(changedFile);
|
|
153176
153143
|
}
|
|
153177
153144
|
}
|
|
153178
153145
|
markAsDirty() {
|
|
@@ -153296,7 +153263,7 @@ ${options.prefix}` : "\n" : options.prefix
|
|
|
153296
153263
|
}
|
|
153297
153264
|
updateMissingFilePathsWatch(
|
|
153298
153265
|
this.program,
|
|
153299
|
-
this.missingFilesMap || (this.missingFilesMap = new Map()),
|
|
153266
|
+
this.missingFilesMap || (this.missingFilesMap = /* @__PURE__ */ new Map()),
|
|
153300
153267
|
(missingFilePath) => this.addMissingFileWatcher(missingFilePath)
|
|
153301
153268
|
);
|
|
153302
153269
|
if (this.generatedFilesMap) {
|
|
@@ -153430,7 +153397,7 @@ ${options.prefix}` : "\n" : options.prefix
|
|
|
153430
153397
|
if (this.generatedFilesMap.has(path))
|
|
153431
153398
|
return;
|
|
153432
153399
|
} else {
|
|
153433
|
-
this.generatedFilesMap = new Map();
|
|
153400
|
+
this.generatedFilesMap = /* @__PURE__ */ new Map();
|
|
153434
153401
|
}
|
|
153435
153402
|
this.generatedFilesMap.set(path, this.createGeneratedFileWatcher(generatedFile));
|
|
153436
153403
|
}
|
|
@@ -153564,8 +153531,8 @@ ${options.prefix}` : "\n" : options.prefix
|
|
|
153564
153531
|
(info2) => info2.fileName,
|
|
153565
153532
|
(info2) => info2.isSourceOfProjectReferenceRedirect
|
|
153566
153533
|
);
|
|
153567
|
-
const added = new Map();
|
|
153568
|
-
const removed = new Map();
|
|
153534
|
+
const added = /* @__PURE__ */ new Map();
|
|
153535
|
+
const removed = /* @__PURE__ */ new Map();
|
|
153569
153536
|
const updated = updatedFileNames ? arrayFrom(updatedFileNames.keys()) : [];
|
|
153570
153537
|
const updatedRedirects = [];
|
|
153571
153538
|
forEachEntry(currentFiles, (isSourceOfProjectReferenceRedirect, fileName) => {
|
|
@@ -154081,7 +154048,7 @@ ${options.prefix}` : "\n" : options.prefix
|
|
|
154081
154048
|
return rootNames || emptyArray;
|
|
154082
154049
|
function addDependency(dependency) {
|
|
154083
154050
|
if (!startsWith(dependency, "@types/")) {
|
|
154084
|
-
(dependencyNames || (dependencyNames = new Set())).add(dependency);
|
|
154051
|
+
(dependencyNames || (dependencyNames = /* @__PURE__ */ new Set())).add(dependency);
|
|
154085
154052
|
}
|
|
154086
154053
|
}
|
|
154087
154054
|
function getRootNamesFromPackageJson(packageJson, program2, symlinkCache, resolveJs) {
|
|
@@ -154219,7 +154186,7 @@ ${options.prefix}` : "\n" : options.prefix
|
|
|
154219
154186
|
getDirectoryPath(configFileName)
|
|
154220
154187
|
);
|
|
154221
154188
|
this.canonicalConfigFilePath = canonicalConfigFilePath;
|
|
154222
|
-
this.openFileWatchTriggered = new Map();
|
|
154189
|
+
this.openFileWatchTriggered = /* @__PURE__ */ new Map();
|
|
154223
154190
|
this.canConfigFileJsonReportNoInputFiles = false;
|
|
154224
154191
|
this.externalProjectRefCount = 0;
|
|
154225
154192
|
this.isInitialLoadPending = returnTrue;
|
|
@@ -154295,7 +154262,7 @@ ${options.prefix}` : "\n" : options.prefix
|
|
|
154295
154262
|
}
|
|
154296
154263
|
setPotentialProjectReference(canonicalConfigPath) {
|
|
154297
154264
|
Debug.assert(this.isInitialLoadPending());
|
|
154298
|
-
(this.potentialProjectReferences || (this.potentialProjectReferences = new Set())).add(canonicalConfigPath);
|
|
154265
|
+
(this.potentialProjectReferences || (this.potentialProjectReferences = /* @__PURE__ */ new Set())).add(canonicalConfigPath);
|
|
154299
154266
|
}
|
|
154300
154267
|
getResolvedProjectReferenceToRedirect(fileName) {
|
|
154301
154268
|
const program = this.getCurrentProgram();
|
|
@@ -154448,7 +154415,7 @@ ${options.prefix}` : "\n" : options.prefix
|
|
|
154448
154415
|
var OpenFileInfoTelemetryEvent = "openFileInfo";
|
|
154449
154416
|
var ensureProjectForOpenFileSchedule = "*ensureProjectForOpenFiles*";
|
|
154450
154417
|
function prepareConvertersForEnumLikeCompilerOptions(commandLineOptions) {
|
|
154451
|
-
const map2 = new Map();
|
|
154418
|
+
const map2 = /* @__PURE__ */ new Map();
|
|
154452
154419
|
for (const option of commandLineOptions) {
|
|
154453
154420
|
if (typeof option.type === "object") {
|
|
154454
154421
|
const optionMap = option.type;
|
|
@@ -154611,7 +154578,7 @@ ${options.prefix}` : "\n" : options.prefix
|
|
|
154611
154578
|
if (result)
|
|
154612
154579
|
return result;
|
|
154613
154580
|
} else if (projectReferenceProjectLoadKind !== 0 /* Find */) {
|
|
154614
|
-
seenResolvedRefs = new Map();
|
|
154581
|
+
seenResolvedRefs = /* @__PURE__ */ new Map();
|
|
154615
154582
|
const result = forEachResolvedProjectReferenceProjectWorker(
|
|
154616
154583
|
resolvedRefs,
|
|
154617
154584
|
project.getCompilerOptions(),
|
|
@@ -154654,7 +154621,7 @@ ${options.prefix}` : "\n" : options.prefix
|
|
|
154654
154621
|
if (result) {
|
|
154655
154622
|
return result;
|
|
154656
154623
|
}
|
|
154657
|
-
(seenResolvedRefs || (seenResolvedRefs = new Map())).set(canonicalPath, loadKind);
|
|
154624
|
+
(seenResolvedRefs || (seenResolvedRefs = /* @__PURE__ */ new Map())).set(canonicalPath, loadKind);
|
|
154658
154625
|
return ref.references && forEachResolvedProjectReferenceProjectWorker(ref.references, ref.commandLine.options, cb, loadKind, projectService, seenResolvedRefs);
|
|
154659
154626
|
});
|
|
154660
154627
|
}
|
|
@@ -154700,32 +154667,32 @@ ${options.prefix}` : "\n" : options.prefix
|
|
|
154700
154667
|
}
|
|
154701
154668
|
var _ProjectService = class {
|
|
154702
154669
|
constructor(opts) {
|
|
154703
|
-
this.filenameToScriptInfo = new Map();
|
|
154704
|
-
this.nodeModulesWatchers = new Map();
|
|
154705
|
-
this.filenameToScriptInfoVersion = new Map();
|
|
154706
|
-
this.allJsFilesForOpenFileTelemetry = new Map();
|
|
154707
|
-
this.externalProjectToConfiguredProjectMap = new Map();
|
|
154670
|
+
this.filenameToScriptInfo = /* @__PURE__ */ new Map();
|
|
154671
|
+
this.nodeModulesWatchers = /* @__PURE__ */ new Map();
|
|
154672
|
+
this.filenameToScriptInfoVersion = /* @__PURE__ */ new Map();
|
|
154673
|
+
this.allJsFilesForOpenFileTelemetry = /* @__PURE__ */ new Map();
|
|
154674
|
+
this.externalProjectToConfiguredProjectMap = /* @__PURE__ */ new Map();
|
|
154708
154675
|
this.externalProjects = [];
|
|
154709
154676
|
this.inferredProjects = [];
|
|
154710
|
-
this.configuredProjects = new Map();
|
|
154677
|
+
this.configuredProjects = /* @__PURE__ */ new Map();
|
|
154711
154678
|
this.newInferredProjectName = createProjectNameFactoryWithCounter(makeInferredProjectName);
|
|
154712
154679
|
this.newAutoImportProviderProjectName = createProjectNameFactoryWithCounter(makeAutoImportProviderProjectName);
|
|
154713
154680
|
this.newAuxiliaryProjectName = createProjectNameFactoryWithCounter(makeAuxiliaryProjectName);
|
|
154714
|
-
this.openFiles = new Map();
|
|
154715
|
-
this.configFileForOpenFiles = new Map();
|
|
154716
|
-
this.openFilesWithNonRootedDiskPath = new Map();
|
|
154717
|
-
this.compilerOptionsForInferredProjectsPerProjectRoot = new Map();
|
|
154718
|
-
this.watchOptionsForInferredProjectsPerProjectRoot = new Map();
|
|
154719
|
-
this.typeAcquisitionForInferredProjectsPerProjectRoot = new Map();
|
|
154720
|
-
this.projectToSizeMap = new Map();
|
|
154721
|
-
this.configFileExistenceInfoCache = new Map();
|
|
154681
|
+
this.openFiles = /* @__PURE__ */ new Map();
|
|
154682
|
+
this.configFileForOpenFiles = /* @__PURE__ */ new Map();
|
|
154683
|
+
this.openFilesWithNonRootedDiskPath = /* @__PURE__ */ new Map();
|
|
154684
|
+
this.compilerOptionsForInferredProjectsPerProjectRoot = /* @__PURE__ */ new Map();
|
|
154685
|
+
this.watchOptionsForInferredProjectsPerProjectRoot = /* @__PURE__ */ new Map();
|
|
154686
|
+
this.typeAcquisitionForInferredProjectsPerProjectRoot = /* @__PURE__ */ new Map();
|
|
154687
|
+
this.projectToSizeMap = /* @__PURE__ */ new Map();
|
|
154688
|
+
this.configFileExistenceInfoCache = /* @__PURE__ */ new Map();
|
|
154722
154689
|
this.safelist = defaultTypeSafeList;
|
|
154723
|
-
this.legacySafelist = new Map();
|
|
154724
|
-
this.pendingProjectUpdates = new Map();
|
|
154690
|
+
this.legacySafelist = /* @__PURE__ */ new Map();
|
|
154691
|
+
this.pendingProjectUpdates = /* @__PURE__ */ new Map();
|
|
154725
154692
|
this.pendingEnsureProjectForOpenFiles = false;
|
|
154726
|
-
this.seenProjects = new Map();
|
|
154727
|
-
this.sharedExtendedConfigFileWatchers = new Map();
|
|
154728
|
-
this.extendedConfigCache = new Map();
|
|
154693
|
+
this.seenProjects = /* @__PURE__ */ new Map();
|
|
154694
|
+
this.sharedExtendedConfigFileWatchers = /* @__PURE__ */ new Map();
|
|
154695
|
+
this.extendedConfigCache = /* @__PURE__ */ new Map();
|
|
154729
154696
|
this.host = opts.host;
|
|
154730
154697
|
this.logger = opts.logger;
|
|
154731
154698
|
this.cancellationToken = opts.cancellationToken;
|
|
@@ -155325,14 +155292,14 @@ ${options.prefix}` : "\n" : options.prefix
|
|
|
155325
155292
|
let configFileExistenceInfo = this.configFileExistenceInfoCache.get(canonicalConfigFilePath);
|
|
155326
155293
|
if (configFileExistenceInfo) {
|
|
155327
155294
|
if (isOpenScriptInfo(info) && !((_a2 = configFileExistenceInfo.openFilesImpactedByConfigFile) == null ? void 0 : _a2.has(info.path))) {
|
|
155328
|
-
(configFileExistenceInfo.openFilesImpactedByConfigFile || (configFileExistenceInfo.openFilesImpactedByConfigFile = new Map())).set(info.path, false);
|
|
155295
|
+
(configFileExistenceInfo.openFilesImpactedByConfigFile || (configFileExistenceInfo.openFilesImpactedByConfigFile = /* @__PURE__ */ new Map())).set(info.path, false);
|
|
155329
155296
|
}
|
|
155330
155297
|
return configFileExistenceInfo.exists;
|
|
155331
155298
|
}
|
|
155332
155299
|
const exists = this.host.fileExists(configFileName);
|
|
155333
155300
|
let openFilesImpactedByConfigFile;
|
|
155334
155301
|
if (isOpenScriptInfo(info)) {
|
|
155335
|
-
(openFilesImpactedByConfigFile || (openFilesImpactedByConfigFile = new Map())).set(info.path, false);
|
|
155302
|
+
(openFilesImpactedByConfigFile || (openFilesImpactedByConfigFile = /* @__PURE__ */ new Map())).set(info.path, false);
|
|
155336
155303
|
}
|
|
155337
155304
|
configFileExistenceInfo = { exists, openFilesImpactedByConfigFile };
|
|
155338
155305
|
this.configFileExistenceInfoCache.set(canonicalConfigFilePath, configFileExistenceInfo);
|
|
@@ -155414,7 +155381,7 @@ ${options.prefix}` : "\n" : options.prefix
|
|
|
155414
155381
|
configFileExistenceInfo = { exists: this.host.fileExists(configFileName) };
|
|
155415
155382
|
this.configFileExistenceInfoCache.set(canonicalConfigFilePath, configFileExistenceInfo);
|
|
155416
155383
|
}
|
|
155417
|
-
(configFileExistenceInfo.openFilesImpactedByConfigFile || (configFileExistenceInfo.openFilesImpactedByConfigFile = new Map())).set(info.path, true);
|
|
155384
|
+
(configFileExistenceInfo.openFilesImpactedByConfigFile || (configFileExistenceInfo.openFilesImpactedByConfigFile = /* @__PURE__ */ new Map())).set(info.path, true);
|
|
155418
155385
|
configFileExistenceInfo.watcher || (configFileExistenceInfo.watcher = canWatchDirectoryOrFile(getDirectoryPath(canonicalConfigFilePath)) ? this.watchFactory.watchFile(
|
|
155419
155386
|
configFileName,
|
|
155420
155387
|
(_filename, eventKind) => this.onConfigFileChanged(canonicalConfigFilePath, eventKind),
|
|
@@ -155625,7 +155592,7 @@ ${options.prefix}` : "\n" : options.prefix
|
|
|
155625
155592
|
if (!configFileExistenceInfo.config) {
|
|
155626
155593
|
configFileExistenceInfo.config = {
|
|
155627
155594
|
cachedDirectoryStructureHost: createCachedDirectoryStructureHost(this.host, this.host.getCurrentDirectory(), this.host.useCaseSensitiveFileNames),
|
|
155628
|
-
projects: new Map(),
|
|
155595
|
+
projects: /* @__PURE__ */ new Map(),
|
|
155629
155596
|
reloadLevel: 2 /* Full */
|
|
155630
155597
|
};
|
|
155631
155598
|
}
|
|
@@ -155733,7 +155700,7 @@ ${options.prefix}` : "\n" : options.prefix
|
|
|
155733
155700
|
}, void 0, " ")}`);
|
|
155734
155701
|
const oldCommandLine = (_b = configFileExistenceInfo.config) == null ? void 0 : _b.parsedCommandLine;
|
|
155735
155702
|
if (!configFileExistenceInfo.config) {
|
|
155736
|
-
configFileExistenceInfo.config = { parsedCommandLine, cachedDirectoryStructureHost, projects: new Map() };
|
|
155703
|
+
configFileExistenceInfo.config = { parsedCommandLine, cachedDirectoryStructureHost, projects: /* @__PURE__ */ new Map() };
|
|
155737
155704
|
} else {
|
|
155738
155705
|
configFileExistenceInfo.config.parsedCommandLine = parsedCommandLine;
|
|
155739
155706
|
configFileExistenceInfo.config.watchedDirectoriesStale = true;
|
|
@@ -155779,7 +155746,7 @@ ${options.prefix}` : "\n" : options.prefix
|
|
|
155779
155746
|
return;
|
|
155780
155747
|
config.watchedDirectoriesStale = false;
|
|
155781
155748
|
updateWatchingWildcardDirectories(
|
|
155782
|
-
config.watchedDirectories || (config.watchedDirectories = new Map()),
|
|
155749
|
+
config.watchedDirectories || (config.watchedDirectories = /* @__PURE__ */ new Map()),
|
|
155783
155750
|
new Map(getEntries(config.parsedCommandLine.wildcardDirectories)),
|
|
155784
155751
|
(directory, flags) => this.watchWildcardDirectory(directory, flags, configFileName, config)
|
|
155785
155752
|
);
|
|
@@ -155807,7 +155774,7 @@ ${options.prefix}` : "\n" : options.prefix
|
|
|
155807
155774
|
}
|
|
155808
155775
|
updateNonInferredProjectFiles(project, files, propertyReader) {
|
|
155809
155776
|
const projectRootFilesMap = project.getRootFilesMap();
|
|
155810
|
-
const newRootScriptInfoMap = new Map();
|
|
155777
|
+
const newRootScriptInfoMap = /* @__PURE__ */ new Map();
|
|
155811
155778
|
for (const f of files) {
|
|
155812
155779
|
const newRootFile = propertyReader.getFileName(f);
|
|
155813
155780
|
const fileName = toNormalizedPath(newRootFile);
|
|
@@ -156106,7 +156073,7 @@ All files are: ${JSON.stringify(names)}`, "Err" /* Err */);
|
|
|
156106
156073
|
}
|
|
156107
156074
|
watchPackageJsonsInNodeModules(dir, project) {
|
|
156108
156075
|
const watcher = this.nodeModulesWatchers.get(dir) || this.createNodeModulesWatcher(dir);
|
|
156109
|
-
(watcher.affectedModuleSpecifierCacheProjects || (watcher.affectedModuleSpecifierCacheProjects = new Set())).add(project.getProjectName());
|
|
156076
|
+
(watcher.affectedModuleSpecifierCacheProjects || (watcher.affectedModuleSpecifierCacheProjects = /* @__PURE__ */ new Set())).add(project.getProjectName());
|
|
156110
156077
|
return {
|
|
156111
156078
|
close: () => {
|
|
156112
156079
|
var _a2;
|
|
@@ -156274,7 +156241,7 @@ Dynamic files must always be opened with service's current directory or service
|
|
|
156274
156241
|
addSourceInfoToSourceMap(sourceFileName, project, sourceInfos) {
|
|
156275
156242
|
if (sourceFileName) {
|
|
156276
156243
|
const sourceInfo = this.getOrCreateScriptInfoNotOpenedByClient(sourceFileName, project.currentDirectory, project.directoryStructureHost);
|
|
156277
|
-
(sourceInfos || (sourceInfos = new Set())).add(sourceInfo.path);
|
|
156244
|
+
(sourceInfos || (sourceInfos = /* @__PURE__ */ new Set())).add(sourceInfo.path);
|
|
156278
156245
|
}
|
|
156279
156246
|
return sourceInfos;
|
|
156280
156247
|
}
|
|
@@ -156309,7 +156276,7 @@ Dynamic files must always be opened with service's current directory or service
|
|
|
156309
156276
|
if (declarationInfo && isString(declarationInfo.sourceMapFilePath) && info !== declarationInfo) {
|
|
156310
156277
|
const sourceMapInfo = this.getScriptInfoForPath(declarationInfo.sourceMapFilePath);
|
|
156311
156278
|
if (sourceMapInfo) {
|
|
156312
|
-
(sourceMapInfo.sourceInfos || (sourceMapInfo.sourceInfos = new Set())).add(info.path);
|
|
156279
|
+
(sourceMapInfo.sourceInfos || (sourceMapInfo.sourceInfos = /* @__PURE__ */ new Set())).add(info.path);
|
|
156313
156280
|
}
|
|
156314
156281
|
}
|
|
156315
156282
|
if (info.cacheSourceFile)
|
|
@@ -156414,7 +156381,7 @@ Dynamic files must always be opened with service's current directory or service
|
|
|
156414
156381
|
this.ensureProjectForOpenFiles();
|
|
156415
156382
|
}
|
|
156416
156383
|
reloadConfiguredProjectForFiles(openFiles, clearSemanticCache, delayReload, shouldReloadProjectFor, reason) {
|
|
156417
|
-
const updatedProjects = new Map();
|
|
156384
|
+
const updatedProjects = /* @__PURE__ */ new Map();
|
|
156418
156385
|
const reloadChildProject = (child) => {
|
|
156419
156386
|
if (!updatedProjects.has(child.canonicalConfigFilePath)) {
|
|
156420
156387
|
updatedProjects.set(child.canonicalConfigFilePath, true);
|
|
@@ -156547,7 +156514,7 @@ Dynamic files must always be opened with service's current directory or service
|
|
|
156547
156514
|
return originalLocation;
|
|
156548
156515
|
function addOriginalConfiguredProject(originalProject) {
|
|
156549
156516
|
if (!project.originalConfiguredProjects) {
|
|
156550
|
-
project.originalConfiguredProjects = new Set();
|
|
156517
|
+
project.originalConfiguredProjects = /* @__PURE__ */ new Set();
|
|
156551
156518
|
}
|
|
156552
156519
|
project.originalConfiguredProjects.add(originalProject.canonicalConfigFilePath);
|
|
156553
156520
|
}
|
|
@@ -156658,7 +156625,7 @@ Dynamic files must always be opened with service's current directory or service
|
|
|
156658
156625
|
this.configuredProjects,
|
|
156659
156626
|
(key, project) => !project.isInitialLoadPending() ? [key, true] : void 0
|
|
156660
156627
|
);
|
|
156661
|
-
const seenProjects = new Set();
|
|
156628
|
+
const seenProjects = /* @__PURE__ */ new Set();
|
|
156662
156629
|
for (const project of arrayFrom(this.configuredProjects.values())) {
|
|
156663
156630
|
if (forEachPotentialProjectReference(project, (potentialRefPath) => forProjects.has(potentialRefPath))) {
|
|
156664
156631
|
updateProjectIfDirty(project);
|
|
@@ -157120,7 +157087,7 @@ Dynamic files must always be opened with service's current directory or service
|
|
|
157120
157087
|
}
|
|
157121
157088
|
if (this.host.importPlugin) {
|
|
157122
157089
|
const importPromise = project.beginEnablePluginAsync(pluginConfigEntry, searchPaths, pluginConfigOverrides);
|
|
157123
|
-
(_a2 = this.pendingPluginEnablements) != null ? _a2 : this.pendingPluginEnablements = new Map();
|
|
157090
|
+
(_a2 = this.pendingPluginEnablements) != null ? _a2 : this.pendingPluginEnablements = /* @__PURE__ */ new Map();
|
|
157124
157091
|
let promises = this.pendingPluginEnablements.get(project);
|
|
157125
157092
|
if (!promises)
|
|
157126
157093
|
this.pendingPluginEnablements.set(project, promises = []);
|
|
@@ -157175,7 +157142,7 @@ Dynamic files must always be opened with service's current directory or service
|
|
|
157175
157142
|
}
|
|
157176
157143
|
configurePlugin(args) {
|
|
157177
157144
|
this.forEachEnabledProject((project) => project.onPluginConfigurationChanged(args.pluginName, args.configuration));
|
|
157178
|
-
this.currentPluginConfigOverrides = this.currentPluginConfigOverrides || new Map();
|
|
157145
|
+
this.currentPluginConfigOverrides = this.currentPluginConfigOverrides || /* @__PURE__ */ new Map();
|
|
157179
157146
|
this.currentPluginConfigOverrides.set(args.pluginName, args.configuration);
|
|
157180
157147
|
}
|
|
157181
157148
|
getPackageJsonsVisibleToFile(fileName, rootDir) {
|
|
@@ -157215,7 +157182,7 @@ Dynamic files must always be opened with service's current directory or service
|
|
|
157215
157182
|
});
|
|
157216
157183
|
}
|
|
157217
157184
|
watchPackageJsonFile(path) {
|
|
157218
|
-
const watchers = this.packageJsonFilesMap || (this.packageJsonFilesMap = new Map());
|
|
157185
|
+
const watchers = this.packageJsonFilesMap || (this.packageJsonFilesMap = /* @__PURE__ */ new Map());
|
|
157219
157186
|
if (!watchers.has(path)) {
|
|
157220
157187
|
this.invalidateProjectPackageJson(path);
|
|
157221
157188
|
watchers.set(path, this.watchFactory.watchFile(
|
|
@@ -157313,7 +157280,7 @@ Dynamic files must always be opened with service's current directory or service
|
|
|
157313
157280
|
if (p.isInNodeModules) {
|
|
157314
157281
|
const nodeModulesPath = p.path.substring(0, p.path.indexOf(nodeModulesPathPart) + nodeModulesPathPart.length - 1);
|
|
157315
157282
|
if (!(containedNodeModulesWatchers == null ? void 0 : containedNodeModulesWatchers.has(nodeModulesPath))) {
|
|
157316
|
-
(containedNodeModulesWatchers || (containedNodeModulesWatchers = new Map())).set(
|
|
157283
|
+
(containedNodeModulesWatchers || (containedNodeModulesWatchers = /* @__PURE__ */ new Map())).set(
|
|
157317
157284
|
nodeModulesPath,
|
|
157318
157285
|
host.watchNodeModulesForPackageJsonChanges(nodeModulesPath)
|
|
157319
157286
|
);
|
|
@@ -157360,7 +157327,7 @@ Dynamic files must always be opened with service's current directory or service
|
|
|
157360
157327
|
result.clear();
|
|
157361
157328
|
}
|
|
157362
157329
|
currentKey = newKey;
|
|
157363
|
-
return cache || (cache = new Map());
|
|
157330
|
+
return cache || (cache = /* @__PURE__ */ new Map());
|
|
157364
157331
|
}
|
|
157365
157332
|
function key(fromFileName, preferences, options) {
|
|
157366
157333
|
return `${fromFileName},${preferences.importModuleSpecifierEnding},${preferences.importModuleSpecifierPreference},${options.overrideImportMode}`;
|
|
@@ -157372,8 +157339,8 @@ Dynamic files must always be opened with service's current directory or service
|
|
|
157372
157339
|
|
|
157373
157340
|
// src/server/packageJsonCache.ts
|
|
157374
157341
|
function createPackageJsonCache(host) {
|
|
157375
|
-
const packageJsons = new Map();
|
|
157376
|
-
const directoriesWithoutPackageJson = new Map();
|
|
157342
|
+
const packageJsons = /* @__PURE__ */ new Map();
|
|
157343
|
+
const directoriesWithoutPackageJson = /* @__PURE__ */ new Map();
|
|
157377
157344
|
return {
|
|
157378
157345
|
addOrUpdate,
|
|
157379
157346
|
forEach: packageJsons.forEach.bind(packageJsons),
|
|
@@ -157666,7 +157633,7 @@ ${json}${newLine}`;
|
|
|
157666
157633
|
}
|
|
157667
157634
|
}
|
|
157668
157635
|
}
|
|
157669
|
-
const updatedProjects = new Set();
|
|
157636
|
+
const updatedProjects = /* @__PURE__ */ new Set();
|
|
157670
157637
|
while (true) {
|
|
157671
157638
|
let progress = false;
|
|
157672
157639
|
perProjectResults.forEach((referencedSymbols, project) => {
|
|
@@ -157730,7 +157697,7 @@ ${json}${newLine}`;
|
|
|
157730
157697
|
}
|
|
157731
157698
|
}
|
|
157732
157699
|
function getPerProjectReferences(projects, defaultProject, initialLocation, isForRename, getResultsForPosition, forPositionInResult) {
|
|
157733
|
-
const resultsMap = new Map();
|
|
157700
|
+
const resultsMap = /* @__PURE__ */ new Map();
|
|
157734
157701
|
const queue = createQueue();
|
|
157735
157702
|
queue.enqueue({ project: defaultProject, location: initialLocation });
|
|
157736
157703
|
forEachProjectInProjects(projects, initialLocation.fileName, (project, path) => {
|
|
@@ -157742,7 +157709,7 @@ ${json}${newLine}`;
|
|
|
157742
157709
|
const defaultDefinition = getDefinitionLocation(defaultProject, initialLocation, isForRename);
|
|
157743
157710
|
const getGeneratedDefinition = memoize(() => defaultProject.isSourceOfProjectReferenceRedirect(defaultDefinition.fileName) ? defaultDefinition : defaultProject.getLanguageService().getSourceMapper().tryGetGeneratedPosition(defaultDefinition));
|
|
157744
157711
|
const getSourceDefinition = memoize(() => defaultProject.isSourceOfProjectReferenceRedirect(defaultDefinition.fileName) ? defaultDefinition : defaultProject.getLanguageService().getSourceMapper().tryGetSourcePosition(defaultDefinition));
|
|
157745
|
-
const searchedProjectKeys = new Set();
|
|
157712
|
+
const searchedProjectKeys = /* @__PURE__ */ new Set();
|
|
157746
157713
|
onCancellation:
|
|
157747
157714
|
while (!queue.isEmpty()) {
|
|
157748
157715
|
while (!queue.isEmpty()) {
|
|
@@ -159163,7 +159130,7 @@ Project '${project.projectName}' (${ProjectKind[project.projectKind]}) ${counter
|
|
|
159163
159130
|
}
|
|
159164
159131
|
}
|
|
159165
159132
|
toSpanGroups(locations) {
|
|
159166
|
-
const map2 = new Map();
|
|
159133
|
+
const map2 = /* @__PURE__ */ new Map();
|
|
159167
159134
|
for (const { fileName, textSpan, contextSpan, originalContextSpan: _2, originalTextSpan: _, originalFileName: _1, ...prefixSuffixText } of locations) {
|
|
159168
159135
|
let group2 = map2.get(fileName);
|
|
159169
159136
|
if (!group2)
|
|
@@ -159673,7 +159640,7 @@ Project '${project.projectName}' (${ProjectKind[project.projectKind]}) ${counter
|
|
|
159673
159640
|
return [{ project, navigateToItems: project.getLanguageService().getNavigateToItems(searchValue, maxResultCount, file) }];
|
|
159674
159641
|
}
|
|
159675
159642
|
const outputs = [];
|
|
159676
|
-
const seenItems = new Map();
|
|
159643
|
+
const seenItems = /* @__PURE__ */ new Map();
|
|
159677
159644
|
if (!args.file && !projectFileName) {
|
|
159678
159645
|
this.projectService.loadAncestorProjectTree();
|
|
159679
159646
|
this.projectService.forEachEnabledProject((project) => addItemsForProject(project));
|
|
@@ -159794,7 +159761,7 @@ Project '${project.projectName}' (${ProjectKind[project.projectKind]}) ${counter
|
|
|
159794
159761
|
const newPath = toNormalizedPath(args.newFilePath);
|
|
159795
159762
|
const formatOptions = this.getHostFormatOptions();
|
|
159796
159763
|
const preferences = this.getHostPreferences();
|
|
159797
|
-
const seenFiles = new Set();
|
|
159764
|
+
const seenFiles = /* @__PURE__ */ new Set();
|
|
159798
159765
|
const textChanges2 = [];
|
|
159799
159766
|
this.projectService.loadAncestorProjectTree();
|
|
159800
159767
|
this.projectService.forEachEnabledProject((project) => {
|
|
@@ -161249,7 +161216,7 @@ ${e.message}`;
|
|
|
161249
161216
|
let canWrite = true;
|
|
161250
161217
|
if (useWatchGuard) {
|
|
161251
161218
|
const currentDrive = extractWatchDirectoryCacheKey(sys2.resolvePath(sys2.getCurrentDirectory()), void 0);
|
|
161252
|
-
const statusCache = new Map();
|
|
161219
|
+
const statusCache = /* @__PURE__ */ new Map();
|
|
161253
161220
|
sys2.watchDirectory = (path, callback, recursive, options) => {
|
|
161254
161221
|
const cacheKey = extractWatchDirectoryCacheKey(path, currentDrive);
|
|
161255
161222
|
let status = cacheKey && statusCache.get(cacheKey);
|
|
@@ -161414,7 +161381,7 @@ ${e.message}`;
|
|
|
161414
161381
|
this.event = event;
|
|
161415
161382
|
this.activeRequestCount = 0;
|
|
161416
161383
|
this.requestQueue = createQueue();
|
|
161417
|
-
this.requestMap = new Map();
|
|
161384
|
+
this.requestMap = /* @__PURE__ */ new Map();
|
|
161418
161385
|
this.requestedRegistry = false;
|
|
161419
161386
|
}
|
|
161420
161387
|
isKnownTypesPackageName(name) {
|