@typescript-deploys/pr-build 5.3.0-pr-55452-7 → 5.3.0-pr-55438-2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -54,7 +54,7 @@ var path = __toESM(require("path"));
54
54
 
55
55
  // src/compiler/corePublic.ts
56
56
  var versionMajorMinor = "5.3";
57
- var version = `${versionMajorMinor}.0-insiders.20230825`;
57
+ var version = `${versionMajorMinor}.0-insiders.20230829`;
58
58
 
59
59
  // src/compiler/core.ts
60
60
  var emptyArray = [];
@@ -569,10 +569,7 @@ function getStringComparer(ignoreCase) {
569
569
  return ignoreCase ? compareStringsCaseInsensitive : compareStringsCaseSensitive;
570
570
  }
571
571
  var createUIStringComparer = (() => {
572
- let defaultComparer;
573
- let enUSComparer;
574
- const stringComparerFactory = getStringComparerFactory();
575
- return createStringComparer;
572
+ return createIntlCollatorStringComparer;
576
573
  function compareWithCallback(a, b, comparer) {
577
574
  if (a === b)
578
575
  return 0 /* EqualTo */;
@@ -587,41 +584,6 @@ var createUIStringComparer = (() => {
587
584
  const comparer = new Intl.Collator(locale, { usage: "sort", sensitivity: "variant" }).compare;
588
585
  return (a, b) => compareWithCallback(a, b, comparer);
589
586
  }
590
- function createLocaleCompareStringComparer(locale) {
591
- if (locale !== void 0)
592
- return createFallbackStringComparer();
593
- return (a, b) => compareWithCallback(a, b, compareStrings);
594
- function compareStrings(a, b) {
595
- return a.localeCompare(b);
596
- }
597
- }
598
- function createFallbackStringComparer() {
599
- return (a, b) => compareWithCallback(a, b, compareDictionaryOrder);
600
- function compareDictionaryOrder(a, b) {
601
- return compareStrings(a.toUpperCase(), b.toUpperCase()) || compareStrings(a, b);
602
- }
603
- function compareStrings(a, b) {
604
- return a < b ? -1 /* LessThan */ : a > b ? 1 /* GreaterThan */ : 0 /* EqualTo */;
605
- }
606
- }
607
- function getStringComparerFactory() {
608
- if (typeof Intl === "object" && typeof Intl.Collator === "function") {
609
- return createIntlCollatorStringComparer;
610
- }
611
- if (typeof String.prototype.localeCompare === "function" && typeof String.prototype.toLocaleUpperCase === "function" && "a".localeCompare("B") < 0) {
612
- return createLocaleCompareStringComparer;
613
- }
614
- return createFallbackStringComparer;
615
- }
616
- function createStringComparer(locale) {
617
- if (locale === void 0) {
618
- return defaultComparer || (defaultComparer = stringComparerFactory(locale));
619
- } else if (locale === "en-US") {
620
- return enUSComparer || (enUSComparer = stringComparerFactory(locale));
621
- } else {
622
- return stringComparerFactory(locale);
623
- }
624
- }
625
587
  })();
626
588
  function getSpellingSuggestion(name, candidates, getName) {
627
589
  const maximumLengthDifference = Math.max(2, Math.floor(name.length * 0.34));
@@ -693,9 +655,6 @@ function endsWith(str, suffix) {
693
655
  const expectedPos = str.length - suffix.length;
694
656
  return expectedPos >= 0 && str.indexOf(suffix, expectedPos) === expectedPos;
695
657
  }
696
- function stringContains(str, substring) {
697
- return str.indexOf(substring) !== -1;
698
- }
699
658
  function removeMinAndVersionNumbers(fileName) {
700
659
  let end = fileName.length;
701
660
  for (let pos = end - 1; pos > 0; pos--) {
@@ -825,21 +784,6 @@ function enumerateInsertsAndDeletes(newItems, oldItems, comparer, inserted, dele
825
784
  }
826
785
  return hasChanges;
827
786
  }
828
- function padLeft(s, length2, padString = " ") {
829
- return length2 <= s.length ? s : padString.repeat(length2 - s.length) + s;
830
- }
831
- var trimString = !!String.prototype.trim ? (s) => s.trim() : (s) => trimStringEnd(trimStringStart(s));
832
- var trimStringEnd = !!String.prototype.trimEnd ? (s) => s.trimEnd() : trimEndImpl;
833
- var trimStringStart = !!String.prototype.trimStart ? (s) => s.trimStart() : (s) => s.replace(/^\s+/g, "");
834
- function trimEndImpl(s) {
835
- let end = s.length - 1;
836
- while (end >= 0) {
837
- if (!isWhiteSpaceLike(s.charCodeAt(end)))
838
- break;
839
- end--;
840
- }
841
- return s.slice(0, end + 1);
842
- }
843
787
  function isNodeLikeSystem() {
844
788
  return typeof process !== "undefined" && !!process.nextTick && !process.browser && typeof module === "object";
845
789
  }
@@ -2027,18 +1971,18 @@ var hyphenRegExp = /^\s*([a-z0-9-+.*]+)\s+-\s+([a-z0-9-+.*]+)\s*$/i;
2027
1971
  var rangeRegExp = /^(~|\^|<|<=|>|>=|=)?\s*([a-z0-9-+.*]+)$/i;
2028
1972
  function parseRange(text) {
2029
1973
  const alternatives = [];
2030
- for (let range of trimString(text).split(logicalOrRegExp)) {
1974
+ for (let range of text.trim().split(logicalOrRegExp)) {
2031
1975
  if (!range)
2032
1976
  continue;
2033
1977
  const comparators = [];
2034
- range = trimString(range);
1978
+ range = range.trim();
2035
1979
  const match = hyphenRegExp.exec(range);
2036
1980
  if (match) {
2037
1981
  if (!parseHyphen(match[1], match[2], comparators))
2038
1982
  return void 0;
2039
1983
  } else {
2040
1984
  for (const simple of range.split(whitespaceRegExp)) {
2041
- const match2 = rangeRegExp.exec(trimString(simple));
1985
+ const match2 = rangeRegExp.exec(simple.trim());
2042
1986
  if (!match2 || !parseComparator(match2[1], match2[2], comparators))
2043
1987
  return void 0;
2044
1988
  }
@@ -3927,11 +3871,11 @@ function createDirectoryWatcherSupportingRecursive({
3927
3871
  return some(ignoredPaths, (searchPath) => isInPath(path2, searchPath)) || isIgnoredByWatchOptions(path2, options, useCaseSensitiveFileNames2, getCurrentDirectory);
3928
3872
  }
3929
3873
  function isInPath(path2, searchPath) {
3930
- if (stringContains(path2, searchPath))
3874
+ if (path2.includes(searchPath))
3931
3875
  return true;
3932
3876
  if (useCaseSensitiveFileNames2)
3933
3877
  return false;
3934
- return stringContains(toCanonicalFilePath(path2), searchPath);
3878
+ return toCanonicalFilePath(path2).includes(searchPath);
3935
3879
  }
3936
3880
  }
3937
3881
  function createFileWatcherCallback(callback) {
@@ -4761,7 +4705,7 @@ function pathIsRelative(path2) {
4761
4705
  return /^\.\.?($|[\\/])/.test(path2);
4762
4706
  }
4763
4707
  function hasExtension(fileName) {
4764
- return stringContains(getBaseFileName(fileName), ".");
4708
+ return getBaseFileName(fileName).includes(".");
4765
4709
  }
4766
4710
  function fileExtensionIs(path2, extension) {
4767
4711
  return path2.length > extension.length && endsWith(path2, extension);
@@ -4906,7 +4850,7 @@ function getPathFromPathComponents(pathComponents2, length2) {
4906
4850
  return root + pathComponents2.slice(1, length2).join(directorySeparator);
4907
4851
  }
4908
4852
  function normalizeSlashes(path2) {
4909
- return path2.indexOf("\\") !== -1 ? path2.replace(backslashRegExp, directorySeparator) : path2;
4853
+ return path2.includes("\\") ? path2.replace(backslashRegExp, directorySeparator) : path2;
4910
4854
  }
4911
4855
  function reducePathComponents(components) {
4912
4856
  if (!some(components))
@@ -8178,7 +8122,7 @@ function createScanner(languageVersion, skipTrivia2, languageVariant = 0 /* Stan
8178
8122
  tokenFlags |= 2048 /* ContainsInvalidEscape */;
8179
8123
  if (shouldEmitInvalidEscapeError) {
8180
8124
  const code = parseInt(text.substring(start2 + 1, pos), 8);
8181
- error(Diagnostics.Octal_escape_sequences_are_not_allowed_Use_the_syntax_0, start2, pos - start2, "\\x" + padLeft(code.toString(16), 2, "0"));
8125
+ error(Diagnostics.Octal_escape_sequences_are_not_allowed_Use_the_syntax_0, start2, pos - start2, "\\x" + code.toString(16).padStart(2, "0"));
8182
8126
  return String.fromCharCode(code);
8183
8127
  }
8184
8128
  return text.substring(start2, pos);
@@ -8981,7 +8925,7 @@ function createScanner(languageVersion, skipTrivia2, languageVariant = 0 /* Stan
8981
8925
  return token;
8982
8926
  }
8983
8927
  function appendIfCommentDirective(commentDirectives2, text2, commentDirectiveRegEx, lineStart) {
8984
- const type = getDirectiveFromComment(trimStringStart(text2), commentDirectiveRegEx);
8928
+ const type = getDirectiveFromComment(text2.trimStart(), commentDirectiveRegEx);
8985
8929
  if (type === void 0) {
8986
8930
  return commentDirectives2;
8987
8931
  }
@@ -9315,20 +9259,9 @@ function createScanner(languageVersion, skipTrivia2, languageVariant = 0 /* Stan
9315
9259
  inJSDocType += inType ? 1 : -1;
9316
9260
  }
9317
9261
  }
9318
- var codePointAt = String.prototype.codePointAt ? (s, i) => s.codePointAt(i) : function codePointAt2(str, i) {
9319
- const size = str.length;
9320
- if (i < 0 || i >= size) {
9321
- return void 0;
9322
- }
9323
- const first2 = str.charCodeAt(i);
9324
- if (first2 >= 55296 && first2 <= 56319 && size > i + 1) {
9325
- const second = str.charCodeAt(i + 1);
9326
- if (second >= 56320 && second <= 57343) {
9327
- return (first2 - 55296) * 1024 + second - 56320 + 65536;
9328
- }
9329
- }
9330
- return first2;
9331
- };
9262
+ function codePointAt(s, i) {
9263
+ return s.codePointAt(i);
9264
+ }
9332
9265
  function charSize(ch) {
9333
9266
  if (ch >= 65536) {
9334
9267
  return 2;
@@ -10155,7 +10088,7 @@ function getTextOfNodeFromSourceText(sourceText, node, includeTrivia = false) {
10155
10088
  }
10156
10089
  let text = sourceText.substring(includeTrivia ? node.pos : skipTrivia(sourceText, node.pos), node.end);
10157
10090
  if (isJSDocTypeExpressionOrChild(node)) {
10158
- text = text.split(/\r\n|\n|\r/).map((line) => trimStringStart(line.replace(/^\s*\*/, ""))).join("\n");
10091
+ text = text.split(/\r\n|\n|\r/).map((line) => line.replace(/^\s*\*/, "").trimStart()).join("\n");
10159
10092
  }
10160
10093
  return text;
10161
10094
  }
@@ -11742,9 +11675,6 @@ function getEscapedTextOfJsxNamespacedName(node) {
11742
11675
  function getTextOfJsxNamespacedName(node) {
11743
11676
  return `${idText(node.namespace)}:${idText(node.name)}`;
11744
11677
  }
11745
- function isNamedTupleMemberName(node) {
11746
- return node.kind === 80 /* Identifier */ || node.kind === 203 /* TemplateLiteralType */ || node.kind === 15 /* NoSubstitutionTemplateLiteral */;
11747
- }
11748
11678
 
11749
11679
  // src/compiler/factory/baseNodeFactory.ts
11750
11680
  function createBaseNodeFactory() {
@@ -20517,29 +20447,21 @@ var Parser;
20517
20447
  }
20518
20448
  return type;
20519
20449
  }
20520
- function isTokenColonOrQuestionColon() {
20521
- return token() === 59 /* ColonToken */ || token() === 58 /* QuestionToken */ && nextToken() === 59 /* ColonToken */;
20450
+ function isNextTokenColonOrQuestionColon() {
20451
+ return nextToken() === 59 /* ColonToken */ || token() === 58 /* QuestionToken */ && nextToken() === 59 /* ColonToken */;
20522
20452
  }
20523
20453
  function isTupleElementName() {
20524
20454
  if (token() === 26 /* DotDotDotToken */) {
20525
- nextToken();
20526
- }
20527
- if (token() === 16 /* TemplateHead */) {
20528
- parseTemplateType();
20529
- return isTokenColonOrQuestionColon();
20530
- }
20531
- if (tokenIsIdentifierOrKeyword(token()) || token() === 15 /* NoSubstitutionTemplateLiteral */) {
20532
- nextToken();
20533
- return isTokenColonOrQuestionColon();
20455
+ return tokenIsIdentifierOrKeyword(nextToken()) && isNextTokenColonOrQuestionColon();
20534
20456
  }
20535
- return false;
20457
+ return tokenIsIdentifierOrKeyword(token()) && isNextTokenColonOrQuestionColon();
20536
20458
  }
20537
20459
  function parseTupleElementNameOrTupleElementType() {
20538
20460
  if (lookAhead(isTupleElementName)) {
20539
20461
  const pos = getNodePos();
20540
20462
  const hasJSDoc = hasPrecedingJSDocComment();
20541
20463
  const dotDotDotToken = parseOptionalToken(26 /* DotDotDotToken */);
20542
- const name = token() === 15 /* NoSubstitutionTemplateLiteral */ ? parseLiteralLikeNode(token()) : token() === 16 /* TemplateHead */ ? parseTemplateType() : parseIdentifierName();
20464
+ const name = parseIdentifierName();
20543
20465
  const questionToken = parseOptionalToken(58 /* QuestionToken */);
20544
20466
  parseExpected(59 /* ColonToken */);
20545
20467
  const type = parseTupleElementType();
@@ -23618,7 +23540,7 @@ var Parser;
23618
23540
  }
23619
23541
  function parseModuleOrNamespaceDeclaration(pos, hasJSDoc, modifiers, flags) {
23620
23542
  const namespaceFlag = flags & 32 /* Namespace */;
23621
- const name = parseIdentifier();
23543
+ const name = flags & 8 /* NestedNamespace */ ? parseIdentifierName() : parseIdentifier();
23622
23544
  const body = parseOptional(25 /* DotToken */) ? parseModuleOrNamespaceDeclaration(
23623
23545
  getNodePos(),
23624
23546
  /*hasJSDoc*/
@@ -24088,8 +24010,6 @@ var Parser;
24088
24010
  PropertyLikeParse2[PropertyLikeParse2["CallbackParameter"] = 4] = "CallbackParameter";
24089
24011
  })(PropertyLikeParse || (PropertyLikeParse = {}));
24090
24012
  function parseJSDocCommentWorker(start = 0, length2) {
24091
- const saveParsingContext = parsingContext;
24092
- parsingContext |= 1 << 25 /* JSDocComment */;
24093
24013
  const content = sourceText;
24094
24014
  const end = length2 === void 0 ? content.length : start + length2;
24095
24015
  length2 = end - start;
@@ -24106,6 +24026,8 @@ var Parser;
24106
24026
  let commentsPos;
24107
24027
  let comments = [];
24108
24028
  const parts = [];
24029
+ const saveParsingContext = parsingContext;
24030
+ parsingContext |= 1 << 25 /* JSDocComment */;
24109
24031
  const result = scanner.scanRange(start + 3, length2 - 5, doJSDocScan);
24110
24032
  parsingContext = saveParsingContext;
24111
24033
  return result;
@@ -24197,7 +24119,7 @@ var Parser;
24197
24119
  nextTokenJSDoc();
24198
24120
  }
24199
24121
  }
24200
- const trimmedComments = trimStringEnd(comments.join(""));
24122
+ const trimmedComments = comments.join("").trimEnd();
24201
24123
  if (parts.length && trimmedComments.length) {
24202
24124
  parts.push(finishNode(factory2.createJSDocText(trimmedComments), linkEnd ?? start, commentsPos));
24203
24125
  }
@@ -24213,7 +24135,7 @@ var Parser;
24213
24135
  }
24214
24136
  function removeTrailingWhitespace(comments2) {
24215
24137
  while (comments2.length) {
24216
- const trimmed = trimStringEnd(comments2[comments2.length - 1]);
24138
+ const trimmed = comments2[comments2.length - 1].trimEnd();
24217
24139
  if (trimmed === "") {
24218
24140
  comments2.pop();
24219
24141
  } else if (trimmed.length < comments2[comments2.length - 1].length) {
@@ -24453,7 +24375,7 @@ var Parser;
24453
24375
  }
24454
24376
  }
24455
24377
  removeLeadingNewlines(comments2);
24456
- const trimmedComments = trimStringEnd(comments2.join(""));
24378
+ const trimmedComments = comments2.join("").trimEnd();
24457
24379
  if (parts2.length) {
24458
24380
  if (trimmedComments.length) {
24459
24381
  parts2.push(finishNode(factory2.createJSDocText(trimmedComments), linkEnd2 ?? commentsPos2));
@@ -25351,7 +25273,7 @@ var IncrementalParser;
25351
25273
  })(InvalidPosition || (InvalidPosition = {}));
25352
25274
  })(IncrementalParser || (IncrementalParser = {}));
25353
25275
  function isDeclarationFileName(fileName) {
25354
- return fileExtensionIsOneOf(fileName, supportedDeclarationExtensions) || fileExtensionIs(fileName, ".ts" /* Ts */) && stringContains(getBaseFileName(fileName), ".d.");
25276
+ return fileExtensionIsOneOf(fileName, supportedDeclarationExtensions) || fileExtensionIs(fileName, ".ts" /* Ts */) && getBaseFileName(fileName).includes(".d.");
25355
25277
  }
25356
25278
  function parseResolutionMode(mode, pos, end, reportDiagnostic) {
25357
25279
  if (!mode) {
@@ -25537,7 +25459,7 @@ function getNamedPragmaArguments(pragma, text) {
25537
25459
  return {};
25538
25460
  if (!pragma.args)
25539
25461
  return {};
25540
- const args = trimString(text).split(/\s+/);
25462
+ const args = text.trim().split(/\s+/);
25541
25463
  const argMap = {};
25542
25464
  for (let i = 0; i < pragma.args.length; i++) {
25543
25465
  const argument = pragma.args[i];
@@ -27876,7 +27798,7 @@ function nodeModuleNameResolverWorker(features, moduleName, containingDirectory,
27876
27798
  result = tryResolve(extensions, state);
27877
27799
  }
27878
27800
  let legacyResult;
27879
- if (((_a = result == null ? void 0 : result.value) == null ? void 0 : _a.isExternalLibraryImport) && !isConfigLookup && extensions & (1 /* TypeScript */ | 4 /* Declaration */) && features & 8 /* Exports */ && !isExternalModuleNameRelative(moduleName) && !extensionIsOk(1 /* TypeScript */ | 4 /* Declaration */, result.value.resolved.extension) && conditions.indexOf("import") > -1) {
27801
+ if (((_a = result == null ? void 0 : result.value) == null ? void 0 : _a.isExternalLibraryImport) && !isConfigLookup && extensions & (1 /* TypeScript */ | 4 /* Declaration */) && features & 8 /* Exports */ && !isExternalModuleNameRelative(moduleName) && !extensionIsOk(1 /* TypeScript */ | 4 /* Declaration */, result.value.resolved.extension) && conditions.includes("import")) {
27880
27802
  traceIfEnabled(state, Diagnostics.Resolution_of_non_relative_name_failed_trying_with_modern_Node_resolution_features_disabled_to_see_if_npm_library_needs_configuration_update);
27881
27803
  const diagnosticState = {
27882
27804
  ...state,
@@ -27920,7 +27842,7 @@ function nodeModuleNameResolverWorker(features, moduleName, containingDirectory,
27920
27842
  resolved2 = loadModuleFromSelfNameReference(extensions2, moduleName, containingDirectory, state2, cache, redirectedReference);
27921
27843
  }
27922
27844
  if (!resolved2) {
27923
- if (moduleName.indexOf(":") > -1) {
27845
+ if (moduleName.includes(":")) {
27924
27846
  if (traceEnabled) {
27925
27847
  trace(host, Diagnostics.Skipping_module_0_that_looks_like_an_absolute_URI_target_file_types_Colon_1, moduleName, formatExtensions(extensions2));
27926
27848
  }
@@ -28010,7 +27932,7 @@ function nodeLoadModuleByRelativeName(extensions, candidate, onlyRecordFailures,
28010
27932
  }
28011
27933
  var nodeModulesPathPart = "/node_modules/";
28012
27934
  function pathContainsNodeModules(path2) {
28013
- return stringContains(path2, nodeModulesPathPart);
27935
+ return path2.includes(nodeModulesPathPart);
28014
27936
  }
28015
27937
  function parseNodeModuleFromPath(resolved, isFolder) {
28016
27938
  const path2 = normalizePath(resolved);
@@ -28046,7 +27968,7 @@ function loadModuleFromFile(extensions, candidate, onlyRecordFailures, state) {
28046
27968
  }
28047
27969
  function loadModuleFromFileNoImplicitExtensions(extensions, candidate, onlyRecordFailures, state) {
28048
27970
  const filename = getBaseFileName(candidate);
28049
- if (filename.indexOf(".") === -1) {
27971
+ if (!filename.includes(".")) {
28050
27972
  return void 0;
28051
27973
  }
28052
27974
  let extensionless = removeFileExtension(candidate);
@@ -28454,7 +28376,7 @@ function comparePatternKeys(a, b) {
28454
28376
  }
28455
28377
  function loadModuleFromImportsOrExports(extensions, state, cache, redirectedReference, moduleName, lookupTable, scope, isImports) {
28456
28378
  const loadModuleFromTargetImportOrExport = getLoadModuleFromTargetImportOrExport(extensions, state, cache, redirectedReference, moduleName, scope, isImports);
28457
- if (!endsWith(moduleName, directorySeparator) && moduleName.indexOf("*") === -1 && hasProperty(lookupTable, moduleName)) {
28379
+ if (!endsWith(moduleName, directorySeparator) && !moduleName.includes("*") && hasProperty(lookupTable, moduleName)) {
28458
28380
  const target = lookupTable[moduleName];
28459
28381
  return loadModuleFromTargetImportOrExport(
28460
28382
  target,
@@ -28465,7 +28387,7 @@ function loadModuleFromImportsOrExports(extensions, state, cache, redirectedRefe
28465
28387
  moduleName
28466
28388
  );
28467
28389
  }
28468
- const expandingKeys = sort(filter(getOwnKeys(lookupTable), (k) => k.indexOf("*") !== -1 || endsWith(k, "/")), comparePatternKeys);
28390
+ const expandingKeys = sort(filter(getOwnKeys(lookupTable), (k) => k.includes("*") || endsWith(k, "/")), comparePatternKeys);
28469
28391
  for (const potentialTarget of expandingKeys) {
28470
28392
  if (state.features & 16 /* ExportsPatternTrailers */ && matchesPatternWithTrailer(potentialTarget, moduleName)) {
28471
28393
  const target = lookupTable[potentialTarget];
@@ -28559,7 +28481,7 @@ function getLoadModuleFromTargetImportOrExport(extensions, state, cache, redirec
28559
28481
  }
28560
28482
  const parts = pathIsRelative(target) ? getPathComponents(target).slice(1) : getPathComponents(target);
28561
28483
  const partsAfterFirst = parts.slice(1);
28562
- if (partsAfterFirst.indexOf("..") >= 0 || partsAfterFirst.indexOf(".") >= 0 || partsAfterFirst.indexOf("node_modules") >= 0) {
28484
+ if (partsAfterFirst.includes("..") || partsAfterFirst.includes(".") || partsAfterFirst.includes("node_modules")) {
28563
28485
  if (state.traceEnabled) {
28564
28486
  trace(state.host, Diagnostics.package_json_scope_0_has_invalid_type_for_target_of_specifier_1, scope.packageDirectory, moduleName);
28565
28487
  }
@@ -28570,7 +28492,7 @@ function getLoadModuleFromTargetImportOrExport(extensions, state, cache, redirec
28570
28492
  }
28571
28493
  const resolvedTarget = combinePaths(scope.packageDirectory, target);
28572
28494
  const subpathParts = getPathComponents(subpath);
28573
- if (subpathParts.indexOf("..") >= 0 || subpathParts.indexOf(".") >= 0 || subpathParts.indexOf("node_modules") >= 0) {
28495
+ if (subpathParts.includes("..") || subpathParts.includes(".") || subpathParts.includes("node_modules")) {
28574
28496
  if (state.traceEnabled) {
28575
28497
  trace(state.host, Diagnostics.package_json_scope_0_has_invalid_type_for_target_of_specifier_1, scope.packageDirectory, moduleName);
28576
28498
  }
@@ -28597,7 +28519,7 @@ function getLoadModuleFromTargetImportOrExport(extensions, state, cache, redirec
28597
28519
  if (!Array.isArray(target)) {
28598
28520
  traceIfEnabled(state, Diagnostics.Entering_conditional_exports);
28599
28521
  for (const condition of getOwnKeys(target)) {
28600
- if (condition === "default" || state.conditions.indexOf(condition) >= 0 || isApplicableVersionedTypesKey(state.conditions, condition)) {
28522
+ if (condition === "default" || state.conditions.includes(condition) || isApplicableVersionedTypesKey(state.conditions, condition)) {
28601
28523
  traceIfEnabled(state, Diagnostics.Matched_0_condition_1, isImports ? "imports" : "exports", condition);
28602
28524
  const subTarget = target[condition];
28603
28525
  const result = loadModuleFromTargetImportOrExport(subTarget, subpath, pattern, key);
@@ -28658,7 +28580,7 @@ function getLoadModuleFromTargetImportOrExport(extensions, state, cache, redirec
28658
28580
  }
28659
28581
  function tryLoadInputFileForPath(finalPath, entry, packagePath, isImports2) {
28660
28582
  var _a, _b, _c, _d;
28661
- if (!state.isConfigLookup && (state.compilerOptions.declarationDir || state.compilerOptions.outDir) && finalPath.indexOf("/node_modules/") === -1 && (state.compilerOptions.configFile ? containsPath(scope.packageDirectory, toAbsolutePath(state.compilerOptions.configFile.fileName), !useCaseSensitiveFileNames(state)) : true)) {
28583
+ if (!state.isConfigLookup && (state.compilerOptions.declarationDir || state.compilerOptions.outDir) && !finalPath.includes("/node_modules/") && (state.compilerOptions.configFile ? containsPath(scope.packageDirectory, toAbsolutePath(state.compilerOptions.configFile.fileName), !useCaseSensitiveFileNames(state)) : true)) {
28662
28584
  const getCanonicalFileName = hostGetCanonicalFileName({ useCaseSensitiveFileNames: () => useCaseSensitiveFileNames(state) });
28663
28585
  const commonSourceDirGuesses = [];
28664
28586
  if (state.compilerOptions.rootDir || state.compilerOptions.composite && state.compilerOptions.configFilePath) {
@@ -28732,7 +28654,7 @@ function getLoadModuleFromTargetImportOrExport(extensions, state, cache, redirec
28732
28654
  }
28733
28655
  }
28734
28656
  function isApplicableVersionedTypesKey(conditions, key) {
28735
- if (conditions.indexOf("types") === -1)
28657
+ if (!conditions.includes("types"))
28736
28658
  return false;
28737
28659
  if (!startsWith(key, "types@"))
28738
28660
  return false;
@@ -29694,7 +29616,7 @@ var visitEachChildTable = {
29694
29616
  return context.factory.updateNamedTupleMember(
29695
29617
  node,
29696
29618
  tokenVisitor ? nodeVisitor(node.dotDotDotToken, tokenVisitor, isDotDotDotToken) : node.dotDotDotToken,
29697
- Debug.checkDefined(nodeVisitor(node.name, visitor, isNamedTupleMemberName)),
29619
+ Debug.checkDefined(nodeVisitor(node.name, visitor, isIdentifier)),
29698
29620
  tokenVisitor ? nodeVisitor(node.questionToken, tokenVisitor, isQuestionToken) : node.questionToken,
29699
29621
  Debug.checkDefined(nodeVisitor(node.type, visitor, isTypeNode))
29700
29622
  );
@@ -31680,7 +31602,7 @@ var Arguments;
31680
31602
  Arguments2.ValidateDefaultNpmLocation = "--validateDefaultNpmLocation";
31681
31603
  })(Arguments || (Arguments = {}));
31682
31604
  function hasArgument(argumentName) {
31683
- return sys.args.indexOf(argumentName) >= 0;
31605
+ return sys.args.includes(argumentName);
31684
31606
  }
31685
31607
  function findArgument(argumentName) {
31686
31608
  const index = sys.args.indexOf(argumentName);
@@ -31688,7 +31610,7 @@ function findArgument(argumentName) {
31688
31610
  }
31689
31611
  function nowString() {
31690
31612
  const d = /* @__PURE__ */ new Date();
31691
- return `${padLeft(d.getHours().toString(), 2, "0")}:${padLeft(d.getMinutes().toString(), 2, "0")}:${padLeft(d.getSeconds().toString(), 2, "0")}.${padLeft(d.getMilliseconds().toString(), 3, "0")}`;
31613
+ return `${d.getHours().toString().padStart(2, "0")}:${d.getMinutes().toString().padStart(2, "0")}:${d.getSeconds().toString().padStart(2, "0")}.${d.getMilliseconds().toString().padStart(3, "0")}`;
31692
31614
  }
31693
31615
 
31694
31616
  // src/typingsInstallerCore/typingsInstaller.ts
@@ -32107,7 +32029,7 @@ var NodeTypingsInstaller = class extends TypingsInstaller {
32107
32029
  log2
32108
32030
  );
32109
32031
  this.npmPath = npmLocation2 !== void 0 ? npmLocation2 : getDefaultNPMLocation(process.argv[0], validateDefaultNpmLocation2, this.installTypingHost);
32110
- if (stringContains(this.npmPath, " ") && this.npmPath[0] !== `"`) {
32032
+ if (this.npmPath.includes(" ") && this.npmPath[0] !== `"`) {
32111
32033
  this.npmPath = `"${this.npmPath}"`;
32112
32034
  }
32113
32035
  if (this.log.isEnabled()) {
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.3.0-pr-55452-7",
5
+ "version": "5.3.0-pr-55438-2",
6
6
  "license": "Apache-2.0",
7
7
  "description": "TypeScript is a language for application scale JavaScript development",
8
8
  "keywords": [
@@ -113,5 +113,5 @@
113
113
  "node": "20.1.0",
114
114
  "npm": "8.19.4"
115
115
  },
116
- "gitHead": "70cb7717b6c1bdfb06e172b22e6a6494fe8e5320"
116
+ "gitHead": "6889736b7b5cfbaed372a0f3ebce7662dbe02ed9"
117
117
  }