typescript 4.8.0-dev.20220523 → 4.8.0-dev.20220526
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/protocol.d.ts +1 -0
- package/lib/tsc.js +88 -51
- package/lib/tsserver.js +117 -64
- package/lib/tsserverlibrary.d.ts +2 -0
- package/lib/tsserverlibrary.js +117 -64
- package/lib/typescript.d.ts +1 -0
- package/lib/typescript.js +117 -64
- package/lib/typescriptServices.d.ts +1 -0
- package/lib/typescriptServices.js +117 -64
- package/lib/typingsInstaller.js +112 -64
- package/package.json +1 -1
package/lib/typingsInstaller.js
CHANGED
|
@@ -89,7 +89,7 @@ var ts;
|
|
|
89
89
|
// The following is baselined as a literal template type without intervention
|
|
90
90
|
/** The version of the TypeScript compiler release */
|
|
91
91
|
// eslint-disable-next-line @typescript-eslint/no-inferrable-types
|
|
92
|
-
ts.version = ts.versionMajorMinor + ".0-dev.
|
|
92
|
+
ts.version = ts.versionMajorMinor + ".0-dev.20220526";
|
|
93
93
|
/* @internal */
|
|
94
94
|
var Comparison;
|
|
95
95
|
(function (Comparison) {
|
|
@@ -42032,7 +42032,7 @@ var ts;
|
|
|
42032
42032
|
}
|
|
42033
42033
|
if (ts.isImplicitGlob(spec.substring(spec.lastIndexOf(ts.directorySeparator) + 1))) {
|
|
42034
42034
|
return {
|
|
42035
|
-
key: useCaseSensitiveFileNames ? spec : ts.toFileNameLowerCase(spec),
|
|
42035
|
+
key: ts.removeTrailingDirectorySeparator(useCaseSensitiveFileNames ? spec : ts.toFileNameLowerCase(spec)),
|
|
42036
42036
|
flags: 1 /* Recursive */
|
|
42037
42037
|
};
|
|
42038
42038
|
}
|
|
@@ -43137,16 +43137,20 @@ var ts;
|
|
|
43137
43137
|
function nodeNextModuleNameResolver(moduleName, containingFile, compilerOptions, host, cache, redirectedReference, resolutionMode) {
|
|
43138
43138
|
return nodeNextModuleNameResolverWorker(NodeResolutionFeatures.NodeNextDefault, moduleName, containingFile, compilerOptions, host, cache, redirectedReference, resolutionMode);
|
|
43139
43139
|
}
|
|
43140
|
+
var jsOnlyExtensions = [Extensions.JavaScript];
|
|
43141
|
+
var tsExtensions = [Extensions.TypeScript, Extensions.JavaScript];
|
|
43142
|
+
var tsPlusJsonExtensions = __spreadArray(__spreadArray([], tsExtensions, true), [Extensions.Json], false);
|
|
43143
|
+
var tsconfigExtensions = [Extensions.TSConfig];
|
|
43140
43144
|
function nodeNextModuleNameResolverWorker(features, moduleName, containingFile, compilerOptions, host, cache, redirectedReference, resolutionMode) {
|
|
43141
43145
|
var containingDirectory = ts.getDirectoryPath(containingFile);
|
|
43142
43146
|
// es module file or cjs-like input file, use a variant of the legacy cjs resolver that supports the selected modern features
|
|
43143
43147
|
var esmMode = resolutionMode === ts.ModuleKind.ESNext ? NodeResolutionFeatures.EsmMode : 0;
|
|
43144
|
-
|
|
43148
|
+
var extensions = compilerOptions.noDtsResolution ? [Extensions.TsOnly, Extensions.JavaScript] : tsExtensions;
|
|
43149
|
+
if (compilerOptions.resolveJsonModule) {
|
|
43150
|
+
extensions = __spreadArray(__spreadArray([], extensions, true), [Extensions.Json], false);
|
|
43151
|
+
}
|
|
43152
|
+
return nodeModuleNameResolverWorker(features | esmMode, moduleName, containingDirectory, compilerOptions, host, cache, extensions, redirectedReference);
|
|
43145
43153
|
}
|
|
43146
|
-
var jsOnlyExtensions = [Extensions.JavaScript];
|
|
43147
|
-
var tsExtensions = [Extensions.TypeScript, Extensions.JavaScript];
|
|
43148
|
-
var tsPlusJsonExtensions = __spreadArray(__spreadArray([], tsExtensions, true), [Extensions.Json], false);
|
|
43149
|
-
var tsconfigExtensions = [Extensions.TSConfig];
|
|
43150
43154
|
function tryResolveJSModuleWorker(moduleName, initialDir, host) {
|
|
43151
43155
|
return nodeModuleNameResolverWorker(NodeResolutionFeatures.None, moduleName, initialDir, { moduleResolution: ts.ModuleResolutionKind.NodeJs, allowJs: true }, host, /*cache*/ undefined, jsOnlyExtensions, /*redirectedReferences*/ undefined);
|
|
43152
43156
|
}
|
|
@@ -62173,7 +62177,7 @@ var ts;
|
|
|
62173
62177
|
function substituteIndexedMappedType(objectType, index) {
|
|
62174
62178
|
var mapper = createTypeMapper([getTypeParameterFromMappedType(objectType)], [index]);
|
|
62175
62179
|
var templateMapper = combineTypeMappers(objectType.mapper, mapper);
|
|
62176
|
-
return instantiateType(getTemplateTypeFromMappedType(objectType), templateMapper);
|
|
62180
|
+
return instantiateType(getTemplateTypeFromMappedType(objectType.target || objectType), templateMapper);
|
|
62177
62181
|
}
|
|
62178
62182
|
function getIndexedAccessType(objectType, indexType, accessFlags, accessNode, aliasSymbol, aliasTypeArguments) {
|
|
62179
62183
|
if (accessFlags === void 0) { accessFlags = 0 /* None */; }
|
|
@@ -72285,7 +72289,7 @@ var ts;
|
|
|
72285
72289
|
if (result) {
|
|
72286
72290
|
return result;
|
|
72287
72291
|
}
|
|
72288
|
-
if (!(contextFlags & 8 /* SkipBindingPatterns */) && ts.isBindingPattern(declaration.name)
|
|
72292
|
+
if (!(contextFlags & 8 /* SkipBindingPatterns */) && ts.isBindingPattern(declaration.name) && declaration.name.elements.length > 0) {
|
|
72289
72293
|
return getTypeFromBindingPattern(declaration.name, /*includePatternInType*/ true, /*reportErrors*/ false);
|
|
72290
72294
|
}
|
|
72291
72295
|
}
|
|
@@ -72754,22 +72758,20 @@ var ts;
|
|
|
72754
72758
|
var inferenceContext = getInferenceContext(node);
|
|
72755
72759
|
// If no inferences have been made, nothing is gained from instantiating as type parameters
|
|
72756
72760
|
// would just be replaced with their defaults similar to the apparent type.
|
|
72757
|
-
if (inferenceContext && ts.some(inferenceContext.inferences, hasInferenceCandidates)) {
|
|
72761
|
+
if (inferenceContext && contextFlags & 1 /* Signature */ && ts.some(inferenceContext.inferences, hasInferenceCandidates)) {
|
|
72758
72762
|
// For contextual signatures we incorporate all inferences made so far, e.g. from return
|
|
72759
72763
|
// types as well as arguments to the left in a function call.
|
|
72760
|
-
|
|
72761
|
-
|
|
72762
|
-
|
|
72764
|
+
return instantiateInstantiableTypes(contextualType, inferenceContext.nonFixingMapper);
|
|
72765
|
+
}
|
|
72766
|
+
if (inferenceContext === null || inferenceContext === void 0 ? void 0 : inferenceContext.returnMapper) {
|
|
72763
72767
|
// For other purposes (e.g. determining whether to produce literal types) we only
|
|
72764
72768
|
// incorporate inferences made from the return type in a function call. We remove
|
|
72765
72769
|
// the 'boolean' type from the contextual type such that contextually typed boolean
|
|
72766
72770
|
// literals actually end up widening to 'boolean' (see #48363).
|
|
72767
|
-
|
|
72768
|
-
|
|
72769
|
-
|
|
72770
|
-
|
|
72771
|
-
type;
|
|
72772
|
-
}
|
|
72771
|
+
var type = instantiateInstantiableTypes(contextualType, inferenceContext.returnMapper);
|
|
72772
|
+
return type.flags & 1048576 /* Union */ && containsType(type.types, regularFalseType) && containsType(type.types, regularTrueType) ?
|
|
72773
|
+
filterType(type, function (t) { return t !== regularFalseType && t !== regularTrueType; }) :
|
|
72774
|
+
type;
|
|
72773
72775
|
}
|
|
72774
72776
|
}
|
|
72775
72777
|
return contextualType;
|
|
@@ -75303,29 +75305,43 @@ var ts;
|
|
|
75303
75305
|
// 'let f: (x: string) => number = wrap(s => s.length)', we infer from the declared type of 'f' to the
|
|
75304
75306
|
// return type of 'wrap'.
|
|
75305
75307
|
if (node.kind !== 165 /* Decorator */) {
|
|
75306
|
-
var
|
|
75308
|
+
var skipBindingPatterns = ts.every(signature.typeParameters, function (p) { return !!getDefaultFromTypeParameter(p); });
|
|
75309
|
+
var contextualType = getContextualType(node, skipBindingPatterns ? 8 /* SkipBindingPatterns */ : 0 /* None */);
|
|
75307
75310
|
if (contextualType) {
|
|
75308
75311
|
var inferenceTargetType = getReturnTypeOfSignature(signature);
|
|
75309
75312
|
if (couldContainTypeVariables(inferenceTargetType)) {
|
|
75310
|
-
// We clone the inference context to avoid disturbing a resolution in progress for an
|
|
75311
|
-
// outer call expression. Effectively we just want a snapshot of whatever has been
|
|
75312
|
-
// inferred for any outer call expression so far.
|
|
75313
75313
|
var outerContext = getInferenceContext(node);
|
|
75314
|
-
var
|
|
75315
|
-
|
|
75316
|
-
//
|
|
75317
|
-
//
|
|
75318
|
-
//
|
|
75319
|
-
//
|
|
75320
|
-
// declare function
|
|
75321
|
-
// const
|
|
75322
|
-
//
|
|
75323
|
-
|
|
75324
|
-
|
|
75325
|
-
|
|
75326
|
-
|
|
75327
|
-
|
|
75328
|
-
|
|
75314
|
+
var isFromBindingPattern = !skipBindingPatterns && getContextualType(node, 8 /* SkipBindingPatterns */) !== contextualType;
|
|
75315
|
+
// A return type inference from a binding pattern can be used in instantiating the contextual
|
|
75316
|
+
// type of an argument later in inference, but cannot stand on its own as the final return type.
|
|
75317
|
+
// It is incorporated into `context.returnMapper` which is used in `instantiateContextualType`,
|
|
75318
|
+
// but doesn't need to go into `context.inferences`. This allows a an array binding pattern to
|
|
75319
|
+
// produce a tuple for `T` in
|
|
75320
|
+
// declare function f<T>(cb: () => T): T;
|
|
75321
|
+
// const [e1, e2, e3] = f(() => [1, "hi", true]);
|
|
75322
|
+
// but does not produce any inference for `T` in
|
|
75323
|
+
// declare function f<T>(): T;
|
|
75324
|
+
// const [e1, e2, e3] = f();
|
|
75325
|
+
if (!isFromBindingPattern) {
|
|
75326
|
+
// We clone the inference context to avoid disturbing a resolution in progress for an
|
|
75327
|
+
// outer call expression. Effectively we just want a snapshot of whatever has been
|
|
75328
|
+
// inferred for any outer call expression so far.
|
|
75329
|
+
var outerMapper = getMapperFromContext(cloneInferenceContext(outerContext, 1 /* NoDefault */));
|
|
75330
|
+
var instantiatedType = instantiateType(contextualType, outerMapper);
|
|
75331
|
+
// If the contextual type is a generic function type with a single call signature, we
|
|
75332
|
+
// instantiate the type with its own type parameters and type arguments. This ensures that
|
|
75333
|
+
// the type parameters are not erased to type any during type inference such that they can
|
|
75334
|
+
// be inferred as actual types from the contextual type. For example:
|
|
75335
|
+
// declare function arrayMap<T, U>(f: (x: T) => U): (a: T[]) => U[];
|
|
75336
|
+
// const boxElements: <A>(a: A[]) => { value: A }[] = arrayMap(value => ({ value }));
|
|
75337
|
+
// Above, the type of the 'value' parameter is inferred to be 'A'.
|
|
75338
|
+
var contextualSignature = getSingleCallSignature(instantiatedType);
|
|
75339
|
+
var inferenceSourceType = contextualSignature && contextualSignature.typeParameters ?
|
|
75340
|
+
getOrCreateTypeFromSignature(getSignatureInstantiationWithoutFillingInTypeArguments(contextualSignature, contextualSignature.typeParameters)) :
|
|
75341
|
+
instantiatedType;
|
|
75342
|
+
// Inferences made from return types have lower priority than all other inferences.
|
|
75343
|
+
inferTypes(context.inferences, inferenceSourceType, inferenceTargetType, 128 /* ReturnType */);
|
|
75344
|
+
}
|
|
75329
75345
|
// Create a type mapper for instantiating generic contextual types using the inferences made
|
|
75330
75346
|
// from the return type. We need a separate inference pass here because (a) instantiation of
|
|
75331
75347
|
// the source type uses the outer context's return mapper (which excludes inferences made from
|
|
@@ -107250,7 +107266,7 @@ var ts;
|
|
|
107250
107266
|
// Though an error in es2020 modules, in node-flavor es2020 modules, we can helpfully transform this to a synthetic `require` call
|
|
107251
107267
|
// To give easy access to a synchronous `require` in node-flavor esm. We do the transform even in scenarios where we error, but `import.meta.url`
|
|
107252
107268
|
// is available, just because the output is reasonable for a node-like runtime.
|
|
107253
|
-
return ts.
|
|
107269
|
+
return ts.getEmitModuleKind(compilerOptions) >= ts.ModuleKind.Node16 ? visitImportEqualsDeclaration(node) : undefined;
|
|
107254
107270
|
case 271 /* ExportAssignment */:
|
|
107255
107271
|
return visitExportAssignment(node);
|
|
107256
107272
|
case 272 /* ExportDeclaration */:
|
|
@@ -123624,6 +123640,7 @@ var ts;
|
|
|
123624
123640
|
}
|
|
123625
123641
|
function reloadFileNamesFromConfigFile() {
|
|
123626
123642
|
writeLog("Reloading new file names and options");
|
|
123643
|
+
reloadLevel = ts.ConfigFileProgramReloadLevel.None;
|
|
123627
123644
|
rootFileNames = ts.getFileNamesFromConfigSpecs(compilerOptions.configFile.configFileSpecs, ts.getNormalizedAbsolutePath(ts.getDirectoryPath(configFileName), currentDirectory), compilerOptions, parseConfigFileHost, extraFileExtensions);
|
|
123628
123645
|
if (ts.updateErrorForNoInputFiles(rootFileNames, ts.getNormalizedAbsolutePath(configFileName, currentDirectory), compilerOptions.configFile.configFileSpecs, configFileParsingDiagnostics, canConfigFileJsonReportNoInputFiles)) {
|
|
123629
123646
|
hasChangedConfigFileParsingErrors = true;
|
|
@@ -124081,7 +124098,6 @@ var ts;
|
|
|
124081
124098
|
allProjectBuildPending: true,
|
|
124082
124099
|
needsSummary: true,
|
|
124083
124100
|
watchAllProjectsPending: watch,
|
|
124084
|
-
currentInvalidatedProject: undefined,
|
|
124085
124101
|
// Watch state
|
|
124086
124102
|
watch: watch,
|
|
124087
124103
|
allWatchedWildcardDirectories: new ts.Map(),
|
|
@@ -124314,7 +124330,6 @@ var ts;
|
|
|
124314
124330
|
})(InvalidatedProjectKind = ts.InvalidatedProjectKind || (ts.InvalidatedProjectKind = {}));
|
|
124315
124331
|
function doneInvalidatedProject(state, projectPath) {
|
|
124316
124332
|
state.projectPendingBuild.delete(projectPath);
|
|
124317
|
-
state.currentInvalidatedProject = undefined;
|
|
124318
124333
|
return state.diagnostics.has(projectPath) ?
|
|
124319
124334
|
ts.ExitStatus.DiagnosticsPresent_OutputsSkipped :
|
|
124320
124335
|
ts.ExitStatus.Success;
|
|
@@ -124665,17 +124680,11 @@ var ts;
|
|
|
124665
124680
|
!!ts.getConfigFileParsingDiagnostics(config).length ||
|
|
124666
124681
|
!ts.isIncrementalCompilation(config.options);
|
|
124667
124682
|
}
|
|
124668
|
-
function
|
|
124683
|
+
function getNextInvalidatedProjectCreateInfo(state, buildOrder, reportQueue) {
|
|
124669
124684
|
if (!state.projectPendingBuild.size)
|
|
124670
124685
|
return undefined;
|
|
124671
124686
|
if (isCircularBuildOrder(buildOrder))
|
|
124672
124687
|
return undefined;
|
|
124673
|
-
if (state.currentInvalidatedProject) {
|
|
124674
|
-
// Only if same buildOrder the currentInvalidated project can be sent again
|
|
124675
|
-
return ts.arrayIsEqualTo(state.currentInvalidatedProject.buildOrder, buildOrder) ?
|
|
124676
|
-
state.currentInvalidatedProject :
|
|
124677
|
-
undefined;
|
|
124678
|
-
}
|
|
124679
124688
|
var options = state.options, projectPendingBuild = state.projectPendingBuild;
|
|
124680
124689
|
for (var projectIndex = 0; projectIndex < buildOrder.length; projectIndex++) {
|
|
124681
124690
|
var project = buildOrder[projectIndex];
|
|
@@ -124708,9 +124717,9 @@ var ts;
|
|
|
124708
124717
|
watchPackageJsonFiles(state, project, projectPath, config);
|
|
124709
124718
|
}
|
|
124710
124719
|
var status = getUpToDateStatus(state, config, projectPath);
|
|
124711
|
-
verboseReportProjectStatus(state, project, status);
|
|
124712
124720
|
if (!options.force) {
|
|
124713
124721
|
if (status.type === ts.UpToDateStatusType.UpToDate) {
|
|
124722
|
+
verboseReportProjectStatus(state, project, status);
|
|
124714
124723
|
reportAndStoreErrors(state, projectPath, ts.getConfigFileParsingDiagnostics(config));
|
|
124715
124724
|
projectPendingBuild.delete(projectPath);
|
|
124716
124725
|
// Up to date, skip
|
|
@@ -124722,10 +124731,18 @@ var ts;
|
|
|
124722
124731
|
}
|
|
124723
124732
|
if (status.type === ts.UpToDateStatusType.UpToDateWithUpstreamTypes) {
|
|
124724
124733
|
reportAndStoreErrors(state, projectPath, ts.getConfigFileParsingDiagnostics(config));
|
|
124725
|
-
return
|
|
124734
|
+
return {
|
|
124735
|
+
kind: InvalidatedProjectKind.UpdateOutputFileStamps,
|
|
124736
|
+
status: status,
|
|
124737
|
+
project: project,
|
|
124738
|
+
projectPath: projectPath,
|
|
124739
|
+
projectIndex: projectIndex,
|
|
124740
|
+
config: config
|
|
124741
|
+
};
|
|
124726
124742
|
}
|
|
124727
124743
|
}
|
|
124728
124744
|
if (status.type === ts.UpToDateStatusType.UpstreamBlocked) {
|
|
124745
|
+
verboseReportProjectStatus(state, project, status);
|
|
124729
124746
|
reportAndStoreErrors(state, projectPath, ts.getConfigFileParsingDiagnostics(config));
|
|
124730
124747
|
projectPendingBuild.delete(projectPath);
|
|
124731
124748
|
if (options.verbose) {
|
|
@@ -124736,17 +124753,37 @@ var ts;
|
|
|
124736
124753
|
continue;
|
|
124737
124754
|
}
|
|
124738
124755
|
if (status.type === ts.UpToDateStatusType.ContainerOnly) {
|
|
124756
|
+
verboseReportProjectStatus(state, project, status);
|
|
124739
124757
|
reportAndStoreErrors(state, projectPath, ts.getConfigFileParsingDiagnostics(config));
|
|
124740
124758
|
projectPendingBuild.delete(projectPath);
|
|
124741
124759
|
// Do nothing
|
|
124742
124760
|
continue;
|
|
124743
124761
|
}
|
|
124744
|
-
return
|
|
124745
|
-
|
|
124746
|
-
|
|
124762
|
+
return {
|
|
124763
|
+
kind: needsBuild(state, status, config) ?
|
|
124764
|
+
InvalidatedProjectKind.Build :
|
|
124765
|
+
InvalidatedProjectKind.UpdateBundle,
|
|
124766
|
+
status: status,
|
|
124767
|
+
project: project,
|
|
124768
|
+
projectPath: projectPath,
|
|
124769
|
+
projectIndex: projectIndex,
|
|
124770
|
+
config: config,
|
|
124771
|
+
};
|
|
124747
124772
|
}
|
|
124748
124773
|
return undefined;
|
|
124749
124774
|
}
|
|
124775
|
+
function createInvalidatedProjectWithInfo(state, info, buildOrder) {
|
|
124776
|
+
verboseReportProjectStatus(state, info.project, info.status);
|
|
124777
|
+
return info.kind !== InvalidatedProjectKind.UpdateOutputFileStamps ?
|
|
124778
|
+
createBuildOrUpdateInvalidedProject(info.kind, state, info.project, info.projectPath, info.projectIndex, info.config, buildOrder) :
|
|
124779
|
+
createUpdateOutputFileStampsProject(state, info.project, info.projectPath, info.config, buildOrder);
|
|
124780
|
+
}
|
|
124781
|
+
function getNextInvalidatedProject(state, buildOrder, reportQueue) {
|
|
124782
|
+
var info = getNextInvalidatedProjectCreateInfo(state, buildOrder, reportQueue);
|
|
124783
|
+
if (!info)
|
|
124784
|
+
return info;
|
|
124785
|
+
return createInvalidatedProjectWithInfo(state, info, buildOrder);
|
|
124786
|
+
}
|
|
124750
124787
|
function listEmittedFile(_a, proj, file) {
|
|
124751
124788
|
var write = _a.write;
|
|
124752
124789
|
if (write && proj.options.listEmittedFiles) {
|
|
@@ -125187,9 +125224,9 @@ var ts;
|
|
|
125187
125224
|
function invalidateProjectAndScheduleBuilds(state, resolvedPath, reloadLevel) {
|
|
125188
125225
|
state.reportFileChangeDetected = true;
|
|
125189
125226
|
invalidateProject(state, resolvedPath, reloadLevel);
|
|
125190
|
-
scheduleBuildInvalidatedProject(state);
|
|
125227
|
+
scheduleBuildInvalidatedProject(state, 250, /*changeDetected*/ true);
|
|
125191
125228
|
}
|
|
125192
|
-
function scheduleBuildInvalidatedProject(state) {
|
|
125229
|
+
function scheduleBuildInvalidatedProject(state, time, changeDetected) {
|
|
125193
125230
|
var hostWithWatch = state.hostWithWatch;
|
|
125194
125231
|
if (!hostWithWatch.setTimeout || !hostWithWatch.clearTimeout) {
|
|
125195
125232
|
return;
|
|
@@ -125197,25 +125234,38 @@ var ts;
|
|
|
125197
125234
|
if (state.timerToBuildInvalidatedProject) {
|
|
125198
125235
|
hostWithWatch.clearTimeout(state.timerToBuildInvalidatedProject);
|
|
125199
125236
|
}
|
|
125200
|
-
state.timerToBuildInvalidatedProject = hostWithWatch.setTimeout(buildNextInvalidatedProject,
|
|
125237
|
+
state.timerToBuildInvalidatedProject = hostWithWatch.setTimeout(buildNextInvalidatedProject, time, state, changeDetected);
|
|
125201
125238
|
}
|
|
125202
|
-
function buildNextInvalidatedProject(state) {
|
|
125239
|
+
function buildNextInvalidatedProject(state, changeDetected) {
|
|
125203
125240
|
state.timerToBuildInvalidatedProject = undefined;
|
|
125204
125241
|
if (state.reportFileChangeDetected) {
|
|
125205
125242
|
state.reportFileChangeDetected = false;
|
|
125206
125243
|
state.projectErrorsReported.clear();
|
|
125207
125244
|
reportWatchStatus(state, ts.Diagnostics.File_change_detected_Starting_incremental_compilation);
|
|
125208
125245
|
}
|
|
125246
|
+
var projectsBuilt = 0;
|
|
125209
125247
|
var buildOrder = getBuildOrder(state);
|
|
125210
125248
|
var invalidatedProject = getNextInvalidatedProject(state, buildOrder, /*reportQueue*/ false);
|
|
125211
125249
|
if (invalidatedProject) {
|
|
125212
125250
|
invalidatedProject.done();
|
|
125213
|
-
|
|
125214
|
-
|
|
125215
|
-
|
|
125216
|
-
|
|
125251
|
+
projectsBuilt++;
|
|
125252
|
+
while (state.projectPendingBuild.size) {
|
|
125253
|
+
// If already scheduled, skip
|
|
125254
|
+
if (state.timerToBuildInvalidatedProject)
|
|
125255
|
+
return;
|
|
125256
|
+
// Before scheduling check if the next project needs build
|
|
125257
|
+
var info = getNextInvalidatedProjectCreateInfo(state, buildOrder, /*reportQueue*/ false);
|
|
125258
|
+
if (!info)
|
|
125259
|
+
break; // Nothing to build any more
|
|
125260
|
+
if (info.kind !== InvalidatedProjectKind.UpdateOutputFileStamps && (changeDetected || projectsBuilt === 5)) {
|
|
125261
|
+
// Schedule next project for build
|
|
125262
|
+
scheduleBuildInvalidatedProject(state, 100, /*changeDetected*/ false);
|
|
125263
|
+
return;
|
|
125217
125264
|
}
|
|
125218
|
-
|
|
125265
|
+
var project = createInvalidatedProjectWithInfo(state, info, buildOrder);
|
|
125266
|
+
project.done();
|
|
125267
|
+
if (info.kind !== InvalidatedProjectKind.UpdateOutputFileStamps)
|
|
125268
|
+
projectsBuilt++;
|
|
125219
125269
|
}
|
|
125220
125270
|
}
|
|
125221
125271
|
disableCache(state);
|
|
@@ -125319,8 +125369,6 @@ var ts;
|
|
|
125319
125369
|
return getUpToDateStatus(state, parseConfigFile(state, configFileName, configFilePath), configFilePath);
|
|
125320
125370
|
},
|
|
125321
125371
|
invalidateProject: function (configFilePath, reloadLevel) { return invalidateProject(state, configFilePath, reloadLevel || ts.ConfigFileProgramReloadLevel.None); },
|
|
125322
|
-
buildNextInvalidatedProject: function () { return buildNextInvalidatedProject(state); },
|
|
125323
|
-
getAllParsedConfigs: function () { return ts.arrayFrom(ts.mapDefinedIterator(state.configFileCache.values(), function (config) { return isParsedCommandLine(config) ? config : undefined; })); },
|
|
125324
125372
|
close: function () { return stopWatching(state); },
|
|
125325
125373
|
};
|
|
125326
125374
|
}
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "typescript",
|
|
3
3
|
"author": "Microsoft Corp.",
|
|
4
4
|
"homepage": "https://www.typescriptlang.org/",
|
|
5
|
-
"version": "4.8.0-dev.
|
|
5
|
+
"version": "4.8.0-dev.20220526",
|
|
6
6
|
"license": "Apache-2.0",
|
|
7
7
|
"description": "TypeScript is a language for application scale JavaScript development",
|
|
8
8
|
"keywords": [
|