typescript 4.9.0-dev.20220811 → 4.9.0-dev.20220812
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 +227 -66
- package/lib/tsserver.js +71 -9
- package/lib/tsserverlibrary.js +71 -9
- package/lib/typescript.js +71 -9
- package/lib/typescriptServices.js +71 -9
- package/lib/typingsInstaller.js +71 -9
- package/package.json +1 -1
package/lib/tsserver.js
CHANGED
|
@@ -109,7 +109,7 @@ var ts;
|
|
|
109
109
|
// The following is baselined as a literal template type without intervention
|
|
110
110
|
/** The version of the TypeScript compiler release */
|
|
111
111
|
// eslint-disable-next-line @typescript-eslint/no-inferrable-types
|
|
112
|
-
ts.version = ts.versionMajorMinor + ".0-dev.
|
|
112
|
+
ts.version = ts.versionMajorMinor + ".0-dev.20220812";
|
|
113
113
|
/* @internal */
|
|
114
114
|
var Comparison;
|
|
115
115
|
(function (Comparison) {
|
|
@@ -3563,6 +3563,8 @@ var ts;
|
|
|
3563
3563
|
typeof performance.mark === "function" &&
|
|
3564
3564
|
typeof performance.measure === "function" &&
|
|
3565
3565
|
typeof performance.now === "function" &&
|
|
3566
|
+
typeof performance.clearMarks === "function" &&
|
|
3567
|
+
typeof performance.clearMeasures === "function" &&
|
|
3566
3568
|
typeof PerformanceObserver === "function";
|
|
3567
3569
|
}
|
|
3568
3570
|
function tryGetWebPerformanceHooks() {
|
|
@@ -3607,7 +3609,9 @@ var ts;
|
|
|
3607
3609
|
if (end === "__performance.measure-fix__") {
|
|
3608
3610
|
nodePerformance_1.clearMarks("__performance.measure-fix__");
|
|
3609
3611
|
}
|
|
3610
|
-
}
|
|
3612
|
+
},
|
|
3613
|
+
clearMarks: function (name) { return nodePerformance_1.clearMarks(name); },
|
|
3614
|
+
clearMeasures: function (name) { return nodePerformance_1.clearMeasures(name); },
|
|
3611
3615
|
};
|
|
3612
3616
|
}
|
|
3613
3617
|
return {
|
|
@@ -3740,6 +3744,30 @@ var ts;
|
|
|
3740
3744
|
durations.forEach(function (duration, measureName) { return cb(measureName, duration); });
|
|
3741
3745
|
}
|
|
3742
3746
|
performance.forEachMeasure = forEachMeasure;
|
|
3747
|
+
function forEachMark(cb) {
|
|
3748
|
+
marks.forEach(function (_time, markName) { return cb(markName); });
|
|
3749
|
+
}
|
|
3750
|
+
performance.forEachMark = forEachMark;
|
|
3751
|
+
function clearMeasures(name) {
|
|
3752
|
+
if (name !== undefined)
|
|
3753
|
+
durations.delete(name);
|
|
3754
|
+
else
|
|
3755
|
+
durations.clear();
|
|
3756
|
+
performanceImpl === null || performanceImpl === void 0 ? void 0 : performanceImpl.clearMeasures(name);
|
|
3757
|
+
}
|
|
3758
|
+
performance.clearMeasures = clearMeasures;
|
|
3759
|
+
function clearMarks(name) {
|
|
3760
|
+
if (name !== undefined) {
|
|
3761
|
+
counts.delete(name);
|
|
3762
|
+
marks.delete(name);
|
|
3763
|
+
}
|
|
3764
|
+
else {
|
|
3765
|
+
counts.clear();
|
|
3766
|
+
marks.clear();
|
|
3767
|
+
}
|
|
3768
|
+
performanceImpl === null || performanceImpl === void 0 ? void 0 : performanceImpl.clearMarks(name);
|
|
3769
|
+
}
|
|
3770
|
+
performance.clearMarks = clearMarks;
|
|
3743
3771
|
/**
|
|
3744
3772
|
* Indicates whether the performance API is enabled.
|
|
3745
3773
|
*/
|
|
@@ -73972,17 +74000,15 @@ var ts;
|
|
|
73972
74000
|
var typeParams = getLocalTypeParametersOfClassOrInterfaceOrTypeAlias(intrinsicClassAttribs.symbol);
|
|
73973
74001
|
var hostClassType = getReturnTypeOfSignature(sig);
|
|
73974
74002
|
var libraryManagedAttributeType = void 0;
|
|
73975
|
-
if (typeParams
|
|
74003
|
+
if (typeParams) {
|
|
74004
|
+
// apply JSX.IntrinsicClassElements<hostClassType, ...>
|
|
73976
74005
|
var inferredArgs = fillMissingTypeArguments([hostClassType], typeParams, getMinTypeArgumentCount(typeParams), ts.isInJSFile(context));
|
|
73977
74006
|
libraryManagedAttributeType = instantiateType(intrinsicClassAttribs, createTypeMapper(typeParams, inferredArgs));
|
|
73978
74007
|
}
|
|
73979
|
-
|
|
73980
|
-
libraryManagedAttributeType = undefined;
|
|
74008
|
+
// or JSX.IntrinsicClassElements has no generics.
|
|
73981
74009
|
else
|
|
73982
74010
|
libraryManagedAttributeType = intrinsicClassAttribs;
|
|
73983
|
-
|
|
73984
|
-
apparentAttributesType = intersectTypes(libraryManagedAttributeType, apparentAttributesType);
|
|
73985
|
-
}
|
|
74011
|
+
apparentAttributesType = intersectTypes(libraryManagedAttributeType, apparentAttributesType);
|
|
73986
74012
|
}
|
|
73987
74013
|
var intrinsicAttribs = getJsxType(JsxNames.IntrinsicAttributes, context);
|
|
73988
74014
|
if (!isErrorType(intrinsicAttribs)) {
|
|
@@ -126064,6 +126090,7 @@ var ts;
|
|
|
126064
126090
|
if (value) {
|
|
126065
126091
|
return isParsedCommandLine(value) ? value : undefined;
|
|
126066
126092
|
}
|
|
126093
|
+
ts.performance.mark("SolutionBuilder::beforeConfigFileParsing");
|
|
126067
126094
|
var diagnostic;
|
|
126068
126095
|
var parseConfigFileHost = state.parseConfigFileHost, baseCompilerOptions = state.baseCompilerOptions, baseWatchOptions = state.baseWatchOptions, extendedConfigCache = state.extendedConfigCache, host = state.host;
|
|
126069
126096
|
var parsed;
|
|
@@ -126078,6 +126105,8 @@ var ts;
|
|
|
126078
126105
|
parseConfigFileHost.onUnRecoverableConfigFileDiagnostic = ts.noop;
|
|
126079
126106
|
}
|
|
126080
126107
|
configFileCache.set(configFilePath, parsed || diagnostic);
|
|
126108
|
+
ts.performance.mark("SolutionBuilder::afterConfigFileParsing");
|
|
126109
|
+
ts.performance.measure("SolutionBuilder::Config file parsing", "SolutionBuilder::beforeConfigFileParsing", "SolutionBuilder::afterConfigFileParsing");
|
|
126081
126110
|
return parsed;
|
|
126082
126111
|
}
|
|
126083
126112
|
function resolveProjectName(state, name) {
|
|
@@ -126277,6 +126306,7 @@ var ts;
|
|
|
126277
126306
|
if (updateOutputFileStampsPending) {
|
|
126278
126307
|
updateOutputTimestamps(state, config, projectPath);
|
|
126279
126308
|
}
|
|
126309
|
+
ts.performance.mark("SolutionBuilder::Timestamps only updates");
|
|
126280
126310
|
return doneInvalidatedProject(state, projectPath);
|
|
126281
126311
|
}
|
|
126282
126312
|
};
|
|
@@ -126370,6 +126400,10 @@ var ts;
|
|
|
126370
126400
|
};
|
|
126371
126401
|
function done(cancellationToken, writeFile, customTransformers) {
|
|
126372
126402
|
executeSteps(BuildStep.Done, cancellationToken, writeFile, customTransformers);
|
|
126403
|
+
if (kind === InvalidatedProjectKind.Build)
|
|
126404
|
+
ts.performance.mark("SolutionBuilder::Projects built");
|
|
126405
|
+
else
|
|
126406
|
+
ts.performance.mark("SolutionBuilder::Bundles updated");
|
|
126373
126407
|
return doneInvalidatedProject(state, projectPath);
|
|
126374
126408
|
}
|
|
126375
126409
|
function withProgramOrUndefined(action) {
|
|
@@ -127142,7 +127176,10 @@ var ts;
|
|
|
127142
127176
|
if (prior !== undefined) {
|
|
127143
127177
|
return prior;
|
|
127144
127178
|
}
|
|
127179
|
+
ts.performance.mark("SolutionBuilder::beforeUpToDateCheck");
|
|
127145
127180
|
var actual = getUpToDateStatusWorker(state, project, resolvedPath);
|
|
127181
|
+
ts.performance.mark("SolutionBuilder::afterUpToDateCheck");
|
|
127182
|
+
ts.performance.measure("SolutionBuilder::Up-to-date check", "SolutionBuilder::beforeUpToDateCheck", "SolutionBuilder::afterUpToDateCheck");
|
|
127146
127183
|
state.projectStatus.set(resolvedPath, actual);
|
|
127147
127184
|
return actual;
|
|
127148
127185
|
}
|
|
@@ -127280,6 +127317,13 @@ var ts;
|
|
|
127280
127317
|
}
|
|
127281
127318
|
}
|
|
127282
127319
|
function build(state, project, cancellationToken, writeFile, getCustomTransformers, onlyReferences) {
|
|
127320
|
+
ts.performance.mark("SolutionBuilder::beforeBuild");
|
|
127321
|
+
var result = buildWorker(state, project, cancellationToken, writeFile, getCustomTransformers, onlyReferences);
|
|
127322
|
+
ts.performance.mark("SolutionBuilder::afterBuild");
|
|
127323
|
+
ts.performance.measure("SolutionBuilder::Build", "SolutionBuilder::beforeBuild", "SolutionBuilder::afterBuild");
|
|
127324
|
+
return result;
|
|
127325
|
+
}
|
|
127326
|
+
function buildWorker(state, project, cancellationToken, writeFile, getCustomTransformers, onlyReferences) {
|
|
127283
127327
|
var buildOrder = getBuildOrderFor(state, project, onlyReferences);
|
|
127284
127328
|
if (!buildOrder)
|
|
127285
127329
|
return ts.ExitStatus.InvalidProject_OutputsSkipped;
|
|
@@ -127307,6 +127351,13 @@ var ts;
|
|
|
127307
127351
|
: ts.ExitStatus.DiagnosticsPresent_OutputsSkipped;
|
|
127308
127352
|
}
|
|
127309
127353
|
function clean(state, project, onlyReferences) {
|
|
127354
|
+
ts.performance.mark("SolutionBuilder::beforeClean");
|
|
127355
|
+
var result = cleanWorker(state, project, onlyReferences);
|
|
127356
|
+
ts.performance.mark("SolutionBuilder::afterClean");
|
|
127357
|
+
ts.performance.measure("SolutionBuilder::Clean", "SolutionBuilder::beforeClean", "SolutionBuilder::afterClean");
|
|
127358
|
+
return result;
|
|
127359
|
+
}
|
|
127360
|
+
function cleanWorker(state, project, onlyReferences) {
|
|
127310
127361
|
var buildOrder = getBuildOrderFor(state, project, onlyReferences);
|
|
127311
127362
|
if (!buildOrder)
|
|
127312
127363
|
return ts.ExitStatus.InvalidProject_OutputsSkipped;
|
|
@@ -127380,6 +127431,14 @@ var ts;
|
|
|
127380
127431
|
state.timerToBuildInvalidatedProject = hostWithWatch.setTimeout(buildNextInvalidatedProject, time, state, changeDetected);
|
|
127381
127432
|
}
|
|
127382
127433
|
function buildNextInvalidatedProject(state, changeDetected) {
|
|
127434
|
+
ts.performance.mark("SolutionBuilder::beforeBuild");
|
|
127435
|
+
var buildOrder = buildNextInvalidatedProjectWorker(state, changeDetected);
|
|
127436
|
+
ts.performance.mark("SolutionBuilder::afterBuild");
|
|
127437
|
+
ts.performance.measure("SolutionBuilder::Build", "SolutionBuilder::beforeBuild", "SolutionBuilder::afterBuild");
|
|
127438
|
+
if (buildOrder)
|
|
127439
|
+
reportErrorSummary(state, buildOrder);
|
|
127440
|
+
}
|
|
127441
|
+
function buildNextInvalidatedProjectWorker(state, changeDetected) {
|
|
127383
127442
|
state.timerToBuildInvalidatedProject = undefined;
|
|
127384
127443
|
if (state.reportFileChangeDetected) {
|
|
127385
127444
|
state.reportFileChangeDetected = false;
|
|
@@ -127412,7 +127471,7 @@ var ts;
|
|
|
127412
127471
|
}
|
|
127413
127472
|
}
|
|
127414
127473
|
disableCache(state);
|
|
127415
|
-
|
|
127474
|
+
return buildOrder;
|
|
127416
127475
|
}
|
|
127417
127476
|
function watchConfigFile(state, resolved, resolvedPath, parsed) {
|
|
127418
127477
|
if (!state.watch || state.allWatchedConfigFiles.has(resolvedPath))
|
|
@@ -127467,6 +127526,7 @@ var ts;
|
|
|
127467
127526
|
function startWatching(state, buildOrder) {
|
|
127468
127527
|
if (!state.watchAllProjectsPending)
|
|
127469
127528
|
return;
|
|
127529
|
+
ts.performance.mark("SolutionBuilder::beforeWatcherCreation");
|
|
127470
127530
|
state.watchAllProjectsPending = false;
|
|
127471
127531
|
for (var _i = 0, _a = getBuildOrderFromAnyBuildOrder(buildOrder); _i < _a.length; _i++) {
|
|
127472
127532
|
var resolved = _a[_i];
|
|
@@ -127484,6 +127544,8 @@ var ts;
|
|
|
127484
127544
|
watchPackageJsonFiles(state, resolved, resolvedPath, cfg);
|
|
127485
127545
|
}
|
|
127486
127546
|
}
|
|
127547
|
+
ts.performance.mark("SolutionBuilder::afterWatcherCreation");
|
|
127548
|
+
ts.performance.measure("SolutionBuilder::Watcher creation", "SolutionBuilder::beforeWatcherCreation", "SolutionBuilder::afterWatcherCreation");
|
|
127487
127549
|
}
|
|
127488
127550
|
function stopWatching(state) {
|
|
127489
127551
|
ts.clearMap(state.allWatchedConfigFiles, ts.closeFileWatcher);
|
package/lib/tsserverlibrary.js
CHANGED
|
@@ -108,7 +108,7 @@ var ts;
|
|
|
108
108
|
// The following is baselined as a literal template type without intervention
|
|
109
109
|
/** The version of the TypeScript compiler release */
|
|
110
110
|
// eslint-disable-next-line @typescript-eslint/no-inferrable-types
|
|
111
|
-
ts.version = ts.versionMajorMinor + ".0-dev.
|
|
111
|
+
ts.version = ts.versionMajorMinor + ".0-dev.20220812";
|
|
112
112
|
/* @internal */
|
|
113
113
|
var Comparison;
|
|
114
114
|
(function (Comparison) {
|
|
@@ -3562,6 +3562,8 @@ var ts;
|
|
|
3562
3562
|
typeof performance.mark === "function" &&
|
|
3563
3563
|
typeof performance.measure === "function" &&
|
|
3564
3564
|
typeof performance.now === "function" &&
|
|
3565
|
+
typeof performance.clearMarks === "function" &&
|
|
3566
|
+
typeof performance.clearMeasures === "function" &&
|
|
3565
3567
|
typeof PerformanceObserver === "function";
|
|
3566
3568
|
}
|
|
3567
3569
|
function tryGetWebPerformanceHooks() {
|
|
@@ -3606,7 +3608,9 @@ var ts;
|
|
|
3606
3608
|
if (end === "__performance.measure-fix__") {
|
|
3607
3609
|
nodePerformance_1.clearMarks("__performance.measure-fix__");
|
|
3608
3610
|
}
|
|
3609
|
-
}
|
|
3611
|
+
},
|
|
3612
|
+
clearMarks: function (name) { return nodePerformance_1.clearMarks(name); },
|
|
3613
|
+
clearMeasures: function (name) { return nodePerformance_1.clearMeasures(name); },
|
|
3610
3614
|
};
|
|
3611
3615
|
}
|
|
3612
3616
|
return {
|
|
@@ -3739,6 +3743,30 @@ var ts;
|
|
|
3739
3743
|
durations.forEach(function (duration, measureName) { return cb(measureName, duration); });
|
|
3740
3744
|
}
|
|
3741
3745
|
performance.forEachMeasure = forEachMeasure;
|
|
3746
|
+
function forEachMark(cb) {
|
|
3747
|
+
marks.forEach(function (_time, markName) { return cb(markName); });
|
|
3748
|
+
}
|
|
3749
|
+
performance.forEachMark = forEachMark;
|
|
3750
|
+
function clearMeasures(name) {
|
|
3751
|
+
if (name !== undefined)
|
|
3752
|
+
durations.delete(name);
|
|
3753
|
+
else
|
|
3754
|
+
durations.clear();
|
|
3755
|
+
performanceImpl === null || performanceImpl === void 0 ? void 0 : performanceImpl.clearMeasures(name);
|
|
3756
|
+
}
|
|
3757
|
+
performance.clearMeasures = clearMeasures;
|
|
3758
|
+
function clearMarks(name) {
|
|
3759
|
+
if (name !== undefined) {
|
|
3760
|
+
counts.delete(name);
|
|
3761
|
+
marks.delete(name);
|
|
3762
|
+
}
|
|
3763
|
+
else {
|
|
3764
|
+
counts.clear();
|
|
3765
|
+
marks.clear();
|
|
3766
|
+
}
|
|
3767
|
+
performanceImpl === null || performanceImpl === void 0 ? void 0 : performanceImpl.clearMarks(name);
|
|
3768
|
+
}
|
|
3769
|
+
performance.clearMarks = clearMarks;
|
|
3742
3770
|
/**
|
|
3743
3771
|
* Indicates whether the performance API is enabled.
|
|
3744
3772
|
*/
|
|
@@ -73971,17 +73999,15 @@ var ts;
|
|
|
73971
73999
|
var typeParams = getLocalTypeParametersOfClassOrInterfaceOrTypeAlias(intrinsicClassAttribs.symbol);
|
|
73972
74000
|
var hostClassType = getReturnTypeOfSignature(sig);
|
|
73973
74001
|
var libraryManagedAttributeType = void 0;
|
|
73974
|
-
if (typeParams
|
|
74002
|
+
if (typeParams) {
|
|
74003
|
+
// apply JSX.IntrinsicClassElements<hostClassType, ...>
|
|
73975
74004
|
var inferredArgs = fillMissingTypeArguments([hostClassType], typeParams, getMinTypeArgumentCount(typeParams), ts.isInJSFile(context));
|
|
73976
74005
|
libraryManagedAttributeType = instantiateType(intrinsicClassAttribs, createTypeMapper(typeParams, inferredArgs));
|
|
73977
74006
|
}
|
|
73978
|
-
|
|
73979
|
-
libraryManagedAttributeType = undefined;
|
|
74007
|
+
// or JSX.IntrinsicClassElements has no generics.
|
|
73980
74008
|
else
|
|
73981
74009
|
libraryManagedAttributeType = intrinsicClassAttribs;
|
|
73982
|
-
|
|
73983
|
-
apparentAttributesType = intersectTypes(libraryManagedAttributeType, apparentAttributesType);
|
|
73984
|
-
}
|
|
74010
|
+
apparentAttributesType = intersectTypes(libraryManagedAttributeType, apparentAttributesType);
|
|
73985
74011
|
}
|
|
73986
74012
|
var intrinsicAttribs = getJsxType(JsxNames.IntrinsicAttributes, context);
|
|
73987
74013
|
if (!isErrorType(intrinsicAttribs)) {
|
|
@@ -126063,6 +126089,7 @@ var ts;
|
|
|
126063
126089
|
if (value) {
|
|
126064
126090
|
return isParsedCommandLine(value) ? value : undefined;
|
|
126065
126091
|
}
|
|
126092
|
+
ts.performance.mark("SolutionBuilder::beforeConfigFileParsing");
|
|
126066
126093
|
var diagnostic;
|
|
126067
126094
|
var parseConfigFileHost = state.parseConfigFileHost, baseCompilerOptions = state.baseCompilerOptions, baseWatchOptions = state.baseWatchOptions, extendedConfigCache = state.extendedConfigCache, host = state.host;
|
|
126068
126095
|
var parsed;
|
|
@@ -126077,6 +126104,8 @@ var ts;
|
|
|
126077
126104
|
parseConfigFileHost.onUnRecoverableConfigFileDiagnostic = ts.noop;
|
|
126078
126105
|
}
|
|
126079
126106
|
configFileCache.set(configFilePath, parsed || diagnostic);
|
|
126107
|
+
ts.performance.mark("SolutionBuilder::afterConfigFileParsing");
|
|
126108
|
+
ts.performance.measure("SolutionBuilder::Config file parsing", "SolutionBuilder::beforeConfigFileParsing", "SolutionBuilder::afterConfigFileParsing");
|
|
126080
126109
|
return parsed;
|
|
126081
126110
|
}
|
|
126082
126111
|
function resolveProjectName(state, name) {
|
|
@@ -126276,6 +126305,7 @@ var ts;
|
|
|
126276
126305
|
if (updateOutputFileStampsPending) {
|
|
126277
126306
|
updateOutputTimestamps(state, config, projectPath);
|
|
126278
126307
|
}
|
|
126308
|
+
ts.performance.mark("SolutionBuilder::Timestamps only updates");
|
|
126279
126309
|
return doneInvalidatedProject(state, projectPath);
|
|
126280
126310
|
}
|
|
126281
126311
|
};
|
|
@@ -126369,6 +126399,10 @@ var ts;
|
|
|
126369
126399
|
};
|
|
126370
126400
|
function done(cancellationToken, writeFile, customTransformers) {
|
|
126371
126401
|
executeSteps(BuildStep.Done, cancellationToken, writeFile, customTransformers);
|
|
126402
|
+
if (kind === InvalidatedProjectKind.Build)
|
|
126403
|
+
ts.performance.mark("SolutionBuilder::Projects built");
|
|
126404
|
+
else
|
|
126405
|
+
ts.performance.mark("SolutionBuilder::Bundles updated");
|
|
126372
126406
|
return doneInvalidatedProject(state, projectPath);
|
|
126373
126407
|
}
|
|
126374
126408
|
function withProgramOrUndefined(action) {
|
|
@@ -127141,7 +127175,10 @@ var ts;
|
|
|
127141
127175
|
if (prior !== undefined) {
|
|
127142
127176
|
return prior;
|
|
127143
127177
|
}
|
|
127178
|
+
ts.performance.mark("SolutionBuilder::beforeUpToDateCheck");
|
|
127144
127179
|
var actual = getUpToDateStatusWorker(state, project, resolvedPath);
|
|
127180
|
+
ts.performance.mark("SolutionBuilder::afterUpToDateCheck");
|
|
127181
|
+
ts.performance.measure("SolutionBuilder::Up-to-date check", "SolutionBuilder::beforeUpToDateCheck", "SolutionBuilder::afterUpToDateCheck");
|
|
127145
127182
|
state.projectStatus.set(resolvedPath, actual);
|
|
127146
127183
|
return actual;
|
|
127147
127184
|
}
|
|
@@ -127279,6 +127316,13 @@ var ts;
|
|
|
127279
127316
|
}
|
|
127280
127317
|
}
|
|
127281
127318
|
function build(state, project, cancellationToken, writeFile, getCustomTransformers, onlyReferences) {
|
|
127319
|
+
ts.performance.mark("SolutionBuilder::beforeBuild");
|
|
127320
|
+
var result = buildWorker(state, project, cancellationToken, writeFile, getCustomTransformers, onlyReferences);
|
|
127321
|
+
ts.performance.mark("SolutionBuilder::afterBuild");
|
|
127322
|
+
ts.performance.measure("SolutionBuilder::Build", "SolutionBuilder::beforeBuild", "SolutionBuilder::afterBuild");
|
|
127323
|
+
return result;
|
|
127324
|
+
}
|
|
127325
|
+
function buildWorker(state, project, cancellationToken, writeFile, getCustomTransformers, onlyReferences) {
|
|
127282
127326
|
var buildOrder = getBuildOrderFor(state, project, onlyReferences);
|
|
127283
127327
|
if (!buildOrder)
|
|
127284
127328
|
return ts.ExitStatus.InvalidProject_OutputsSkipped;
|
|
@@ -127306,6 +127350,13 @@ var ts;
|
|
|
127306
127350
|
: ts.ExitStatus.DiagnosticsPresent_OutputsSkipped;
|
|
127307
127351
|
}
|
|
127308
127352
|
function clean(state, project, onlyReferences) {
|
|
127353
|
+
ts.performance.mark("SolutionBuilder::beforeClean");
|
|
127354
|
+
var result = cleanWorker(state, project, onlyReferences);
|
|
127355
|
+
ts.performance.mark("SolutionBuilder::afterClean");
|
|
127356
|
+
ts.performance.measure("SolutionBuilder::Clean", "SolutionBuilder::beforeClean", "SolutionBuilder::afterClean");
|
|
127357
|
+
return result;
|
|
127358
|
+
}
|
|
127359
|
+
function cleanWorker(state, project, onlyReferences) {
|
|
127309
127360
|
var buildOrder = getBuildOrderFor(state, project, onlyReferences);
|
|
127310
127361
|
if (!buildOrder)
|
|
127311
127362
|
return ts.ExitStatus.InvalidProject_OutputsSkipped;
|
|
@@ -127379,6 +127430,14 @@ var ts;
|
|
|
127379
127430
|
state.timerToBuildInvalidatedProject = hostWithWatch.setTimeout(buildNextInvalidatedProject, time, state, changeDetected);
|
|
127380
127431
|
}
|
|
127381
127432
|
function buildNextInvalidatedProject(state, changeDetected) {
|
|
127433
|
+
ts.performance.mark("SolutionBuilder::beforeBuild");
|
|
127434
|
+
var buildOrder = buildNextInvalidatedProjectWorker(state, changeDetected);
|
|
127435
|
+
ts.performance.mark("SolutionBuilder::afterBuild");
|
|
127436
|
+
ts.performance.measure("SolutionBuilder::Build", "SolutionBuilder::beforeBuild", "SolutionBuilder::afterBuild");
|
|
127437
|
+
if (buildOrder)
|
|
127438
|
+
reportErrorSummary(state, buildOrder);
|
|
127439
|
+
}
|
|
127440
|
+
function buildNextInvalidatedProjectWorker(state, changeDetected) {
|
|
127382
127441
|
state.timerToBuildInvalidatedProject = undefined;
|
|
127383
127442
|
if (state.reportFileChangeDetected) {
|
|
127384
127443
|
state.reportFileChangeDetected = false;
|
|
@@ -127411,7 +127470,7 @@ var ts;
|
|
|
127411
127470
|
}
|
|
127412
127471
|
}
|
|
127413
127472
|
disableCache(state);
|
|
127414
|
-
|
|
127473
|
+
return buildOrder;
|
|
127415
127474
|
}
|
|
127416
127475
|
function watchConfigFile(state, resolved, resolvedPath, parsed) {
|
|
127417
127476
|
if (!state.watch || state.allWatchedConfigFiles.has(resolvedPath))
|
|
@@ -127466,6 +127525,7 @@ var ts;
|
|
|
127466
127525
|
function startWatching(state, buildOrder) {
|
|
127467
127526
|
if (!state.watchAllProjectsPending)
|
|
127468
127527
|
return;
|
|
127528
|
+
ts.performance.mark("SolutionBuilder::beforeWatcherCreation");
|
|
127469
127529
|
state.watchAllProjectsPending = false;
|
|
127470
127530
|
for (var _i = 0, _a = getBuildOrderFromAnyBuildOrder(buildOrder); _i < _a.length; _i++) {
|
|
127471
127531
|
var resolved = _a[_i];
|
|
@@ -127483,6 +127543,8 @@ var ts;
|
|
|
127483
127543
|
watchPackageJsonFiles(state, resolved, resolvedPath, cfg);
|
|
127484
127544
|
}
|
|
127485
127545
|
}
|
|
127546
|
+
ts.performance.mark("SolutionBuilder::afterWatcherCreation");
|
|
127547
|
+
ts.performance.measure("SolutionBuilder::Watcher creation", "SolutionBuilder::beforeWatcherCreation", "SolutionBuilder::afterWatcherCreation");
|
|
127486
127548
|
}
|
|
127487
127549
|
function stopWatching(state) {
|
|
127488
127550
|
ts.clearMap(state.allWatchedConfigFiles, ts.closeFileWatcher);
|
package/lib/typescript.js
CHANGED
|
@@ -99,7 +99,7 @@ var ts;
|
|
|
99
99
|
// The following is baselined as a literal template type without intervention
|
|
100
100
|
/** The version of the TypeScript compiler release */
|
|
101
101
|
// eslint-disable-next-line @typescript-eslint/no-inferrable-types
|
|
102
|
-
ts.version = ts.versionMajorMinor + ".0-dev.
|
|
102
|
+
ts.version = ts.versionMajorMinor + ".0-dev.20220812";
|
|
103
103
|
/* @internal */
|
|
104
104
|
var Comparison;
|
|
105
105
|
(function (Comparison) {
|
|
@@ -3553,6 +3553,8 @@ var ts;
|
|
|
3553
3553
|
typeof performance.mark === "function" &&
|
|
3554
3554
|
typeof performance.measure === "function" &&
|
|
3555
3555
|
typeof performance.now === "function" &&
|
|
3556
|
+
typeof performance.clearMarks === "function" &&
|
|
3557
|
+
typeof performance.clearMeasures === "function" &&
|
|
3556
3558
|
typeof PerformanceObserver === "function";
|
|
3557
3559
|
}
|
|
3558
3560
|
function tryGetWebPerformanceHooks() {
|
|
@@ -3597,7 +3599,9 @@ var ts;
|
|
|
3597
3599
|
if (end === "__performance.measure-fix__") {
|
|
3598
3600
|
nodePerformance_1.clearMarks("__performance.measure-fix__");
|
|
3599
3601
|
}
|
|
3600
|
-
}
|
|
3602
|
+
},
|
|
3603
|
+
clearMarks: function (name) { return nodePerformance_1.clearMarks(name); },
|
|
3604
|
+
clearMeasures: function (name) { return nodePerformance_1.clearMeasures(name); },
|
|
3601
3605
|
};
|
|
3602
3606
|
}
|
|
3603
3607
|
return {
|
|
@@ -3730,6 +3734,30 @@ var ts;
|
|
|
3730
3734
|
durations.forEach(function (duration, measureName) { return cb(measureName, duration); });
|
|
3731
3735
|
}
|
|
3732
3736
|
performance.forEachMeasure = forEachMeasure;
|
|
3737
|
+
function forEachMark(cb) {
|
|
3738
|
+
marks.forEach(function (_time, markName) { return cb(markName); });
|
|
3739
|
+
}
|
|
3740
|
+
performance.forEachMark = forEachMark;
|
|
3741
|
+
function clearMeasures(name) {
|
|
3742
|
+
if (name !== undefined)
|
|
3743
|
+
durations.delete(name);
|
|
3744
|
+
else
|
|
3745
|
+
durations.clear();
|
|
3746
|
+
performanceImpl === null || performanceImpl === void 0 ? void 0 : performanceImpl.clearMeasures(name);
|
|
3747
|
+
}
|
|
3748
|
+
performance.clearMeasures = clearMeasures;
|
|
3749
|
+
function clearMarks(name) {
|
|
3750
|
+
if (name !== undefined) {
|
|
3751
|
+
counts.delete(name);
|
|
3752
|
+
marks.delete(name);
|
|
3753
|
+
}
|
|
3754
|
+
else {
|
|
3755
|
+
counts.clear();
|
|
3756
|
+
marks.clear();
|
|
3757
|
+
}
|
|
3758
|
+
performanceImpl === null || performanceImpl === void 0 ? void 0 : performanceImpl.clearMarks(name);
|
|
3759
|
+
}
|
|
3760
|
+
performance.clearMarks = clearMarks;
|
|
3733
3761
|
/**
|
|
3734
3762
|
* Indicates whether the performance API is enabled.
|
|
3735
3763
|
*/
|
|
@@ -73962,17 +73990,15 @@ var ts;
|
|
|
73962
73990
|
var typeParams = getLocalTypeParametersOfClassOrInterfaceOrTypeAlias(intrinsicClassAttribs.symbol);
|
|
73963
73991
|
var hostClassType = getReturnTypeOfSignature(sig);
|
|
73964
73992
|
var libraryManagedAttributeType = void 0;
|
|
73965
|
-
if (typeParams
|
|
73993
|
+
if (typeParams) {
|
|
73994
|
+
// apply JSX.IntrinsicClassElements<hostClassType, ...>
|
|
73966
73995
|
var inferredArgs = fillMissingTypeArguments([hostClassType], typeParams, getMinTypeArgumentCount(typeParams), ts.isInJSFile(context));
|
|
73967
73996
|
libraryManagedAttributeType = instantiateType(intrinsicClassAttribs, createTypeMapper(typeParams, inferredArgs));
|
|
73968
73997
|
}
|
|
73969
|
-
|
|
73970
|
-
libraryManagedAttributeType = undefined;
|
|
73998
|
+
// or JSX.IntrinsicClassElements has no generics.
|
|
73971
73999
|
else
|
|
73972
74000
|
libraryManagedAttributeType = intrinsicClassAttribs;
|
|
73973
|
-
|
|
73974
|
-
apparentAttributesType = intersectTypes(libraryManagedAttributeType, apparentAttributesType);
|
|
73975
|
-
}
|
|
74001
|
+
apparentAttributesType = intersectTypes(libraryManagedAttributeType, apparentAttributesType);
|
|
73976
74002
|
}
|
|
73977
74003
|
var intrinsicAttribs = getJsxType(JsxNames.IntrinsicAttributes, context);
|
|
73978
74004
|
if (!isErrorType(intrinsicAttribs)) {
|
|
@@ -126054,6 +126080,7 @@ var ts;
|
|
|
126054
126080
|
if (value) {
|
|
126055
126081
|
return isParsedCommandLine(value) ? value : undefined;
|
|
126056
126082
|
}
|
|
126083
|
+
ts.performance.mark("SolutionBuilder::beforeConfigFileParsing");
|
|
126057
126084
|
var diagnostic;
|
|
126058
126085
|
var parseConfigFileHost = state.parseConfigFileHost, baseCompilerOptions = state.baseCompilerOptions, baseWatchOptions = state.baseWatchOptions, extendedConfigCache = state.extendedConfigCache, host = state.host;
|
|
126059
126086
|
var parsed;
|
|
@@ -126068,6 +126095,8 @@ var ts;
|
|
|
126068
126095
|
parseConfigFileHost.onUnRecoverableConfigFileDiagnostic = ts.noop;
|
|
126069
126096
|
}
|
|
126070
126097
|
configFileCache.set(configFilePath, parsed || diagnostic);
|
|
126098
|
+
ts.performance.mark("SolutionBuilder::afterConfigFileParsing");
|
|
126099
|
+
ts.performance.measure("SolutionBuilder::Config file parsing", "SolutionBuilder::beforeConfigFileParsing", "SolutionBuilder::afterConfigFileParsing");
|
|
126071
126100
|
return parsed;
|
|
126072
126101
|
}
|
|
126073
126102
|
function resolveProjectName(state, name) {
|
|
@@ -126267,6 +126296,7 @@ var ts;
|
|
|
126267
126296
|
if (updateOutputFileStampsPending) {
|
|
126268
126297
|
updateOutputTimestamps(state, config, projectPath);
|
|
126269
126298
|
}
|
|
126299
|
+
ts.performance.mark("SolutionBuilder::Timestamps only updates");
|
|
126270
126300
|
return doneInvalidatedProject(state, projectPath);
|
|
126271
126301
|
}
|
|
126272
126302
|
};
|
|
@@ -126360,6 +126390,10 @@ var ts;
|
|
|
126360
126390
|
};
|
|
126361
126391
|
function done(cancellationToken, writeFile, customTransformers) {
|
|
126362
126392
|
executeSteps(BuildStep.Done, cancellationToken, writeFile, customTransformers);
|
|
126393
|
+
if (kind === InvalidatedProjectKind.Build)
|
|
126394
|
+
ts.performance.mark("SolutionBuilder::Projects built");
|
|
126395
|
+
else
|
|
126396
|
+
ts.performance.mark("SolutionBuilder::Bundles updated");
|
|
126363
126397
|
return doneInvalidatedProject(state, projectPath);
|
|
126364
126398
|
}
|
|
126365
126399
|
function withProgramOrUndefined(action) {
|
|
@@ -127132,7 +127166,10 @@ var ts;
|
|
|
127132
127166
|
if (prior !== undefined) {
|
|
127133
127167
|
return prior;
|
|
127134
127168
|
}
|
|
127169
|
+
ts.performance.mark("SolutionBuilder::beforeUpToDateCheck");
|
|
127135
127170
|
var actual = getUpToDateStatusWorker(state, project, resolvedPath);
|
|
127171
|
+
ts.performance.mark("SolutionBuilder::afterUpToDateCheck");
|
|
127172
|
+
ts.performance.measure("SolutionBuilder::Up-to-date check", "SolutionBuilder::beforeUpToDateCheck", "SolutionBuilder::afterUpToDateCheck");
|
|
127136
127173
|
state.projectStatus.set(resolvedPath, actual);
|
|
127137
127174
|
return actual;
|
|
127138
127175
|
}
|
|
@@ -127270,6 +127307,13 @@ var ts;
|
|
|
127270
127307
|
}
|
|
127271
127308
|
}
|
|
127272
127309
|
function build(state, project, cancellationToken, writeFile, getCustomTransformers, onlyReferences) {
|
|
127310
|
+
ts.performance.mark("SolutionBuilder::beforeBuild");
|
|
127311
|
+
var result = buildWorker(state, project, cancellationToken, writeFile, getCustomTransformers, onlyReferences);
|
|
127312
|
+
ts.performance.mark("SolutionBuilder::afterBuild");
|
|
127313
|
+
ts.performance.measure("SolutionBuilder::Build", "SolutionBuilder::beforeBuild", "SolutionBuilder::afterBuild");
|
|
127314
|
+
return result;
|
|
127315
|
+
}
|
|
127316
|
+
function buildWorker(state, project, cancellationToken, writeFile, getCustomTransformers, onlyReferences) {
|
|
127273
127317
|
var buildOrder = getBuildOrderFor(state, project, onlyReferences);
|
|
127274
127318
|
if (!buildOrder)
|
|
127275
127319
|
return ts.ExitStatus.InvalidProject_OutputsSkipped;
|
|
@@ -127297,6 +127341,13 @@ var ts;
|
|
|
127297
127341
|
: ts.ExitStatus.DiagnosticsPresent_OutputsSkipped;
|
|
127298
127342
|
}
|
|
127299
127343
|
function clean(state, project, onlyReferences) {
|
|
127344
|
+
ts.performance.mark("SolutionBuilder::beforeClean");
|
|
127345
|
+
var result = cleanWorker(state, project, onlyReferences);
|
|
127346
|
+
ts.performance.mark("SolutionBuilder::afterClean");
|
|
127347
|
+
ts.performance.measure("SolutionBuilder::Clean", "SolutionBuilder::beforeClean", "SolutionBuilder::afterClean");
|
|
127348
|
+
return result;
|
|
127349
|
+
}
|
|
127350
|
+
function cleanWorker(state, project, onlyReferences) {
|
|
127300
127351
|
var buildOrder = getBuildOrderFor(state, project, onlyReferences);
|
|
127301
127352
|
if (!buildOrder)
|
|
127302
127353
|
return ts.ExitStatus.InvalidProject_OutputsSkipped;
|
|
@@ -127370,6 +127421,14 @@ var ts;
|
|
|
127370
127421
|
state.timerToBuildInvalidatedProject = hostWithWatch.setTimeout(buildNextInvalidatedProject, time, state, changeDetected);
|
|
127371
127422
|
}
|
|
127372
127423
|
function buildNextInvalidatedProject(state, changeDetected) {
|
|
127424
|
+
ts.performance.mark("SolutionBuilder::beforeBuild");
|
|
127425
|
+
var buildOrder = buildNextInvalidatedProjectWorker(state, changeDetected);
|
|
127426
|
+
ts.performance.mark("SolutionBuilder::afterBuild");
|
|
127427
|
+
ts.performance.measure("SolutionBuilder::Build", "SolutionBuilder::beforeBuild", "SolutionBuilder::afterBuild");
|
|
127428
|
+
if (buildOrder)
|
|
127429
|
+
reportErrorSummary(state, buildOrder);
|
|
127430
|
+
}
|
|
127431
|
+
function buildNextInvalidatedProjectWorker(state, changeDetected) {
|
|
127373
127432
|
state.timerToBuildInvalidatedProject = undefined;
|
|
127374
127433
|
if (state.reportFileChangeDetected) {
|
|
127375
127434
|
state.reportFileChangeDetected = false;
|
|
@@ -127402,7 +127461,7 @@ var ts;
|
|
|
127402
127461
|
}
|
|
127403
127462
|
}
|
|
127404
127463
|
disableCache(state);
|
|
127405
|
-
|
|
127464
|
+
return buildOrder;
|
|
127406
127465
|
}
|
|
127407
127466
|
function watchConfigFile(state, resolved, resolvedPath, parsed) {
|
|
127408
127467
|
if (!state.watch || state.allWatchedConfigFiles.has(resolvedPath))
|
|
@@ -127457,6 +127516,7 @@ var ts;
|
|
|
127457
127516
|
function startWatching(state, buildOrder) {
|
|
127458
127517
|
if (!state.watchAllProjectsPending)
|
|
127459
127518
|
return;
|
|
127519
|
+
ts.performance.mark("SolutionBuilder::beforeWatcherCreation");
|
|
127460
127520
|
state.watchAllProjectsPending = false;
|
|
127461
127521
|
for (var _i = 0, _a = getBuildOrderFromAnyBuildOrder(buildOrder); _i < _a.length; _i++) {
|
|
127462
127522
|
var resolved = _a[_i];
|
|
@@ -127474,6 +127534,8 @@ var ts;
|
|
|
127474
127534
|
watchPackageJsonFiles(state, resolved, resolvedPath, cfg);
|
|
127475
127535
|
}
|
|
127476
127536
|
}
|
|
127537
|
+
ts.performance.mark("SolutionBuilder::afterWatcherCreation");
|
|
127538
|
+
ts.performance.measure("SolutionBuilder::Watcher creation", "SolutionBuilder::beforeWatcherCreation", "SolutionBuilder::afterWatcherCreation");
|
|
127477
127539
|
}
|
|
127478
127540
|
function stopWatching(state) {
|
|
127479
127541
|
ts.clearMap(state.allWatchedConfigFiles, ts.closeFileWatcher);
|