@typescript-deploys/pr-build 4.8.0-pr-49285-33 → 4.8.0-pr-49156-9

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 CHANGED
@@ -89075,12 +89075,6 @@ var ts;
89075
89075
  })(ts || (ts = {}));
89076
89076
  var ts;
89077
89077
  (function (ts) {
89078
- function getDeclarationDiagnostics(host, resolver, file) {
89079
- var compilerOptions = host.getCompilerOptions();
89080
- var result = ts.transformNodes(resolver, host, ts.factory, compilerOptions, file ? [file] : ts.filter(host.getSourceFiles(), ts.isSourceFileNotJson), [transformDeclarations], false);
89081
- return result.diagnostics;
89082
- }
89083
- ts.getDeclarationDiagnostics = getDeclarationDiagnostics;
89084
89078
  function hasInternalAnnotation(range, currentSourceFile) {
89085
89079
  var comment = currentSourceFile.text.substring(range.pos, range.end);
89086
89080
  return ts.stringContains(comment, "@internal");
@@ -91001,6 +90995,13 @@ var ts;
91001
90995
  return ts.Debug.fail("project " + configFile.options.configFilePath + " expected to have at least one output");
91002
90996
  }
91003
90997
  ts.getFirstProjectOutput = getFirstProjectOutput;
90998
+ function getCacheDtsEmitResultKey(sourceFileOrBundle, options) {
90999
+ return ts.isSourceFile(sourceFileOrBundle) ? sourceFileOrBundle.resolvedPath : ts.outFile(options);
91000
+ }
91001
+ ts.getCacheDtsEmitResultKey = getCacheDtsEmitResultKey;
91002
+ function isForceDtsEmitResult(result) {
91003
+ return !!result && !result.transformed;
91004
+ }
91004
91005
  function emitFiles(resolver, host, targetSourceFile, _a, emitOnlyDtsFiles, onlyBuildInfo, forceDtsEmit) {
91005
91006
  var scriptTransformers = _a.scriptTransformers, declarationTransformers = _a.declarationTransformers;
91006
91007
  var compilerOptions = host.getCompilerOptions();
@@ -91012,7 +91013,6 @@ var ts;
91012
91013
  var _b = ts.performance.createTimer("printTime", "beforePrint", "afterPrint"), enter = _b.enter, exit = _b.exit;
91013
91014
  var bundleBuildInfo;
91014
91015
  var emitSkipped = false;
91015
- var exportedModulesFromDeclarationEmit;
91016
91016
  enter();
91017
91017
  forEachEmittedFile(host, emitSourceFileOrBundle, ts.getSourceFilesToEmit(host, targetSourceFile, forceDtsEmit), forceDtsEmit, onlyBuildInfo, !targetSourceFile);
91018
91018
  exit();
@@ -91021,7 +91021,6 @@ var ts;
91021
91021
  diagnostics: emitterDiagnostics.getDiagnostics(),
91022
91022
  emittedFiles: emittedFilesList,
91023
91023
  sourceMaps: sourceMapDataList,
91024
- exportedModulesFromDeclarationEmit: exportedModulesFromDeclarationEmit
91025
91024
  };
91026
91025
  function emitSourceFileOrBundle(_a, sourceFileOrBundle) {
91027
91026
  var jsFilePath = _a.jsFilePath, sourceMapFilePath = _a.sourceMapFilePath, declarationFilePath = _a.declarationFilePath, declarationMapPath = _a.declarationMapPath, buildInfoPath = _a.buildInfoPath;
@@ -91105,13 +91104,13 @@ var ts;
91105
91104
  isEmitNotificationEnabled: transform.isEmitNotificationEnabled,
91106
91105
  substituteNode: transform.substituteNode,
91107
91106
  });
91108
- ts.Debug.assert(transform.transformed.length === 1, "Should only see one output from the transform");
91109
- printSourceFileOrBundle(jsFilePath, sourceMapFilePath, transform.transformed[0], printer, compilerOptions);
91107
+ printSourceFileOrBundle(jsFilePath, sourceMapFilePath, transform, printer, compilerOptions);
91110
91108
  transform.dispose();
91111
91109
  if (bundleBuildInfo)
91112
91110
  bundleBuildInfo.js = printer.bundleFileInfo;
91113
91111
  }
91114
91112
  function emitDeclarationFileOrBundle(sourceFileOrBundle, declarationFilePath, declarationMapPath, relativeToBuildInfo) {
91113
+ var _a, _b;
91115
91114
  if (!sourceFileOrBundle)
91116
91115
  return;
91117
91116
  if (!declarationFilePath) {
@@ -91122,13 +91121,39 @@ var ts;
91122
91121
  var sourceFiles = ts.isSourceFile(sourceFileOrBundle) ? [sourceFileOrBundle] : sourceFileOrBundle.sourceFiles;
91123
91122
  var filesForEmit = forceDtsEmit ? sourceFiles : ts.filter(sourceFiles, ts.isSourceFileNotJson);
91124
91123
  var inputListOrBundle = ts.outFile(compilerOptions) ? [ts.factory.createBundle(filesForEmit, !ts.isSourceFile(sourceFileOrBundle) ? sourceFileOrBundle.prepends : undefined)] : filesForEmit;
91125
- if (emitOnlyDtsFiles && !ts.getEmitDeclarations(compilerOptions)) {
91124
+ var key = getCacheDtsEmitResultKey(sourceFileOrBundle, compilerOptions);
91125
+ var cache = host.getDtsEmitResultCache();
91126
+ var existing = declarationTransformers.length === 1 ? cache.get(key) : undefined;
91127
+ if (isForceDtsEmitResult(existing)) {
91128
+ if ((_a = existing.diagnostics) === null || _a === void 0 ? void 0 : _a.length) {
91129
+ for (var _c = 0, _d = existing.diagnostics; _c < _d.length; _c++) {
91130
+ var diagnostic = _d[_c];
91131
+ emitterDiagnostics.add(diagnostic);
91132
+ }
91133
+ }
91134
+ var declBlocked_1 = !!((_b = existing.diagnostics) === null || _b === void 0 ? void 0 : _b.length) || !!host.isEmitBlocked(declarationFilePath) || !!compilerOptions.noEmit;
91135
+ emitSkipped = emitSkipped || declBlocked_1;
91136
+ if (!declBlocked_1 || forceDtsEmit) {
91137
+ if (declarationMapPath && !forceDtsEmit) {
91138
+ if (sourceMapDataList && existing.sourceMapData) {
91139
+ sourceMapDataList.push(existing.sourceMapData);
91140
+ }
91141
+ ts.writeFile(host, emitterDiagnostics, declarationMapPath, existing.sourceMap, false, sourceFiles);
91142
+ }
91143
+ ts.writeFile(host, emitterDiagnostics, declarationFilePath, existing.text, !!compilerOptions.emitBOM, filesForEmit, {
91144
+ sourceMapUrlPos: existing.sourceMapUrlPos,
91145
+ exportedModulesFromDeclarationEmit: existing.exportedModulesFromDeclarationEmit,
91146
+ });
91147
+ }
91148
+ return;
91149
+ }
91150
+ if (!existing && emitOnlyDtsFiles && !ts.getEmitDeclarations(compilerOptions)) {
91126
91151
  filesForEmit.forEach(collectLinkedAliases);
91127
91152
  }
91128
- var declarationTransform = ts.transformNodes(resolver, host, ts.factory, compilerOptions, inputListOrBundle, declarationTransformers, false);
91153
+ var declarationTransform = existing || ts.transformNodes(resolver, host, ts.factory, compilerOptions, inputListOrBundle, declarationTransformers, false);
91129
91154
  if (ts.length(declarationTransform.diagnostics)) {
91130
- for (var _a = 0, _b = declarationTransform.diagnostics; _a < _b.length; _a++) {
91131
- var diagnostic = _b[_a];
91155
+ for (var _e = 0, _f = declarationTransform.diagnostics; _e < _f.length; _e++) {
91156
+ var diagnostic = _f[_e];
91132
91157
  emitterDiagnostics.add(diagnostic);
91133
91158
  }
91134
91159
  }
@@ -91138,8 +91163,7 @@ var ts;
91138
91163
  noEmitHelpers: true,
91139
91164
  module: compilerOptions.module,
91140
91165
  target: compilerOptions.target,
91141
- sourceMap: compilerOptions.sourceMap,
91142
- inlineSourceMap: compilerOptions.inlineSourceMap,
91166
+ sourceMap: (!forceDtsEmit || !compilerOptions.noEmit) && compilerOptions.declarationMap,
91143
91167
  extendedDiagnostics: compilerOptions.extendedDiagnostics,
91144
91168
  onlyPrintJsDocStyle: true,
91145
91169
  writeBundleFileInfo: !!bundleBuildInfo,
@@ -91155,17 +91179,12 @@ var ts;
91155
91179
  var declBlocked = (!!declarationTransform.diagnostics && !!declarationTransform.diagnostics.length) || !!host.isEmitBlocked(declarationFilePath) || !!compilerOptions.noEmit;
91156
91180
  emitSkipped = emitSkipped || declBlocked;
91157
91181
  if (!declBlocked || forceDtsEmit) {
91158
- ts.Debug.assert(declarationTransform.transformed.length === 1, "Should only see one output from the decl transform");
91159
- printSourceFileOrBundle(declarationFilePath, declarationMapPath, declarationTransform.transformed[0], declarationPrinter, {
91160
- sourceMap: !forceDtsEmit && compilerOptions.declarationMap,
91182
+ printSourceFileOrBundle(declarationFilePath, declarationMapPath, declarationTransform, declarationPrinter, {
91183
+ sourceMap: printerOptions.sourceMap,
91161
91184
  sourceRoot: compilerOptions.sourceRoot,
91162
91185
  mapRoot: compilerOptions.mapRoot,
91163
91186
  extendedDiagnostics: compilerOptions.extendedDiagnostics,
91164
91187
  });
91165
- if (forceDtsEmit && declarationTransform.transformed[0].kind === 305) {
91166
- var sourceFile = declarationTransform.transformed[0];
91167
- exportedModulesFromDeclarationEmit = sourceFile.exportedModulesFromDeclarationEmit;
91168
- }
91169
91188
  }
91170
91189
  declarationTransform.dispose();
91171
91190
  if (bundleBuildInfo)
@@ -91184,7 +91203,9 @@ var ts;
91184
91203
  }
91185
91204
  ts.forEachChild(node, collectLinkedAliases);
91186
91205
  }
91187
- function printSourceFileOrBundle(jsFilePath, sourceMapFilePath, sourceFileOrBundle, printer, mapOptions) {
91206
+ function printSourceFileOrBundle(jsFilePath, sourceMapFilePath, transform, printer, mapOptions) {
91207
+ ts.Debug.assert(transform.transformed.length === 1, "Should only see one output from the transform");
91208
+ var sourceFileOrBundle = transform.transformed[0];
91188
91209
  var bundle = sourceFileOrBundle.kind === 306 ? sourceFileOrBundle : undefined;
91189
91210
  var sourceFile = sourceFileOrBundle.kind === 305 ? sourceFileOrBundle : undefined;
91190
91211
  var sourceFiles = bundle ? bundle.sourceFiles : [sourceFile];
@@ -91199,9 +91220,11 @@ var ts;
91199
91220
  printer.writeFile(sourceFile, writer, sourceMapGenerator);
91200
91221
  }
91201
91222
  var sourceMapUrlPos;
91223
+ var sourceMap;
91224
+ var sourceMapData;
91202
91225
  if (sourceMapGenerator) {
91203
91226
  if (sourceMapDataList) {
91204
- sourceMapDataList.push({
91227
+ sourceMapDataList.push(sourceMapData = {
91205
91228
  inputSourceFileNames: sourceMapGenerator.getSources(),
91206
91229
  sourceMap: sourceMapGenerator.toJSON()
91207
91230
  });
@@ -91214,8 +91237,9 @@ var ts;
91214
91237
  writer.writeComment("//# " + "sourceMappingURL" + "=" + sourceMappingURL);
91215
91238
  }
91216
91239
  if (sourceMapFilePath) {
91217
- var sourceMap = sourceMapGenerator.toString();
91218
- ts.writeFile(host, emitterDiagnostics, sourceMapFilePath, sourceMap, false, sourceFiles);
91240
+ sourceMap = sourceMapGenerator.toString();
91241
+ if (!forceDtsEmit)
91242
+ ts.writeFile(host, emitterDiagnostics, sourceMapFilePath, sourceMap, false, sourceFiles);
91219
91243
  if (printer.bundleFileInfo)
91220
91244
  printer.bundleFileInfo.mapHash = ts.BuilderState.computeSignature(sourceMap, ts.maybeBind(host, host.createHash));
91221
91245
  }
@@ -91224,9 +91248,23 @@ var ts;
91224
91248
  writer.writeLine();
91225
91249
  }
91226
91250
  var text = writer.getText();
91227
- ts.writeFile(host, emitterDiagnostics, jsFilePath, text, !!compilerOptions.emitBOM, sourceFiles, { sourceMapUrlPos: sourceMapUrlPos });
91251
+ ts.writeFile(host, emitterDiagnostics, jsFilePath, writer.getText(), !!compilerOptions.emitBOM, sourceFiles, {
91252
+ sourceMapUrlPos: sourceMapUrlPos,
91253
+ exportedModulesFromDeclarationEmit: sourceFile === null || sourceFile === void 0 ? void 0 : sourceFile.exportedModulesFromDeclarationEmit,
91254
+ });
91228
91255
  if (printer.bundleFileInfo)
91229
91256
  printer.bundleFileInfo.hash = ts.BuilderState.computeSignature(text, ts.maybeBind(host, host.createHash));
91257
+ if (forceDtsEmit) {
91258
+ var key = getCacheDtsEmitResultKey(sourceFileOrBundle, compilerOptions);
91259
+ host.getDtsEmitResultCache().set(key, {
91260
+ diagnostics: transform.diagnostics,
91261
+ text: writer.getText(),
91262
+ sourceMap: sourceMap,
91263
+ sourceMapData: sourceMapData,
91264
+ sourceMapUrlPos: sourceMapUrlPos,
91265
+ exportedModulesFromDeclarationEmit: sourceFile === null || sourceFile === void 0 ? void 0 : sourceFile.exportedModulesFromDeclarationEmit,
91266
+ });
91267
+ }
91230
91268
  writer.clear();
91231
91269
  }
91232
91270
  function shouldEmitSourceMaps(mapOptions, sourceFileOrBundle) {
@@ -91424,7 +91462,7 @@ var ts;
91424
91462
  var newBuildInfo = data.buildInfo;
91425
91463
  newBuildInfo.program = buildInfo.program;
91426
91464
  if (newBuildInfo.program && changedDtsText !== undefined && config.options.composite) {
91427
- newBuildInfo.program.outSignature = ts.computeSignature(changedDtsText, changedDtsData, createHash);
91465
+ newBuildInfo.program.outSignature = ts.BuilderState.computeSignature(changedDtsText, createHash, changedDtsData);
91428
91466
  newBuildInfo.program.dtsChangeTime = ts.getCurrentTime(host).getTime();
91429
91467
  }
91430
91468
  var _a = buildInfo.bundle, js = _a.js, dts = _a.dts, sourceFiles = _a.sourceFiles;
@@ -91459,6 +91497,7 @@ var ts;
91459
91497
  redirectTargetsMap: ts.createMultiMap(),
91460
91498
  getFileIncludeReasons: ts.notImplemented,
91461
91499
  createHash: createHash,
91500
+ getDtsEmitResultCache: function () { return new ts.Map(); },
91462
91501
  };
91463
91502
  emitFiles(ts.notImplementedResolver, emitHost, undefined, ts.getTransformers(config.options, customTransformers));
91464
91503
  return outputFiles;
@@ -96863,6 +96902,7 @@ var ts;
96863
96902
  var sourceFileToPackageName = new ts.Map();
96864
96903
  var redirectTargetsMap = ts.createMultiMap();
96865
96904
  var usesUriStyleNodeCoreModules = false;
96905
+ var cacheDtsEmitResult;
96866
96906
  var filesByName = new ts.Map();
96867
96907
  var missingFilePaths;
96868
96908
  var filesByNameIgnoreCase = host.useCaseSensitiveFileNames() ? new ts.Map() : undefined;
@@ -97496,6 +97536,7 @@ var ts;
97496
97536
  redirectTargetsMap: redirectTargetsMap,
97497
97537
  getFileIncludeReasons: program.getFileIncludeReasons,
97498
97538
  createHash: ts.maybeBind(host, host.createHash),
97539
+ getDtsEmitResultCache: function () { return cacheDtsEmitResult || (cacheDtsEmitResult = new ts.Map()); },
97499
97540
  };
97500
97541
  }
97501
97542
  function writeFile(fileName, text, writeByteOrderMark, onError, sourceFiles, data) {
@@ -97901,7 +97942,30 @@ var ts;
97901
97942
  function getDeclarationDiagnosticsForFileNoCache(sourceFile, cancellationToken) {
97902
97943
  return runWithCancellationToken(function () {
97903
97944
  var resolver = getTypeChecker().getEmitResolver(sourceFile, cancellationToken);
97904
- return ts.getDeclarationDiagnostics(getEmitHost(ts.noop), resolver, sourceFile) || ts.emptyArray;
97945
+ var emitHost = getEmitHost(ts.noop);
97946
+ if (sourceFile) {
97947
+ if (!ts.outFile(options)) {
97948
+ var existing = cacheDtsEmitResult === null || cacheDtsEmitResult === void 0 ? void 0 : cacheDtsEmitResult.get(sourceFile.resolvedPath);
97949
+ if (existing)
97950
+ return existing.diagnostics || ts.emptyArray;
97951
+ }
97952
+ var result = ts.transformNodes(resolver, emitHost, ts.factory, options, [sourceFile], [ts.transformDeclarations], false);
97953
+ if (!ts.outFile(options)) {
97954
+ (cacheDtsEmitResult || (cacheDtsEmitResult = new ts.Map())).set(sourceFile.resolvedPath, result);
97955
+ }
97956
+ return result.diagnostics || ts.emptyArray;
97957
+ }
97958
+ var diagnostics;
97959
+ ts.forEachEmittedFile(emitHost, function (_emitFileNames, sourceFileOrBundle) {
97960
+ var key = ts.getCacheDtsEmitResultKey(sourceFileOrBundle, options);
97961
+ var existing = cacheDtsEmitResult === null || cacheDtsEmitResult === void 0 ? void 0 : cacheDtsEmitResult.get(key);
97962
+ if (existing)
97963
+ return existing.diagnostics || ts.emptyArray;
97964
+ var result = ts.transformNodes(resolver, emitHost, ts.factory, options, [sourceFileOrBundle], [ts.transformDeclarations], false);
97965
+ diagnostics = ts.addRange(diagnostics, result.diagnostics);
97966
+ (cacheDtsEmitResult || (cacheDtsEmitResult = new ts.Map())).set(key, result);
97967
+ });
97968
+ return diagnostics || ts.emptyArray;
97905
97969
  });
97906
97970
  }
97907
97971
  function getAndCacheDiagnostics(sourceFile, cancellationToken, cache, getDiagnostics) {
@@ -99390,8 +99454,8 @@ var ts;
99390
99454
  (function (ts) {
99391
99455
  function getFileEmitOutput(program, sourceFile, emitOnlyDtsFiles, cancellationToken, customTransformers, forceDtsEmit) {
99392
99456
  var outputFiles = [];
99393
- var _a = program.emit(sourceFile, writeFile, cancellationToken, emitOnlyDtsFiles, customTransformers, forceDtsEmit), emitSkipped = _a.emitSkipped, diagnostics = _a.diagnostics, exportedModulesFromDeclarationEmit = _a.exportedModulesFromDeclarationEmit;
99394
- return { outputFiles: outputFiles, emitSkipped: emitSkipped, diagnostics: diagnostics, exportedModulesFromDeclarationEmit: exportedModulesFromDeclarationEmit };
99457
+ var _a = program.emit(sourceFile, writeFile, cancellationToken, emitOnlyDtsFiles, customTransformers, forceDtsEmit), emitSkipped = _a.emitSkipped, diagnostics = _a.diagnostics;
99458
+ return { outputFiles: outputFiles, emitSkipped: emitSkipped, diagnostics: diagnostics };
99395
99459
  function writeFile(fileName, text, writeByteOrderMark) {
99396
99460
  outputFiles.push({ name: fileName, writeByteOrderMark: writeByteOrderMark, text: text });
99397
99461
  }
@@ -99606,6 +99670,10 @@ var ts;
99606
99670
  (state.hasCalledUpdateShapeSignature || (state.hasCalledUpdateShapeSignature = new ts.Set())).add(path);
99607
99671
  }
99608
99672
  BuilderState.updateSignatureOfFile = updateSignatureOfFile;
99673
+ function computeSignature(text, computeHash, data) {
99674
+ return (computeHash || ts.generateDjb2Hash)((data === null || data === void 0 ? void 0 : data.sourceMapUrlPos) !== undefined ? text.substring(0, data.sourceMapUrlPos) : text);
99675
+ }
99676
+ BuilderState.computeSignature = computeSignature;
99609
99677
  function updateShapeSignature(state, programOfThisState, sourceFile, cancellationToken, computeHash, useFileVersionAsSignature) {
99610
99678
  var _a;
99611
99679
  if (useFileVersionAsSignature === void 0) { useFileVersionAsSignature = state.useFileVersionAsSignature; }
@@ -99615,15 +99683,14 @@ var ts;
99615
99683
  var prevSignature = info.signature;
99616
99684
  var latestSignature;
99617
99685
  if (!sourceFile.isDeclarationFile && !useFileVersionAsSignature) {
99618
- var emitOutput_1 = getFileEmitOutput(programOfThisState, sourceFile, true, cancellationToken, undefined, true);
99619
- var firstDts_1 = ts.firstOrUndefined(emitOutput_1.outputFiles);
99620
- if (firstDts_1) {
99621
- ts.Debug.assert(ts.isDeclarationFileName(firstDts_1.name), "File extension for signature expected to be dts", function () { return "Found: " + ts.getAnyExtensionFromPath(firstDts_1.name) + " for " + firstDts_1.name + ":: All output files: " + JSON.stringify(emitOutput_1.outputFiles.map(function (f) { return f.name; })); });
99622
- latestSignature = computeSignature(firstDts_1.text, computeHash);
99686
+ programOfThisState.emit(sourceFile, function (fileName, text, _writeByteOrderMark, _onError, _sourceFiles, data) {
99687
+ ts.Debug.assert(ts.isDeclarationFileName(fileName), "File extension for signature expected to be dts");
99688
+ ts.Debug.assert(latestSignature === undefined, "Only one file should be set");
99689
+ latestSignature = computeSignature(text, computeHash, data);
99623
99690
  if (latestSignature !== prevSignature) {
99624
- updateExportedModules(state, sourceFile, emitOutput_1.exportedModulesFromDeclarationEmit);
99691
+ updateExportedModules(state, sourceFile, data === null || data === void 0 ? void 0 : data.exportedModulesFromDeclarationEmit);
99625
99692
  }
99626
- }
99693
+ }, cancellationToken, true, undefined, true);
99627
99694
  }
99628
99695
  if (latestSignature === undefined) {
99629
99696
  latestSignature = sourceFile.version;
@@ -99644,10 +99711,6 @@ var ts;
99644
99711
  return latestSignature !== prevSignature;
99645
99712
  }
99646
99713
  BuilderState.updateShapeSignature = updateShapeSignature;
99647
- function computeSignature(text, computeHash) {
99648
- return (computeHash || ts.generateDjb2Hash)(text);
99649
- }
99650
- BuilderState.computeSignature = computeSignature;
99651
99714
  function updateExportedModules(state, sourceFile, exportedModulesFromDeclarationEmit) {
99652
99715
  if (!state.exportedModulesMap)
99653
99716
  return;
@@ -100380,10 +100443,6 @@ var ts;
100380
100443
  return { host: host, newProgram: newProgram, oldProgram: oldProgram, configFileParsingDiagnostics: configFileParsingDiagnostics || ts.emptyArray };
100381
100444
  }
100382
100445
  ts.getBuilderCreationParameters = getBuilderCreationParameters;
100383
- function computeSignature(text, data, computeHash) {
100384
- return ts.BuilderState.computeSignature((data === null || data === void 0 ? void 0 : data.sourceMapUrlPos) !== undefined ? text.substring(0, data.sourceMapUrlPos) : text, computeHash);
100385
- }
100386
- ts.computeSignature = computeSignature;
100387
100446
  function createBuilderProgram(kind, _a) {
100388
100447
  var newProgram = _a.newProgram, host = _a.host, oldProgram = _a.oldProgram, configFileParsingDiagnostics = _a.configFileParsingDiagnostics;
100389
100448
  var oldState = oldProgram && oldProgram.getState();
@@ -100467,7 +100526,7 @@ var ts;
100467
100526
  var file = sourceFiles[0];
100468
100527
  var info = state.fileInfos.get(file.resolvedPath);
100469
100528
  if (info.signature === file.version) {
100470
- newSignature = computeSignature(text, data, computeHash);
100529
+ newSignature = ts.BuilderState.computeSignature(text, computeHash, data);
100471
100530
  if (newSignature !== file.version) {
100472
100531
  if (host.storeFilesChangingSignatureDuringEmit)
100473
100532
  (state.filesChangingSignature || (state.filesChangingSignature = new ts.Set())).add(file.resolvedPath);
@@ -100489,7 +100548,7 @@ var ts;
100489
100548
  if (state.compilerOptions.composite) {
100490
100549
  var filePath = sourceFiles[0].resolvedPath;
100491
100550
  var oldSignature = (_c = state.emitSignatures) === null || _c === void 0 ? void 0 : _c.get(filePath);
100492
- newSignature || (newSignature = computeSignature(text, data, computeHash));
100551
+ newSignature || (newSignature = ts.BuilderState.computeSignature(text, computeHash, data));
100493
100552
  if (newSignature !== oldSignature) {
100494
100553
  (state.emitSignatures || (state.emitSignatures = new ts.Map())).set(filePath, newSignature);
100495
100554
  state.hasChangedEmitSignature = true;
@@ -100497,7 +100556,7 @@ var ts;
100497
100556
  }
100498
100557
  }
100499
100558
  else if (state.compilerOptions.composite) {
100500
- var newSignature = computeSignature(text, data, computeHash);
100559
+ var newSignature = ts.BuilderState.computeSignature(text, computeHash, data);
100501
100560
  if (newSignature !== state.outSignature) {
100502
100561
  state.outSignature = newSignature;
100503
100562
  state.hasChangedEmitSignature = true;