@typescript-deploys/pr-build 5.4.0-pr-48838-21 → 5.4.0-pr-57029-10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/lib.esnext.collection.d.ts +29 -0
- package/lib/lib.esnext.d.ts +2 -0
- package/lib/lib.esnext.object.d.ts +29 -0
- package/lib/tsc.js +235 -77
- package/lib/tsserver.js +321 -86
- package/lib/typescript.d.ts +7 -2
- package/lib/typescript.js +321 -86
- package/lib/typingsInstaller.js +64 -14
- package/package.json +2 -2
package/lib/typingsInstaller.js
CHANGED
|
@@ -54,7 +54,7 @@ var path = __toESM(require("path"));
|
|
|
54
54
|
|
|
55
55
|
// src/compiler/corePublic.ts
|
|
56
56
|
var versionMajorMinor = "5.4";
|
|
57
|
-
var version = `${versionMajorMinor}.0-insiders.
|
|
57
|
+
var version = `${versionMajorMinor}.0-insiders.20240112`;
|
|
58
58
|
|
|
59
59
|
// src/compiler/core.ts
|
|
60
60
|
var emptyArray = [];
|
|
@@ -4311,6 +4311,7 @@ var sys = (() => {
|
|
|
4311
4311
|
resolvePath: (path2) => _path.resolve(path2),
|
|
4312
4312
|
fileExists,
|
|
4313
4313
|
directoryExists,
|
|
4314
|
+
getAccessibleFileSystemEntries,
|
|
4314
4315
|
createDirectory(directoryName) {
|
|
4315
4316
|
if (!nodeSystem.directoryExists(directoryName)) {
|
|
4316
4317
|
try {
|
|
@@ -6518,6 +6519,10 @@ var Diagnostics = {
|
|
|
6518
6519
|
Export_specifier_0_does_not_exist_in_package_json_scope_at_path_1: diag(6276, 3 /* Message */, "Export_specifier_0_does_not_exist_in_package_json_scope_at_path_1_6276", "Export specifier '{0}' does not exist in package.json scope at path '{1}'."),
|
|
6519
6520
|
Resolution_of_non_relative_name_failed_trying_with_modern_Node_resolution_features_disabled_to_see_if_npm_library_needs_configuration_update: diag(6277, 3 /* Message */, "Resolution_of_non_relative_name_failed_trying_with_modern_Node_resolution_features_disabled_to_see_i_6277", "Resolution of non-relative name failed; trying with modern Node resolution features disabled to see if npm library needs configuration update."),
|
|
6520
6521
|
There_are_types_at_0_but_this_result_could_not_be_resolved_when_respecting_package_json_exports_The_1_library_may_need_to_update_its_package_json_or_typings: diag(6278, 3 /* Message */, "There_are_types_at_0_but_this_result_could_not_be_resolved_when_respecting_package_json_exports_The__6278", `There are types at '{0}', but this result could not be resolved when respecting package.json "exports". The '{1}' library may need to update its package.json or typings.`),
|
|
6522
|
+
package_json_has_a_peerDependencies_field: diag(6279, 3 /* Message */, "package_json_has_a_peerDependencies_field_6279", "'package.json' has a 'peerDependencies' field."),
|
|
6523
|
+
Package_is_not_installed_using_pnpm_skipping_peerDependencies_version_resolution: diag(6280, 3 /* Message */, "Package_is_not_installed_using_pnpm_skipping_peerDependencies_version_resolution_6280", "Package is not installed using pnpm, skipping peerDependencies version resolution."),
|
|
6524
|
+
Found_peerDependency_0_with_1_version: diag(6281, 3 /* Message */, "Found_peerDependency_0_with_1_version_6281", "Found peerDependency '{0}' with '{1}' version."),
|
|
6525
|
+
Failed_to_find_peerDependency_0: diag(6282, 3 /* Message */, "Failed_to_find_peerDependency_0_6282", "Failed to find peerDependency '{0}'."),
|
|
6521
6526
|
Enable_project_compilation: diag(6302, 3 /* Message */, "Enable_project_compilation_6302", "Enable project compilation"),
|
|
6522
6527
|
Composite_projects_may_not_disable_declaration_emit: diag(6304, 1 /* Error */, "Composite_projects_may_not_disable_declaration_emit_6304", "Composite projects may not disable declaration emit."),
|
|
6523
6528
|
Output_file_0_has_not_been_built_from_source_file_1: diag(6305, 1 /* Error */, "Output_file_0_has_not_been_built_from_source_file_1_6305", "Output file '{0}' has not been built from source file '{1}'."),
|
|
@@ -10092,7 +10097,7 @@ function packageIdToPackageName({ name, subModuleName }) {
|
|
|
10092
10097
|
return subModuleName ? `${name}/${subModuleName}` : name;
|
|
10093
10098
|
}
|
|
10094
10099
|
function packageIdToString(packageId) {
|
|
10095
|
-
return `${packageIdToPackageName(packageId)}@${packageId.version}`;
|
|
10100
|
+
return `${packageIdToPackageName(packageId)}@${packageId.version}${packageId.peerDependencies ?? ""}`;
|
|
10096
10101
|
}
|
|
10097
10102
|
function containsParseError(node) {
|
|
10098
10103
|
aggregateChildData(node);
|
|
@@ -25933,7 +25938,7 @@ var libEntries = [
|
|
|
25933
25938
|
["es2023.array", "lib.es2023.array.d.ts"],
|
|
25934
25939
|
["es2023.collection", "lib.es2023.collection.d.ts"],
|
|
25935
25940
|
["esnext.array", "lib.es2023.array.d.ts"],
|
|
25936
|
-
["esnext.collection", "lib.
|
|
25941
|
+
["esnext.collection", "lib.esnext.collection.d.ts"],
|
|
25937
25942
|
["esnext.symbol", "lib.es2019.symbol.d.ts"],
|
|
25938
25943
|
["esnext.asynciterable", "lib.es2018.asynciterable.d.ts"],
|
|
25939
25944
|
["esnext.intl", "lib.esnext.intl.d.ts"],
|
|
@@ -25943,6 +25948,7 @@ var libEntries = [
|
|
|
25943
25948
|
["esnext.promise", "lib.esnext.promise.d.ts"],
|
|
25944
25949
|
["esnext.weakref", "lib.es2021.weakref.d.ts"],
|
|
25945
25950
|
["esnext.decorators", "lib.esnext.decorators.d.ts"],
|
|
25951
|
+
["esnext.object", "lib.esnext.object.d.ts"],
|
|
25946
25952
|
["decorators", "lib.decorators.d.ts"],
|
|
25947
25953
|
["decorators.legacy", "lib.decorators.legacy.d.ts"]
|
|
25948
25954
|
];
|
|
@@ -27614,7 +27620,7 @@ function trace(host, message, ...args) {
|
|
|
27614
27620
|
function isTraceEnabled(compilerOptions, host) {
|
|
27615
27621
|
return !!compilerOptions.traceResolution && host.trace !== void 0;
|
|
27616
27622
|
}
|
|
27617
|
-
function withPackageId(packageInfo, r) {
|
|
27623
|
+
function withPackageId(packageInfo, r, state) {
|
|
27618
27624
|
let packageId;
|
|
27619
27625
|
if (r && packageInfo) {
|
|
27620
27626
|
const packageJsonContent = packageInfo.contents.packageJsonContent;
|
|
@@ -27622,7 +27628,8 @@ function withPackageId(packageInfo, r) {
|
|
|
27622
27628
|
packageId = {
|
|
27623
27629
|
name: packageJsonContent.name,
|
|
27624
27630
|
subModuleName: r.path.slice(packageInfo.packageDirectory.length + directorySeparator.length),
|
|
27625
|
-
version: packageJsonContent.version
|
|
27631
|
+
version: packageJsonContent.version,
|
|
27632
|
+
peerDependencies: getPeerDependenciesOfPackageJsonInfo(packageInfo, state)
|
|
27626
27633
|
};
|
|
27627
27634
|
}
|
|
27628
27635
|
}
|
|
@@ -27632,7 +27639,9 @@ function noPackageId(r) {
|
|
|
27632
27639
|
return withPackageId(
|
|
27633
27640
|
/*packageInfo*/
|
|
27634
27641
|
void 0,
|
|
27635
|
-
r
|
|
27642
|
+
r,
|
|
27643
|
+
/*state*/
|
|
27644
|
+
void 0
|
|
27636
27645
|
);
|
|
27637
27646
|
}
|
|
27638
27647
|
function removeIgnoredPackageId(r) {
|
|
@@ -28326,7 +28335,7 @@ function nodeLoadModuleByRelativeName(extensions, candidate, onlyRecordFailures,
|
|
|
28326
28335
|
false,
|
|
28327
28336
|
state
|
|
28328
28337
|
) : void 0;
|
|
28329
|
-
return withPackageId(packageInfo, resolvedFromFile);
|
|
28338
|
+
return withPackageId(packageInfo, resolvedFromFile, state);
|
|
28330
28339
|
}
|
|
28331
28340
|
}
|
|
28332
28341
|
if (!onlyRecordFailures) {
|
|
@@ -28469,7 +28478,7 @@ function loadNodeModuleFromDirectory(extensions, candidate, onlyRecordFailures,
|
|
|
28469
28478
|
const packageInfo = considerPackageJson ? getPackageJsonInfo(candidate, onlyRecordFailures, state) : void 0;
|
|
28470
28479
|
const packageJsonContent = packageInfo && packageInfo.contents.packageJsonContent;
|
|
28471
28480
|
const versionPaths = packageInfo && getVersionPathsOfPackageJsonInfo(packageInfo, state);
|
|
28472
|
-
return withPackageId(packageInfo, loadNodeModuleFromDirectoryWorker(extensions, candidate, onlyRecordFailures, state, packageJsonContent, versionPaths));
|
|
28481
|
+
return withPackageId(packageInfo, loadNodeModuleFromDirectoryWorker(extensions, candidate, onlyRecordFailures, state, packageJsonContent, versionPaths), state);
|
|
28473
28482
|
}
|
|
28474
28483
|
function getPackageScopeForPath(fileName, state) {
|
|
28475
28484
|
const parts = getPathComponents(fileName);
|
|
@@ -28494,6 +28503,47 @@ function getVersionPathsOfPackageJsonInfo(packageJsonInfo, state) {
|
|
|
28494
28503
|
}
|
|
28495
28504
|
return packageJsonInfo.contents.versionPaths || void 0;
|
|
28496
28505
|
}
|
|
28506
|
+
function getPeerDependenciesOfPackageJsonInfo(packageJsonInfo, state) {
|
|
28507
|
+
if (packageJsonInfo.contents.peerDependencies === void 0) {
|
|
28508
|
+
packageJsonInfo.contents.peerDependencies = readPackageJsonPeerDependencies(packageJsonInfo, state) || false;
|
|
28509
|
+
}
|
|
28510
|
+
return packageJsonInfo.contents.peerDependencies || void 0;
|
|
28511
|
+
}
|
|
28512
|
+
function readPackageJsonPeerDependencies(packageJsonInfo, state) {
|
|
28513
|
+
const peerDependencies = readPackageJsonField(packageJsonInfo.contents.packageJsonContent, "peerDependencies", "object", state);
|
|
28514
|
+
if (peerDependencies === void 0)
|
|
28515
|
+
return void 0;
|
|
28516
|
+
if (state.traceEnabled)
|
|
28517
|
+
trace(state.host, Diagnostics.package_json_has_a_peerDependencies_field);
|
|
28518
|
+
const packageDirectory = realPath(packageJsonInfo.packageDirectory, state.host, state.traceEnabled);
|
|
28519
|
+
if (packageDirectory.indexOf(".pnpm") === -1) {
|
|
28520
|
+
if (state.traceEnabled)
|
|
28521
|
+
trace(state.host, Diagnostics.Package_is_not_installed_using_pnpm_skipping_peerDependencies_version_resolution);
|
|
28522
|
+
return void 0;
|
|
28523
|
+
}
|
|
28524
|
+
const nodeModules = packageDirectory.substring(0, packageDirectory.lastIndexOf("node_modules") + "node_modules".length) + directorySeparator;
|
|
28525
|
+
let result = "";
|
|
28526
|
+
for (const key in peerDependencies) {
|
|
28527
|
+
if (hasProperty(peerDependencies, key)) {
|
|
28528
|
+
const peerPackageJson = getPackageJsonInfo(
|
|
28529
|
+
nodeModules + key,
|
|
28530
|
+
/*onlyRecordFailures*/
|
|
28531
|
+
false,
|
|
28532
|
+
state
|
|
28533
|
+
);
|
|
28534
|
+
if (peerPackageJson) {
|
|
28535
|
+
const version2 = peerPackageJson.contents.packageJsonContent.version;
|
|
28536
|
+
result += `+${key}@${version2}`;
|
|
28537
|
+
if (state.traceEnabled)
|
|
28538
|
+
trace(state.host, Diagnostics.Found_peerDependency_0_with_1_version, key, version2);
|
|
28539
|
+
} else {
|
|
28540
|
+
if (state.traceEnabled)
|
|
28541
|
+
trace(state.host, Diagnostics.Failed_to_find_peerDependency_0, key);
|
|
28542
|
+
}
|
|
28543
|
+
}
|
|
28544
|
+
}
|
|
28545
|
+
return result;
|
|
28546
|
+
}
|
|
28497
28547
|
function getPackageJsonInfo(packageDirectory, onlyRecordFailures, state) {
|
|
28498
28548
|
var _a, _b, _c, _d, _e, _f;
|
|
28499
28549
|
const { host, traceEnabled } = state;
|
|
@@ -28522,7 +28572,7 @@ function getPackageJsonInfo(packageDirectory, onlyRecordFailures, state) {
|
|
|
28522
28572
|
if (traceEnabled) {
|
|
28523
28573
|
trace(host, Diagnostics.Found_package_json_at_0, packageJsonPath);
|
|
28524
28574
|
}
|
|
28525
|
-
const result = { packageDirectory, contents: { packageJsonContent, versionPaths: void 0, resolvedEntrypoints: void 0 } };
|
|
28575
|
+
const result = { packageDirectory, contents: { packageJsonContent, versionPaths: void 0, resolvedEntrypoints: void 0, peerDependencies: void 0 } };
|
|
28526
28576
|
if (state.packageJsonInfoCache && !state.packageJsonInfoCache.isReadonly)
|
|
28527
28577
|
state.packageJsonInfoCache.setPackageJsonInfo(packageJsonPath, result);
|
|
28528
28578
|
(_e = state.affectingLocations) == null ? void 0 : _e.push(packageJsonPath);
|
|
@@ -28930,7 +28980,7 @@ function getLoadModuleFromTargetImportOrExport(extensions, state, cache, redirec
|
|
|
28930
28980
|
/*onlyRecordFailures*/
|
|
28931
28981
|
false,
|
|
28932
28982
|
state
|
|
28933
|
-
)));
|
|
28983
|
+
), state));
|
|
28934
28984
|
} else if (typeof target === "object" && target !== null) {
|
|
28935
28985
|
if (!Array.isArray(target)) {
|
|
28936
28986
|
traceIfEnabled(state, Diagnostics.Entering_conditional_exports);
|
|
@@ -29044,7 +29094,7 @@ function getLoadModuleFromTargetImportOrExport(extensions, state, cache, redirec
|
|
|
29044
29094
|
/*onlyRecordFailures*/
|
|
29045
29095
|
false,
|
|
29046
29096
|
state
|
|
29047
|
-
)));
|
|
29097
|
+
), state));
|
|
29048
29098
|
}
|
|
29049
29099
|
}
|
|
29050
29100
|
}
|
|
@@ -29175,7 +29225,7 @@ function loadModuleFromSpecificNodeModulesDirectory(extensions, moduleName, node
|
|
|
29175
29225
|
packageInfo.contents.packageJsonContent,
|
|
29176
29226
|
getVersionPathsOfPackageJsonInfo(packageInfo, state)
|
|
29177
29227
|
);
|
|
29178
|
-
return withPackageId(packageInfo, fromDirectory);
|
|
29228
|
+
return withPackageId(packageInfo, fromDirectory, state);
|
|
29179
29229
|
}
|
|
29180
29230
|
const loader = (extensions2, candidate2, onlyRecordFailures, state2) => {
|
|
29181
29231
|
let pathAndExtension = (rest || !(state2.features & 32 /* EsmMode */)) && loadModuleFromFile(extensions2, candidate2, onlyRecordFailures, state2) || loadNodeModuleFromDirectoryWorker(
|
|
@@ -29189,7 +29239,7 @@ function loadModuleFromSpecificNodeModulesDirectory(extensions, moduleName, node
|
|
|
29189
29239
|
if (!pathAndExtension && packageInfo && (packageInfo.contents.packageJsonContent.exports === void 0 || packageInfo.contents.packageJsonContent.exports === null) && state2.features & 32 /* EsmMode */) {
|
|
29190
29240
|
pathAndExtension = loadModuleFromFile(extensions2, combinePaths(candidate2, "index.js"), onlyRecordFailures, state2);
|
|
29191
29241
|
}
|
|
29192
|
-
return withPackageId(packageInfo, pathAndExtension);
|
|
29242
|
+
return withPackageId(packageInfo, pathAndExtension, state2);
|
|
29193
29243
|
};
|
|
29194
29244
|
if (rest !== "") {
|
|
29195
29245
|
packageInfo = rootPackageInfo ?? getPackageJsonInfo(packageDirectory, !nodeModulesDirectoryExists, state);
|
|
@@ -29379,7 +29429,7 @@ function resolveFromTypeRoot(moduleName, state) {
|
|
|
29379
29429
|
false,
|
|
29380
29430
|
state
|
|
29381
29431
|
) : void 0;
|
|
29382
|
-
return toSearchResult(withPackageId(packageInfo, resolvedFromFile));
|
|
29432
|
+
return toSearchResult(withPackageId(packageInfo, resolvedFromFile, state));
|
|
29383
29433
|
}
|
|
29384
29434
|
const resolved = loadNodeModuleFromDirectory(4 /* Declaration */, candidate, !directoryExists, state);
|
|
29385
29435
|
if (resolved)
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "@typescript-deploys/pr-build",
|
|
3
3
|
"author": "Microsoft Corp.",
|
|
4
4
|
"homepage": "https://www.typescriptlang.org/",
|
|
5
|
-
"version": "5.4.0-pr-
|
|
5
|
+
"version": "5.4.0-pr-57029-10",
|
|
6
6
|
"license": "Apache-2.0",
|
|
7
7
|
"description": "TypeScript is a language for application scale JavaScript development",
|
|
8
8
|
"keywords": [
|
|
@@ -114,5 +114,5 @@
|
|
|
114
114
|
"node": "20.1.0",
|
|
115
115
|
"npm": "8.19.4"
|
|
116
116
|
},
|
|
117
|
-
"gitHead": "
|
|
117
|
+
"gitHead": "c8d582cb35ea90dba7cf513fe85b2a597885a4f7"
|
|
118
118
|
}
|