@storm-software/linting-tools 1.119.14 → 1.119.16

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.
Files changed (107) hide show
  1. package/README.md +7 -7
  2. package/{dist/chunk-P57FV6C7.cjs → bin/chunk-2HPUSEOW.cjs} +2 -2
  3. package/{dist/chunk-54CFDIUE.js → bin/chunk-2IE4DLUN.js} +1 -1
  4. package/bin/{chunk-5YNSXZUV.cjs → chunk-2KDMIKWU.cjs} +11 -11
  5. package/bin/{chunk-54RWBTS6.js → chunk-A4TZZH23.js} +2 -2
  6. package/bin/{chunk-2MMI4SWB.cjs → chunk-B5GG3XCQ.cjs} +44 -44
  7. package/{dist/chunk-ZCN56EP7.js → bin/chunk-BLCDYU3V.js} +1 -1
  8. package/{dist/chunk-UGTDGDK4.cjs → bin/chunk-BPGBQ4AU.cjs} +388 -388
  9. package/bin/{chunk-MWIMLJFN.cjs → chunk-EF2QNWS4.cjs} +204 -204
  10. package/bin/chunk-F6SMOBG3.js +112 -0
  11. package/bin/{chunk-3C4I67HA.js → chunk-FH3GDOOO.js} +2 -2
  12. package/{dist/chunk-XSNTWOJH.js → bin/chunk-HEZ4RO23.js} +2 -2
  13. package/bin/{chunk-YVJJXPQ6.js → chunk-NBPTD76Q.js} +2 -2
  14. package/bin/{chunk-32N2OGWN.js → chunk-NJWQ5DAN.js} +2 -2
  15. package/{dist/chunk-RHWLTUG4.cjs → bin/chunk-PQ5PUA5Y.cjs} +40 -40
  16. package/bin/{chunk-7GNWLBIN.cjs → chunk-SG7EAXX4.cjs} +138 -138
  17. package/{dist/chunk-RTS6UXXP.cjs → bin/chunk-SQCSB444.cjs} +32 -32
  18. package/{dist/chunk-K6L3YLSV.js → bin/chunk-VO3ZJK3W.js} +2 -2
  19. package/bin/{chunk-WHKY3M5Z.js → chunk-YGKJSNX7.js} +2 -2
  20. package/bin/chunk-YPA2QUMR.cjs +112 -0
  21. package/{dist/chunk-C5CFETOZ.cjs → bin/chunk-ZDJ6A2LW.cjs} +152 -152
  22. package/bin/{dist-ADRPNADD.cjs → dist-7LMLAWUP.cjs} +13 -11
  23. package/bin/{dist-3WBV2IAS.cjs → dist-OHY4PLS2.cjs} +989 -989
  24. package/bin/{dist-25H3BHT5.js → dist-RWR2JNAL.js} +7 -5
  25. package/bin/{dist-VPVBHEYK.js → dist-VFELXY4D.js} +8 -8
  26. package/bin/{esm-RUXZNXEX.js → esm-HY37SH6N.js} +1 -1
  27. package/{dist/esm-BNVF2MRI.cjs → bin/esm-XU4H3B2N.cjs} +46 -46
  28. package/bin/json5-3VVARTPN.cjs +10 -0
  29. package/bin/json5-WUIP5FMS.js +10 -0
  30. package/bin/jsonc-IS6EPVRJ.cjs +15 -0
  31. package/{dist/jsonc-HBV365B7.js → bin/jsonc-KYPEKHOV.js} +3 -3
  32. package/bin/lint.cjs +27626 -27108
  33. package/bin/lint.js +1102 -584
  34. package/{dist/multipart-parser-GIYQPD3I.js → bin/multipart-parser-5HBMD6JO.js} +2 -2
  35. package/bin/{multipart-parser-GL32RRIX.cjs → multipart-parser-CF3BQORX.cjs} +11 -11
  36. package/bin/{package-json-XQ2VHHU4.cjs → package-json-6XHUARKD.cjs} +248 -248
  37. package/{dist/package-json-BISGQCQA.js → bin/package-json-V5Z5DK5X.js} +2 -2
  38. package/bin/toml-BAOM6BGG.js +10 -0
  39. package/bin/toml-JQMR5ASK.cjs +10 -0
  40. package/bin/{utils-ZXNPMV2B.js → utils-DUARF7MU.js} +4 -13
  41. package/{dist/utils-B72MMWGL.cjs → bin/utils-ZLRC2VXJ.cjs} +12 -21
  42. package/bin/yaml-LF4MDF3I.cjs +10 -0
  43. package/bin/yaml-TI2L6CZN.js +10 -0
  44. package/{bin/chunk-P57FV6C7.cjs → dist/chunk-2HPUSEOW.cjs} +2 -2
  45. package/{bin/chunk-54CFDIUE.js → dist/chunk-2IE4DLUN.js} +1 -1
  46. package/dist/{chunk-5YNSXZUV.cjs → chunk-2KDMIKWU.cjs} +11 -11
  47. package/dist/{chunk-54RWBTS6.js → chunk-A4TZZH23.js} +2 -2
  48. package/dist/{chunk-2MMI4SWB.cjs → chunk-B5GG3XCQ.cjs} +44 -44
  49. package/{bin/chunk-ZCN56EP7.js → dist/chunk-BLCDYU3V.js} +1 -1
  50. package/{bin/chunk-UGTDGDK4.cjs → dist/chunk-BPGBQ4AU.cjs} +388 -388
  51. package/dist/{chunk-MWIMLJFN.cjs → chunk-EF2QNWS4.cjs} +204 -204
  52. package/dist/chunk-F6SMOBG3.js +112 -0
  53. package/dist/{chunk-3C4I67HA.js → chunk-FH3GDOOO.js} +2 -2
  54. package/{bin/chunk-XSNTWOJH.js → dist/chunk-HEZ4RO23.js} +2 -2
  55. package/dist/{chunk-YVJJXPQ6.js → chunk-NBPTD76Q.js} +2 -2
  56. package/dist/{chunk-32N2OGWN.js → chunk-NJWQ5DAN.js} +2 -2
  57. package/{bin/chunk-RHWLTUG4.cjs → dist/chunk-PQ5PUA5Y.cjs} +40 -40
  58. package/dist/{chunk-7GNWLBIN.cjs → chunk-SG7EAXX4.cjs} +138 -138
  59. package/{bin/chunk-RTS6UXXP.cjs → dist/chunk-SQCSB444.cjs} +32 -32
  60. package/{bin/chunk-K6L3YLSV.js → dist/chunk-VO3ZJK3W.js} +2 -2
  61. package/dist/{chunk-WHKY3M5Z.js → chunk-YGKJSNX7.js} +2 -2
  62. package/dist/chunk-YPA2QUMR.cjs +112 -0
  63. package/{bin/chunk-C5CFETOZ.cjs → dist/chunk-ZDJ6A2LW.cjs} +152 -152
  64. package/dist/{dist-ADRPNADD.cjs → dist-7LMLAWUP.cjs} +13 -11
  65. package/dist/{dist-3WBV2IAS.cjs → dist-OHY4PLS2.cjs} +989 -989
  66. package/dist/{dist-25H3BHT5.js → dist-RWR2JNAL.js} +7 -5
  67. package/dist/{dist-VPVBHEYK.js → dist-VFELXY4D.js} +8 -8
  68. package/dist/{esm-RUXZNXEX.js → esm-HY37SH6N.js} +1 -1
  69. package/{bin/esm-BNVF2MRI.cjs → dist/esm-XU4H3B2N.cjs} +46 -46
  70. package/dist/index.cjs +27622 -27104
  71. package/dist/index.d.cts +64 -0
  72. package/dist/index.d.ts +64 -0
  73. package/dist/index.js +1102 -584
  74. package/dist/json5-3VVARTPN.cjs +10 -0
  75. package/dist/json5-WUIP5FMS.js +10 -0
  76. package/dist/jsonc-IS6EPVRJ.cjs +15 -0
  77. package/{bin/jsonc-HBV365B7.js → dist/jsonc-KYPEKHOV.js} +3 -3
  78. package/{bin/multipart-parser-GIYQPD3I.js → dist/multipart-parser-5HBMD6JO.js} +2 -2
  79. package/dist/{multipart-parser-GL32RRIX.cjs → multipart-parser-CF3BQORX.cjs} +11 -11
  80. package/dist/{package-json-XQ2VHHU4.cjs → package-json-6XHUARKD.cjs} +248 -248
  81. package/{bin/package-json-BISGQCQA.js → dist/package-json-V5Z5DK5X.js} +2 -2
  82. package/dist/toml-BAOM6BGG.js +10 -0
  83. package/dist/toml-JQMR5ASK.cjs +10 -0
  84. package/dist/{utils-ZXNPMV2B.js → utils-DUARF7MU.js} +4 -13
  85. package/{bin/utils-B72MMWGL.cjs → dist/utils-ZLRC2VXJ.cjs} +12 -21
  86. package/dist/yaml-LF4MDF3I.cjs +10 -0
  87. package/dist/yaml-TI2L6CZN.js +10 -0
  88. package/package.json +1 -1
  89. package/zizmor/config.yml +1 -2
  90. package/bin/chunk-FQD7U3GL.cjs +0 -105
  91. package/bin/chunk-LPZTUZI7.js +0 -105
  92. package/bin/json5-4GROEWN5.cjs +0 -10
  93. package/bin/json5-OPEY7IVI.js +0 -10
  94. package/bin/jsonc-HON5YCSB.cjs +0 -15
  95. package/bin/toml-4KC5RP7Q.js +0 -10
  96. package/bin/toml-52O5X4HU.cjs +0 -10
  97. package/bin/yaml-GU7KPIYY.cjs +0 -10
  98. package/bin/yaml-ODZRTFYX.js +0 -10
  99. package/dist/chunk-FQD7U3GL.cjs +0 -105
  100. package/dist/chunk-LPZTUZI7.js +0 -105
  101. package/dist/json5-4GROEWN5.cjs +0 -10
  102. package/dist/json5-OPEY7IVI.js +0 -10
  103. package/dist/jsonc-HON5YCSB.cjs +0 -15
  104. package/dist/toml-4KC5RP7Q.js +0 -10
  105. package/dist/toml-52O5X4HU.cjs +0 -10
  106. package/dist/yaml-GU7KPIYY.cjs +0 -10
  107. package/dist/yaml-ODZRTFYX.js +0 -10
package/dist/index.js CHANGED
@@ -2,7 +2,7 @@ import {
2
2
  require_clean,
3
3
  require_semver,
4
4
  require_valid
5
- } from "./chunk-ZCN56EP7.js";
5
+ } from "./chunk-BLCDYU3V.js";
6
6
  import {
7
7
  basename,
8
8
  be,
@@ -14,12 +14,12 @@ import {
14
14
  join,
15
15
  readPackageJSON,
16
16
  resolve
17
- } from "./chunk-XSNTWOJH.js";
18
- import "./chunk-54RWBTS6.js";
19
- import "./chunk-YVJJXPQ6.js";
20
- import "./chunk-K6L3YLSV.js";
21
- import "./chunk-32N2OGWN.js";
22
- import "./chunk-54CFDIUE.js";
17
+ } from "./chunk-HEZ4RO23.js";
18
+ import "./chunk-A4TZZH23.js";
19
+ import "./chunk-NBPTD76Q.js";
20
+ import "./chunk-VO3ZJK3W.js";
21
+ import "./chunk-NJWQ5DAN.js";
22
+ import "./chunk-2IE4DLUN.js";
23
23
  import {
24
24
  __commonJS,
25
25
  __dirname,
@@ -32,7 +32,7 @@ import {
32
32
  __toCommonJS,
33
33
  __toESM,
34
34
  init_esm_shims
35
- } from "./chunk-3C4I67HA.js";
35
+ } from "./chunk-FH3GDOOO.js";
36
36
 
37
37
  // ../../node_modules/.pnpm/jiti@2.4.2/node_modules/jiti/dist/jiti.cjs
38
38
  var require_jiti = __commonJS({
@@ -40404,9 +40404,9 @@ var require_out2 = __commonJS({
40404
40404
  }
40405
40405
  });
40406
40406
 
40407
- // ../../node_modules/.pnpm/reusify@1.0.4/node_modules/reusify/reusify.js
40407
+ // ../../node_modules/.pnpm/reusify@1.1.0/node_modules/reusify/reusify.js
40408
40408
  var require_reusify = __commonJS({
40409
- "../../node_modules/.pnpm/reusify@1.0.4/node_modules/reusify/reusify.js"(exports, module) {
40409
+ "../../node_modules/.pnpm/reusify@1.1.0/node_modules/reusify/reusify.js"(exports, module) {
40410
40410
  "use strict";
40411
40411
  init_esm_shims();
40412
40412
  function reusify(Constructor) {
@@ -40439,9 +40439,9 @@ var require_reusify = __commonJS({
40439
40439
  }
40440
40440
  });
40441
40441
 
40442
- // ../../node_modules/.pnpm/fastq@1.19.0/node_modules/fastq/queue.js
40442
+ // ../../node_modules/.pnpm/fastq@1.19.1/node_modules/fastq/queue.js
40443
40443
  var require_queue = __commonJS({
40444
- "../../node_modules/.pnpm/fastq@1.19.0/node_modules/fastq/queue.js"(exports, module) {
40444
+ "../../node_modules/.pnpm/fastq@1.19.1/node_modules/fastq/queue.js"(exports, module) {
40445
40445
  "use strict";
40446
40446
  init_esm_shims();
40447
40447
  var reusify = require_reusify();
@@ -82327,9 +82327,9 @@ var require_source_map_support = __commonJS({
82327
82327
  }
82328
82328
  });
82329
82329
 
82330
- // ../../node_modules/.pnpm/typescript@5.7.3/node_modules/typescript/lib/typescript.js
82330
+ // ../../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/typescript.js
82331
82331
  var require_typescript = __commonJS({
82332
- "../../node_modules/.pnpm/typescript@5.7.3/node_modules/typescript/lib/typescript.js"(exports, module) {
82332
+ "../../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/typescript.js"(exports, module) {
82333
82333
  init_esm_shims();
82334
82334
  var ts = {};
82335
82335
  ((module1) => {
@@ -82756,6 +82756,7 @@ var require_typescript = __commonJS({
82756
82756
  createPrinterWithRemoveCommentsNeverAsciiEscape: /* @__PURE__ */ __name(() => createPrinterWithRemoveCommentsNeverAsciiEscape, "createPrinterWithRemoveCommentsNeverAsciiEscape"),
82757
82757
  createPrinterWithRemoveCommentsOmitTrailingSemicolon: /* @__PURE__ */ __name(() => createPrinterWithRemoveCommentsOmitTrailingSemicolon, "createPrinterWithRemoveCommentsOmitTrailingSemicolon"),
82758
82758
  createProgram: /* @__PURE__ */ __name(() => createProgram2, "createProgram"),
82759
+ createProgramDiagnostics: /* @__PURE__ */ __name(() => createProgramDiagnostics, "createProgramDiagnostics"),
82759
82760
  createProgramHost: /* @__PURE__ */ __name(() => createProgramHost, "createProgramHost"),
82760
82761
  createPropertyNameNodeForIdentifierOrLiteral: /* @__PURE__ */ __name(() => createPropertyNameNodeForIdentifierOrLiteral, "createPropertyNameNodeForIdentifierOrLiteral"),
82761
82762
  createQueue: /* @__PURE__ */ __name(() => createQueue, "createQueue"),
@@ -82925,6 +82926,8 @@ var require_typescript = __commonJS({
82925
82926
  forEachLeadingCommentRange: /* @__PURE__ */ __name(() => forEachLeadingCommentRange, "forEachLeadingCommentRange"),
82926
82927
  forEachNameInAccessChainWalkingLeft: /* @__PURE__ */ __name(() => forEachNameInAccessChainWalkingLeft, "forEachNameInAccessChainWalkingLeft"),
82927
82928
  forEachNameOfDefaultExport: /* @__PURE__ */ __name(() => forEachNameOfDefaultExport, "forEachNameOfDefaultExport"),
82929
+ forEachOptionsSyntaxByName: /* @__PURE__ */ __name(() => forEachOptionsSyntaxByName, "forEachOptionsSyntaxByName"),
82930
+ forEachProjectReference: /* @__PURE__ */ __name(() => forEachProjectReference, "forEachProjectReference"),
82928
82931
  forEachPropertyAssignment: /* @__PURE__ */ __name(() => forEachPropertyAssignment, "forEachPropertyAssignment"),
82929
82932
  forEachResolvedProjectReference: /* @__PURE__ */ __name(() => forEachResolvedProjectReference, "forEachResolvedProjectReference"),
82930
82933
  forEachReturnStatement: /* @__PURE__ */ __name(() => forEachReturnStatement, "forEachReturnStatement"),
@@ -83164,6 +83167,8 @@ var require_typescript = __commonJS({
83164
83167
  getLeadingCommentRangesOfNode: /* @__PURE__ */ __name(() => getLeadingCommentRangesOfNode, "getLeadingCommentRangesOfNode"),
83165
83168
  getLeftmostAccessExpression: /* @__PURE__ */ __name(() => getLeftmostAccessExpression, "getLeftmostAccessExpression"),
83166
83169
  getLeftmostExpression: /* @__PURE__ */ __name(() => getLeftmostExpression, "getLeftmostExpression"),
83170
+ getLibFileNameFromLibReference: /* @__PURE__ */ __name(() => getLibFileNameFromLibReference, "getLibFileNameFromLibReference"),
83171
+ getLibNameFromLibReference: /* @__PURE__ */ __name(() => getLibNameFromLibReference, "getLibNameFromLibReference"),
83167
83172
  getLibraryNameFromLibFileName: /* @__PURE__ */ __name(() => getLibraryNameFromLibFileName, "getLibraryNameFromLibFileName"),
83168
83173
  getLineAndCharacterOfPosition: /* @__PURE__ */ __name(() => getLineAndCharacterOfPosition, "getLineAndCharacterOfPosition"),
83169
83174
  getLineInfo: /* @__PURE__ */ __name(() => getLineInfo, "getLineInfo"),
@@ -83236,6 +83241,8 @@ var require_typescript = __commonJS({
83236
83241
  getOptionFromName: /* @__PURE__ */ __name(() => getOptionFromName, "getOptionFromName"),
83237
83242
  getOptionsForLibraryResolution: /* @__PURE__ */ __name(() => getOptionsForLibraryResolution, "getOptionsForLibraryResolution"),
83238
83243
  getOptionsNameMap: /* @__PURE__ */ __name(() => getOptionsNameMap, "getOptionsNameMap"),
83244
+ getOptionsSyntaxByArrayElementValue: /* @__PURE__ */ __name(() => getOptionsSyntaxByArrayElementValue, "getOptionsSyntaxByArrayElementValue"),
83245
+ getOptionsSyntaxByValue: /* @__PURE__ */ __name(() => getOptionsSyntaxByValue, "getOptionsSyntaxByValue"),
83239
83246
  getOrCreateEmitNode: /* @__PURE__ */ __name(() => getOrCreateEmitNode, "getOrCreateEmitNode"),
83240
83247
  getOrUpdate: /* @__PURE__ */ __name(() => getOrUpdate, "getOrUpdate"),
83241
83248
  getOriginalNode: /* @__PURE__ */ __name(() => getOriginalNode, "getOriginalNode"),
@@ -83272,7 +83279,6 @@ var require_typescript = __commonJS({
83272
83279
  getPrivateIdentifier: /* @__PURE__ */ __name(() => getPrivateIdentifier, "getPrivateIdentifier"),
83273
83280
  getProperties: /* @__PURE__ */ __name(() => getProperties, "getProperties"),
83274
83281
  getProperty: /* @__PURE__ */ __name(() => getProperty, "getProperty"),
83275
- getPropertyArrayElementValue: /* @__PURE__ */ __name(() => getPropertyArrayElementValue, "getPropertyArrayElementValue"),
83276
83282
  getPropertyAssignmentAliasLikeExpression: /* @__PURE__ */ __name(() => getPropertyAssignmentAliasLikeExpression, "getPropertyAssignmentAliasLikeExpression"),
83277
83283
  getPropertyNameForPropertyNameNode: /* @__PURE__ */ __name(() => getPropertyNameForPropertyNameNode, "getPropertyNameForPropertyNameNode"),
83278
83284
  getPropertyNameFromType: /* @__PURE__ */ __name(() => getPropertyNameFromType, "getPropertyNameFromType"),
@@ -84183,6 +84189,7 @@ var require_typescript = __commonJS({
84183
84189
  moduleResolutionUsesNodeModules: /* @__PURE__ */ __name(() => moduleResolutionUsesNodeModules, "moduleResolutionUsesNodeModules"),
84184
84190
  moduleSpecifierToValidIdentifier: /* @__PURE__ */ __name(() => moduleSpecifierToValidIdentifier, "moduleSpecifierToValidIdentifier"),
84185
84191
  moduleSpecifiers: /* @__PURE__ */ __name(() => ts_moduleSpecifiers_exports, "moduleSpecifiers"),
84192
+ moduleSupportsImportAttributes: /* @__PURE__ */ __name(() => moduleSupportsImportAttributes, "moduleSupportsImportAttributes"),
84186
84193
  moduleSymbolToValidIdentifier: /* @__PURE__ */ __name(() => moduleSymbolToValidIdentifier, "moduleSymbolToValidIdentifier"),
84187
84194
  moveEmitHelpers: /* @__PURE__ */ __name(() => moveEmitHelpers, "moveEmitHelpers"),
84188
84195
  moveRangeEnd: /* @__PURE__ */ __name(() => moveRangeEnd, "moveRangeEnd"),
@@ -84595,8 +84602,8 @@ var require_typescript = __commonJS({
84595
84602
  zipWith: /* @__PURE__ */ __name(() => zipWith, "zipWith")
84596
84603
  });
84597
84604
  module1.exports = __toCommonJS2(typescript_exports);
84598
- var versionMajorMinor = "5.7";
84599
- var version4 = "5.7.3";
84605
+ var versionMajorMinor = "5.8";
84606
+ var version4 = "5.8.2";
84600
84607
  var Comparison = /* @__PURE__ */ ((Comparison3) => {
84601
84608
  Comparison3[Comparison3["LessThan"] = -1] = "LessThan";
84602
84609
  Comparison3[Comparison3["EqualTo"] = 0] = "EqualTo";
@@ -89533,6 +89540,7 @@ ${lanes.join("\n")}
89533
89540
  ModuleKind3[ModuleKind3["ES2022"] = 7] = "ES2022";
89534
89541
  ModuleKind3[ModuleKind3["ESNext"] = 99] = "ESNext";
89535
89542
  ModuleKind3[ModuleKind3["Node16"] = 100] = "Node16";
89543
+ ModuleKind3[ModuleKind3["Node18"] = 101] = "Node18";
89536
89544
  ModuleKind3[ModuleKind3["NodeNext"] = 199] = "NodeNext";
89537
89545
  ModuleKind3[ModuleKind3["Preserve"] = 200] = "Preserve";
89538
89546
  return ModuleKind3;
@@ -90017,8 +90025,9 @@ ${lanes.join("\n")}
90017
90025
  OuterExpressionKinds2[OuterExpressionKinds2["NonNullAssertions"] = 4] = "NonNullAssertions";
90018
90026
  OuterExpressionKinds2[OuterExpressionKinds2["PartiallyEmittedExpressions"] = 8] = "PartiallyEmittedExpressions";
90019
90027
  OuterExpressionKinds2[OuterExpressionKinds2["ExpressionsWithTypeArguments"] = 16] = "ExpressionsWithTypeArguments";
90020
- OuterExpressionKinds2[OuterExpressionKinds2["Assertions"] = 6] = "Assertions";
90021
- OuterExpressionKinds2[OuterExpressionKinds2["All"] = 31] = "All";
90028
+ OuterExpressionKinds2[OuterExpressionKinds2["Satisfies"] = 32] = "Satisfies";
90029
+ OuterExpressionKinds2[OuterExpressionKinds2["Assertions"] = 38] = "Assertions";
90030
+ OuterExpressionKinds2[OuterExpressionKinds2["All"] = 63] = "All";
90022
90031
  OuterExpressionKinds2[OuterExpressionKinds2["ExcludeJSDocTypeAssertion"] = -2147483648] = "ExcludeJSDocTypeAssertion";
90023
90032
  return OuterExpressionKinds2;
90024
90033
  })(OuterExpressionKinds || {});
@@ -91973,26 +91982,109 @@ ${lanes.join("\n")}
91973
91982
  return reducePathComponents(getPathComponents(path36, currentDirectory));
91974
91983
  }
91975
91984
  __name(getNormalizedPathComponents, "getNormalizedPathComponents");
91976
- function getNormalizedAbsolutePath(fileName, currentDirectory) {
91977
- return getPathFromPathComponents(getNormalizedPathComponents(fileName, currentDirectory));
91985
+ function getNormalizedAbsolutePath(path36, currentDirectory) {
91986
+ let rootLength = getRootLength(path36);
91987
+ if (rootLength === 0 && currentDirectory) {
91988
+ path36 = combinePaths(currentDirectory, path36);
91989
+ rootLength = getRootLength(path36);
91990
+ } else {
91991
+ path36 = normalizeSlashes(path36);
91992
+ }
91993
+ const simpleNormalized = simpleNormalizePath(path36);
91994
+ if (simpleNormalized !== void 0) {
91995
+ return simpleNormalized.length > rootLength ? removeTrailingDirectorySeparator(simpleNormalized) : simpleNormalized;
91996
+ }
91997
+ const length2 = path36.length;
91998
+ const root = path36.substring(0, rootLength);
91999
+ let normalized;
92000
+ let index2 = rootLength;
92001
+ let segmentStart = index2;
92002
+ let normalizedUpTo = index2;
92003
+ let seenNonDotDotSegment = rootLength !== 0;
92004
+ while (index2 < length2) {
92005
+ segmentStart = index2;
92006
+ let ch = path36.charCodeAt(index2);
92007
+ while (ch === 47 && index2 + 1 < length2) {
92008
+ index2++;
92009
+ ch = path36.charCodeAt(index2);
92010
+ }
92011
+ if (index2 > segmentStart) {
92012
+ normalized ?? (normalized = path36.substring(0, segmentStart - 1));
92013
+ segmentStart = index2;
92014
+ }
92015
+ let segmentEnd = path36.indexOf(directorySeparator, index2 + 1);
92016
+ if (segmentEnd === -1) {
92017
+ segmentEnd = length2;
92018
+ }
92019
+ const segmentLength = segmentEnd - segmentStart;
92020
+ if (segmentLength === 1 && path36.charCodeAt(index2) === 46) {
92021
+ normalized ?? (normalized = path36.substring(0, normalizedUpTo));
92022
+ } else if (segmentLength === 2 && path36.charCodeAt(index2) === 46 && path36.charCodeAt(index2 + 1) === 46) {
92023
+ if (!seenNonDotDotSegment) {
92024
+ if (normalized !== void 0) {
92025
+ normalized += normalized.length === rootLength ? ".." : "/..";
92026
+ } else {
92027
+ normalizedUpTo = index2 + 2;
92028
+ }
92029
+ } else if (normalized === void 0) {
92030
+ if (normalizedUpTo - 2 >= 0) {
92031
+ normalized = path36.substring(0, Math.max(rootLength, path36.lastIndexOf(directorySeparator, normalizedUpTo - 2)));
92032
+ } else {
92033
+ normalized = path36.substring(0, normalizedUpTo);
92034
+ }
92035
+ } else {
92036
+ const lastSlash = normalized.lastIndexOf(directorySeparator);
92037
+ if (lastSlash !== -1) {
92038
+ normalized = normalized.substring(0, Math.max(rootLength, lastSlash));
92039
+ } else {
92040
+ normalized = root;
92041
+ }
92042
+ if (normalized.length === rootLength) {
92043
+ seenNonDotDotSegment = rootLength !== 0;
92044
+ }
92045
+ }
92046
+ } else if (normalized !== void 0) {
92047
+ if (normalized.length !== rootLength) {
92048
+ normalized += directorySeparator;
92049
+ }
92050
+ seenNonDotDotSegment = true;
92051
+ normalized += path36.substring(segmentStart, segmentEnd);
92052
+ } else {
92053
+ seenNonDotDotSegment = true;
92054
+ normalizedUpTo = segmentEnd;
92055
+ }
92056
+ index2 = segmentEnd + 1;
92057
+ }
92058
+ return normalized ?? (length2 > rootLength ? removeTrailingDirectorySeparator(path36) : path36);
91978
92059
  }
91979
92060
  __name(getNormalizedAbsolutePath, "getNormalizedAbsolutePath");
91980
92061
  function normalizePath4(path36) {
91981
92062
  path36 = normalizeSlashes(path36);
92063
+ let normalized = simpleNormalizePath(path36);
92064
+ if (normalized !== void 0) {
92065
+ return normalized;
92066
+ }
92067
+ normalized = getNormalizedAbsolutePath(path36, "");
92068
+ return normalized && hasTrailingDirectorySeparator(path36) ? ensureTrailingDirectorySeparator(normalized) : normalized;
92069
+ }
92070
+ __name(normalizePath4, "normalizePath");
92071
+ function simpleNormalizePath(path36) {
91982
92072
  if (!relativePathSegmentRegExp.test(path36)) {
91983
92073
  return path36;
91984
92074
  }
91985
- const simplified = path36.replace(/\/\.\//g, "/").replace(/^\.\//, "");
92075
+ let simplified = path36.replace(/\/\.\//g, "/");
92076
+ if (simplified.startsWith("./")) {
92077
+ simplified = simplified.slice(2);
92078
+ }
91986
92079
  if (simplified !== path36) {
91987
92080
  path36 = simplified;
91988
92081
  if (!relativePathSegmentRegExp.test(path36)) {
91989
92082
  return path36;
91990
92083
  }
91991
92084
  }
91992
- const normalized = getPathFromPathComponents(reducePathComponents(getPathComponents(path36)));
91993
- return normalized && hasTrailingDirectorySeparator(path36) ? ensureTrailingDirectorySeparator(normalized) : normalized;
92085
+ return void 0;
91994
92086
  }
91995
- __name(normalizePath4, "normalizePath");
92087
+ __name(simpleNormalizePath, "simpleNormalizePath");
91996
92088
  function getPathWithoutRoot(pathComponents2) {
91997
92089
  if (pathComponents2.length === 0) return "";
91998
92090
  return pathComponents2.slice(1).join(directorySeparator);
@@ -92446,6 +92538,7 @@ ${lanes.join("\n")}
92446
92538
  _0_resolves_to_a_type_and_must_be_marked_type_only_in_this_file_before_re_exporting_when_1_is_enabled_Consider_using_import_type_where_0_is_imported: diag(1291, 1, "_0_resolves_to_a_type_and_must_be_marked_type_only_in_this_file_before_re_exporting_when_1_is_enable_1291", "'{0}' resolves to a type and must be marked type-only in this file before re-exporting when '{1}' is enabled. Consider using 'import type' where '{0}' is imported."),
92447
92539
  _0_resolves_to_a_type_and_must_be_marked_type_only_in_this_file_before_re_exporting_when_1_is_enabled_Consider_using_export_type_0_as_default: diag(1292, 1, "_0_resolves_to_a_type_and_must_be_marked_type_only_in_this_file_before_re_exporting_when_1_is_enable_1292", "'{0}' resolves to a type and must be marked type-only in this file before re-exporting when '{1}' is enabled. Consider using 'export type { {0} as default }'."),
92448
92540
  ESM_syntax_is_not_allowed_in_a_CommonJS_module_when_module_is_set_to_preserve: diag(1293, 1, "ESM_syntax_is_not_allowed_in_a_CommonJS_module_when_module_is_set_to_preserve_1293", "ESM syntax is not allowed in a CommonJS module when 'module' is set to 'preserve'."),
92541
+ This_syntax_is_not_allowed_when_erasableSyntaxOnly_is_enabled: diag(1294, 1, "This_syntax_is_not_allowed_when_erasableSyntaxOnly_is_enabled_1294", "This syntax is not allowed when 'erasableSyntaxOnly' is enabled."),
92449
92542
  with_statements_are_not_allowed_in_an_async_function_block: diag(1300, 1, "with_statements_are_not_allowed_in_an_async_function_block_1300", "'with' statements are not allowed in an async function block."),
92450
92543
  await_expressions_are_only_allowed_within_async_functions_and_at_the_top_levels_of_modules: diag(1308, 1, "await_expressions_are_only_allowed_within_async_functions_and_at_the_top_levels_of_modules_1308", "'await' expressions are only allowed within async functions and at the top levels of modules."),
92451
92544
  The_current_file_is_a_CommonJS_module_and_cannot_use_await_at_the_top_level: diag(1309, 1, "The_current_file_is_a_CommonJS_module_and_cannot_use_await_at_the_top_level_1309", "The current file is a CommonJS module and cannot use 'await' at the top level."),
@@ -92460,8 +92553,8 @@ ${lanes.join("\n")}
92460
92553
  Type_of_await_operand_must_either_be_a_valid_promise_or_must_not_contain_a_callable_then_member: diag(1320, 1, "Type_of_await_operand_must_either_be_a_valid_promise_or_must_not_contain_a_callable_then_member_1320", "Type of 'await' operand must either be a valid promise or must not contain a callable 'then' member."),
92461
92554
  Type_of_yield_operand_in_an_async_generator_must_either_be_a_valid_promise_or_must_not_contain_a_callable_then_member: diag(1321, 1, "Type_of_yield_operand_in_an_async_generator_must_either_be_a_valid_promise_or_must_not_contain_a_cal_1321", "Type of 'yield' operand in an async generator must either be a valid promise or must not contain a callable 'then' member."),
92462
92555
  Type_of_iterated_elements_of_a_yield_Asterisk_operand_must_either_be_a_valid_promise_or_must_not_contain_a_callable_then_member: diag(1322, 1, "Type_of_iterated_elements_of_a_yield_Asterisk_operand_must_either_be_a_valid_promise_or_must_not_con_1322", "Type of iterated elements of a 'yield*' operand must either be a valid promise or must not contain a callable 'then' member."),
92463
- Dynamic_imports_are_only_supported_when_the_module_flag_is_set_to_es2020_es2022_esnext_commonjs_amd_system_umd_node16_or_nodenext: diag(1323, 1, "Dynamic_imports_are_only_supported_when_the_module_flag_is_set_to_es2020_es2022_esnext_commonjs_amd__1323", "Dynamic imports are only supported when the '--module' flag is set to 'es2020', 'es2022', 'esnext', 'commonjs', 'amd', 'system', 'umd', 'node16', or 'nodenext'."),
92464
- Dynamic_imports_only_support_a_second_argument_when_the_module_option_is_set_to_esnext_node16_nodenext_or_preserve: diag(1324, 1, "Dynamic_imports_only_support_a_second_argument_when_the_module_option_is_set_to_esnext_node16_nodene_1324", "Dynamic imports only support a second argument when the '--module' option is set to 'esnext', 'node16', 'nodenext', or 'preserve'."),
92556
+ Dynamic_imports_are_only_supported_when_the_module_flag_is_set_to_es2020_es2022_esnext_commonjs_amd_system_umd_node16_node18_or_nodenext: diag(1323, 1, "Dynamic_imports_are_only_supported_when_the_module_flag_is_set_to_es2020_es2022_esnext_commonjs_amd__1323", "Dynamic imports are only supported when the '--module' flag is set to 'es2020', 'es2022', 'esnext', 'commonjs', 'amd', 'system', 'umd', 'node16', 'node18', or 'nodenext'."),
92557
+ Dynamic_imports_only_support_a_second_argument_when_the_module_option_is_set_to_esnext_node16_node18_nodenext_or_preserve: diag(1324, 1, "Dynamic_imports_only_support_a_second_argument_when_the_module_option_is_set_to_esnext_node16_node18_1324", "Dynamic imports only support a second argument when the '--module' option is set to 'esnext', 'node16', 'node18', 'nodenext', or 'preserve'."),
92465
92558
  Argument_of_dynamic_import_cannot_be_spread_element: diag(1325, 1, "Argument_of_dynamic_import_cannot_be_spread_element_1325", "Argument of dynamic import cannot be spread element."),
92466
92559
  This_use_of_import_is_invalid_import_calls_can_be_written_but_they_must_have_parentheses_and_cannot_have_type_arguments: diag(1326, 1, "This_use_of_import_is_invalid_import_calls_can_be_written_but_they_must_have_parentheses_and_cannot__1326", "This use of 'import' is invalid. 'import()' calls can be written, but they must have parentheses and cannot have type arguments."),
92467
92560
  String_literal_with_double_quotes_expected: diag(1327, 1, "String_literal_with_double_quotes_expected_1327", "String literal with double quotes expected."),
@@ -92478,7 +92571,7 @@ ${lanes.join("\n")}
92478
92571
  Module_0_does_not_refer_to_a_value_but_is_used_as_a_value_here: diag(1339, 1, "Module_0_does_not_refer_to_a_value_but_is_used_as_a_value_here_1339", "Module '{0}' does not refer to a value, but is used as a value here."),
92479
92572
  Module_0_does_not_refer_to_a_type_but_is_used_as_a_type_here_Did_you_mean_typeof_import_0: diag(1340, 1, "Module_0_does_not_refer_to_a_type_but_is_used_as_a_type_here_Did_you_mean_typeof_import_0_1340", "Module '{0}' does not refer to a type, but is used as a type here. Did you mean 'typeof import('{0}')'?"),
92480
92573
  Class_constructor_may_not_be_an_accessor: diag(1341, 1, "Class_constructor_may_not_be_an_accessor_1341", "Class constructor may not be an accessor."),
92481
- The_import_meta_meta_property_is_only_allowed_when_the_module_option_is_es2020_es2022_esnext_system_node16_or_nodenext: diag(1343, 1, "The_import_meta_meta_property_is_only_allowed_when_the_module_option_is_es2020_es2022_esnext_system__1343", "The 'import.meta' meta-property is only allowed when the '--module' option is 'es2020', 'es2022', 'esnext', 'system', 'node16', or 'nodenext'."),
92574
+ The_import_meta_meta_property_is_only_allowed_when_the_module_option_is_es2020_es2022_esnext_system_node16_node18_or_nodenext: diag(1343, 1, "The_import_meta_meta_property_is_only_allowed_when_the_module_option_is_es2020_es2022_esnext_system__1343", "The 'import.meta' meta-property is only allowed when the '--module' option is 'es2020', 'es2022', 'esnext', 'system', 'node16', 'node18', or 'nodenext'."),
92482
92575
  A_label_is_not_allowed_here: diag(1344, 1, "A_label_is_not_allowed_here_1344", "'A label is not allowed here."),
92483
92576
  An_expression_of_type_void_cannot_be_tested_for_truthiness: diag(1345, 1, "An_expression_of_type_void_cannot_be_tested_for_truthiness_1345", "An expression of type 'void' cannot be tested for truthiness."),
92484
92577
  This_parameter_is_not_allowed_with_use_strict_directive: diag(1346, 1, "This_parameter_is_not_allowed_with_use_strict_directive_1346", "This parameter is not allowed with 'use strict' directive."),
@@ -92508,7 +92601,7 @@ ${lanes.join("\n")}
92508
92601
  await_expressions_are_only_allowed_at_the_top_level_of_a_file_when_that_file_is_a_module_but_this_file_has_no_imports_or_exports_Consider_adding_an_empty_export_to_make_this_file_a_module: diag(1375, 1, "await_expressions_are_only_allowed_at_the_top_level_of_a_file_when_that_file_is_a_module_but_this_fi_1375", "'await' expressions are only allowed at the top level of a file when that file is a module, but this file has no imports or exports. Consider adding an empty 'export {}' to make this file a module."),
92509
92602
  _0_was_imported_here: diag(1376, 3, "_0_was_imported_here_1376", "'{0}' was imported here."),
92510
92603
  _0_was_exported_here: diag(1377, 3, "_0_was_exported_here_1377", "'{0}' was exported here."),
92511
- Top_level_await_expressions_are_only_allowed_when_the_module_option_is_set_to_es2022_esnext_system_node16_nodenext_or_preserve_and_the_target_option_is_set_to_es2017_or_higher: diag(1378, 1, "Top_level_await_expressions_are_only_allowed_when_the_module_option_is_set_to_es2022_esnext_system_n_1378", "Top-level 'await' expressions are only allowed when the 'module' option is set to 'es2022', 'esnext', 'system', 'node16', 'nodenext', or 'preserve', and the 'target' option is set to 'es2017' or higher."),
92604
+ Top_level_await_expressions_are_only_allowed_when_the_module_option_is_set_to_es2022_esnext_system_node16_node18_nodenext_or_preserve_and_the_target_option_is_set_to_es2017_or_higher: diag(1378, 1, "Top_level_await_expressions_are_only_allowed_when_the_module_option_is_set_to_es2022_esnext_system_n_1378", "Top-level 'await' expressions are only allowed when the 'module' option is set to 'es2022', 'esnext', 'system', 'node16', 'node18', 'nodenext', or 'preserve', and the 'target' option is set to 'es2017' or higher."),
92512
92605
  An_import_alias_cannot_reference_a_declaration_that_was_exported_using_export_type: diag(1379, 1, "An_import_alias_cannot_reference_a_declaration_that_was_exported_using_export_type_1379", "An import alias cannot reference a declaration that was exported using 'export type'."),
92513
92606
  An_import_alias_cannot_reference_a_declaration_that_was_imported_using_import_type: diag(1380, 1, "An_import_alias_cannot_reference_a_declaration_that_was_imported_using_import_type_1380", "An import alias cannot reference a declaration that was imported using 'import type'."),
92514
92607
  Unexpected_token_Did_you_mean_or_rbrace: diag(1381, 1, "Unexpected_token_Did_you_mean_or_rbrace_1381", "Unexpected token. Did you mean `{'}'}` or `&rbrace;`?"),
@@ -92559,7 +92652,7 @@ ${lanes.join("\n")}
92559
92652
  File_redirects_to_file_0: diag(1429, 3, "File_redirects_to_file_0_1429", "File redirects to file '{0}'"),
92560
92653
  The_file_is_in_the_program_because_Colon: diag(1430, 3, "The_file_is_in_the_program_because_Colon_1430", "The file is in the program because:"),
92561
92654
  for_await_loops_are_only_allowed_at_the_top_level_of_a_file_when_that_file_is_a_module_but_this_file_has_no_imports_or_exports_Consider_adding_an_empty_export_to_make_this_file_a_module: diag(1431, 1, "for_await_loops_are_only_allowed_at_the_top_level_of_a_file_when_that_file_is_a_module_but_this_file_1431", "'for await' loops are only allowed at the top level of a file when that file is a module, but this file has no imports or exports. Consider adding an empty 'export {}' to make this file a module."),
92562
- Top_level_for_await_loops_are_only_allowed_when_the_module_option_is_set_to_es2022_esnext_system_node16_nodenext_or_preserve_and_the_target_option_is_set_to_es2017_or_higher: diag(1432, 1, "Top_level_for_await_loops_are_only_allowed_when_the_module_option_is_set_to_es2022_esnext_system_nod_1432", "Top-level 'for await' loops are only allowed when the 'module' option is set to 'es2022', 'esnext', 'system', 'node16', 'nodenext', or 'preserve', and the 'target' option is set to 'es2017' or higher."),
92655
+ Top_level_for_await_loops_are_only_allowed_when_the_module_option_is_set_to_es2022_esnext_system_node16_node18_nodenext_or_preserve_and_the_target_option_is_set_to_es2017_or_higher: diag(1432, 1, "Top_level_for_await_loops_are_only_allowed_when_the_module_option_is_set_to_es2022_esnext_system_nod_1432", "Top-level 'for await' loops are only allowed when the 'module' option is set to 'es2022', 'esnext', 'system', 'node16', 'node18', 'nodenext', or 'preserve', and the 'target' option is set to 'es2017' or higher."),
92563
92656
  Neither_decorators_nor_modifiers_may_be_applied_to_this_parameters: diag(1433, 1, "Neither_decorators_nor_modifiers_may_be_applied_to_this_parameters_1433", "Neither decorators nor modifiers may be applied to 'this' parameters."),
92564
92657
  Unexpected_keyword_or_identifier: diag(1434, 1, "Unexpected_keyword_or_identifier_1434", "Unexpected keyword or identifier."),
92565
92658
  Unknown_keyword_or_identifier_Did_you_mean_0: diag(1435, 1, "Unknown_keyword_or_identifier_Did_you_mean_0_1435", "Unknown keyword or identifier. Did you mean '{0}'?"),
@@ -93201,9 +93294,9 @@ ${lanes.join("\n")}
93201
93294
  Duplicate_identifier_0_Compiler_reserves_name_1_when_emitting_super_references_in_static_initializers: diag(2818, 1, "Duplicate_identifier_0_Compiler_reserves_name_1_when_emitting_super_references_in_static_initializer_2818", "Duplicate identifier '{0}'. Compiler reserves name '{1}' when emitting 'super' references in static initializers."),
93202
93295
  Namespace_name_cannot_be_0: diag(2819, 1, "Namespace_name_cannot_be_0_2819", "Namespace name cannot be '{0}'."),
93203
93296
  Type_0_is_not_assignable_to_type_1_Did_you_mean_2: diag(2820, 1, "Type_0_is_not_assignable_to_type_1_Did_you_mean_2_2820", "Type '{0}' is not assignable to type '{1}'. Did you mean '{2}'?"),
93204
- Import_assertions_are_only_supported_when_the_module_option_is_set_to_esnext_nodenext_or_preserve: diag(2821, 1, "Import_assertions_are_only_supported_when_the_module_option_is_set_to_esnext_nodenext_or_preserve_2821", "Import assertions are only supported when the '--module' option is set to 'esnext', 'nodenext', or 'preserve'."),
93297
+ Import_assertions_are_only_supported_when_the_module_option_is_set_to_esnext_node18_nodenext_or_preserve: diag(2821, 1, "Import_assertions_are_only_supported_when_the_module_option_is_set_to_esnext_node18_nodenext_or_pres_2821", "Import assertions are only supported when the '--module' option is set to 'esnext', 'node18', 'nodenext', or 'preserve'."),
93205
93298
  Import_assertions_cannot_be_used_with_type_only_imports_or_exports: diag(2822, 1, "Import_assertions_cannot_be_used_with_type_only_imports_or_exports_2822", "Import assertions cannot be used with type-only imports or exports."),
93206
- Import_attributes_are_only_supported_when_the_module_option_is_set_to_esnext_nodenext_or_preserve: diag(2823, 1, "Import_attributes_are_only_supported_when_the_module_option_is_set_to_esnext_nodenext_or_preserve_2823", "Import attributes are only supported when the '--module' option is set to 'esnext', 'nodenext', or 'preserve'."),
93299
+ Import_attributes_are_only_supported_when_the_module_option_is_set_to_esnext_node18_nodenext_or_preserve: diag(2823, 1, "Import_attributes_are_only_supported_when_the_module_option_is_set_to_esnext_node18_nodenext_or_pres_2823", "Import attributes are only supported when the '--module' option is set to 'esnext', 'node18', 'nodenext', or 'preserve'."),
93207
93300
  Cannot_find_namespace_0_Did_you_mean_1: diag(2833, 1, "Cannot_find_namespace_0_Did_you_mean_1_2833", "Cannot find namespace '{0}'. Did you mean '{1}'?"),
93208
93301
  Relative_import_paths_need_explicit_file_extensions_in_ECMAScript_imports_when_moduleResolution_is_node16_or_nodenext_Consider_adding_an_extension_to_the_import_path: diag(2834, 1, "Relative_import_paths_need_explicit_file_extensions_in_ECMAScript_imports_when_moduleResolution_is_n_2834", "Relative import paths need explicit file extensions in ECMAScript imports when '--moduleResolution' is 'node16' or 'nodenext'. Consider adding an extension to the import path."),
93209
93302
  Relative_import_paths_need_explicit_file_extensions_in_ECMAScript_imports_when_moduleResolution_is_node16_or_nodenext_Did_you_mean_0: diag(2835, 1, "Relative_import_paths_need_explicit_file_extensions_in_ECMAScript_imports_when_moduleResolution_is_n_2835", "Relative import paths need explicit file extensions in ECMAScript imports when '--moduleResolution' is 'node16' or 'nodenext'. Did you mean '{0}'?"),
@@ -93223,7 +93316,7 @@ ${lanes.join("\n")}
93223
93316
  The_initializer_of_an_await_using_declaration_must_be_either_an_object_with_a_Symbol_asyncDispose_or_Symbol_dispose_method_or_be_null_or_undefined: diag(2851, 1, "The_initializer_of_an_await_using_declaration_must_be_either_an_object_with_a_Symbol_asyncDispose_or_2851", "The initializer of an 'await using' declaration must be either an object with a '[Symbol.asyncDispose]()' or '[Symbol.dispose]()' method, or be 'null' or 'undefined'."),
93224
93317
  await_using_statements_are_only_allowed_within_async_functions_and_at_the_top_levels_of_modules: diag(2852, 1, "await_using_statements_are_only_allowed_within_async_functions_and_at_the_top_levels_of_modules_2852", "'await using' statements are only allowed within async functions and at the top levels of modules."),
93225
93318
  await_using_statements_are_only_allowed_at_the_top_level_of_a_file_when_that_file_is_a_module_but_this_file_has_no_imports_or_exports_Consider_adding_an_empty_export_to_make_this_file_a_module: diag(2853, 1, "await_using_statements_are_only_allowed_at_the_top_level_of_a_file_when_that_file_is_a_module_but_th_2853", "'await using' statements are only allowed at the top level of a file when that file is a module, but this file has no imports or exports. Consider adding an empty 'export {}' to make this file a module."),
93226
- Top_level_await_using_statements_are_only_allowed_when_the_module_option_is_set_to_es2022_esnext_system_node16_nodenext_or_preserve_and_the_target_option_is_set_to_es2017_or_higher: diag(2854, 1, "Top_level_await_using_statements_are_only_allowed_when_the_module_option_is_set_to_es2022_esnext_sys_2854", "Top-level 'await using' statements are only allowed when the 'module' option is set to 'es2022', 'esnext', 'system', 'node16', 'nodenext', or 'preserve', and the 'target' option is set to 'es2017' or higher."),
93319
+ Top_level_await_using_statements_are_only_allowed_when_the_module_option_is_set_to_es2022_esnext_system_node16_node18_nodenext_or_preserve_and_the_target_option_is_set_to_es2017_or_higher: diag(2854, 1, "Top_level_await_using_statements_are_only_allowed_when_the_module_option_is_set_to_es2022_esnext_sys_2854", "Top-level 'await using' statements are only allowed when the 'module' option is set to 'es2022', 'esnext', 'system', 'node16', 'node18', 'nodenext', or 'preserve', and the 'target' option is set to 'es2017' or higher."),
93227
93320
  Class_field_0_defined_by_the_parent_class_is_not_accessible_in_the_child_class_via_super: diag(2855, 1, "Class_field_0_defined_by_the_parent_class_is_not_accessible_in_the_child_class_via_super_2855", "Class field '{0}' defined by the parent class is not accessible in the child class via super."),
93228
93321
  Import_attributes_are_not_allowed_on_statements_that_compile_to_CommonJS_require_calls: diag(2856, 1, "Import_attributes_are_not_allowed_on_statements_that_compile_to_CommonJS_require_calls_2856", "Import attributes are not allowed on statements that compile to CommonJS 'require' calls."),
93229
93322
  Import_attributes_cannot_be_used_with_type_only_imports_or_exports: diag(2857, 1, "Import_attributes_cannot_be_used_with_type_only_imports_or_exports_2857", "Import attributes cannot be used with type-only imports or exports."),
@@ -93249,6 +93342,7 @@ ${lanes.join("\n")}
93249
93342
  This_import_uses_a_0_extension_to_resolve_to_an_input_TypeScript_file_but_will_not_be_rewritten_during_emit_because_it_is_not_a_relative_path: diag(2877, 1, "This_import_uses_a_0_extension_to_resolve_to_an_input_TypeScript_file_but_will_not_be_rewritten_duri_2877", "This import uses a '{0}' extension to resolve to an input TypeScript file, but will not be rewritten during emit because it is not a relative path."),
93250
93343
  This_import_path_is_unsafe_to_rewrite_because_it_resolves_to_another_project_and_the_relative_path_between_the_projects_output_files_is_not_the_same_as_the_relative_path_between_its_input_files: diag(2878, 1, "This_import_path_is_unsafe_to_rewrite_because_it_resolves_to_another_project_and_the_relative_path_b_2878", "This import path is unsafe to rewrite because it resolves to another project, and the relative path between the projects' output files is not the same as the relative path between its input files."),
93251
93344
  Using_JSX_fragments_requires_fragment_factory_0_to_be_in_scope_but_it_could_not_be_found: diag(2879, 1, "Using_JSX_fragments_requires_fragment_factory_0_to_be_in_scope_but_it_could_not_be_found_2879", "Using JSX fragments requires fragment factory '{0}' to be in scope, but it could not be found."),
93345
+ Import_assertions_have_been_replaced_by_import_attributes_Use_with_instead_of_assert: diag(2880, 1, "Import_assertions_have_been_replaced_by_import_attributes_Use_with_instead_of_assert_2880", "Import assertions have been replaced by import attributes. Use 'with' instead of 'assert'."),
93252
93346
  Import_declaration_0_is_using_private_name_1: diag(4e3, 1, "Import_declaration_0_is_using_private_name_1_4000", "Import declaration '{0}' is using private name '{1}'."),
93253
93347
  Type_parameter_0_of_exported_class_has_or_is_using_private_name_1: diag(4002, 1, "Type_parameter_0_of_exported_class_has_or_is_using_private_name_1_4002", "Type parameter '{0}' of exported class has or is using private name '{1}'."),
93254
93348
  Type_parameter_0_of_exported_interface_has_or_is_using_private_name_1: diag(4004, 1, "Type_parameter_0_of_exported_interface_has_or_is_using_private_name_1_4004", "Type parameter '{0}' of exported interface has or is using private name '{1}'."),
@@ -93358,6 +93452,8 @@ ${lanes.join("\n")}
93358
93452
  Compiler_option_0_of_value_1_is_unstable_Use_nightly_TypeScript_to_silence_this_error_Try_updating_with_npm_install_D_typescript_next: diag(4124, 1, "Compiler_option_0_of_value_1_is_unstable_Use_nightly_TypeScript_to_silence_this_error_Try_updating_w_4124", "Compiler option '{0}' of value '{1}' is unstable. Use nightly TypeScript to silence this error. Try updating with 'npm install -D typescript@next'."),
93359
93453
  Each_declaration_of_0_1_differs_in_its_value_where_2_was_expected_but_3_was_given: diag(4125, 1, "Each_declaration_of_0_1_differs_in_its_value_where_2_was_expected_but_3_was_given_4125", "Each declaration of '{0}.{1}' differs in its value, where '{2}' was expected but '{3}' was given."),
93360
93454
  One_value_of_0_1_is_the_string_2_and_the_other_is_assumed_to_be_an_unknown_numeric_value: diag(4126, 1, "One_value_of_0_1_is_the_string_2_and_the_other_is_assumed_to_be_an_unknown_numeric_value_4126", "One value of '{0}.{1}' is the string '{2}', and the other is assumed to be an unknown numeric value."),
93455
+ This_member_cannot_have_an_override_modifier_because_its_name_is_dynamic: diag(4127, 1, "This_member_cannot_have_an_override_modifier_because_its_name_is_dynamic_4127", "This member cannot have an 'override' modifier because its name is dynamic."),
93456
+ This_member_cannot_have_a_JSDoc_comment_with_an_override_tag_because_its_name_is_dynamic: diag(4128, 1, "This_member_cannot_have_a_JSDoc_comment_with_an_override_tag_because_its_name_is_dynamic_4128", "This member cannot have a JSDoc comment with an '@override' tag because its name is dynamic."),
93361
93457
  The_current_host_does_not_support_the_0_option: diag(5001, 1, "The_current_host_does_not_support_the_0_option_5001", "The current host does not support the '{0}' option."),
93362
93458
  Cannot_find_the_common_subdirectory_path_for_the_input_files: diag(5009, 1, "Cannot_find_the_common_subdirectory_path_for_the_input_files_5009", "Cannot find the common subdirectory path for the input files."),
93363
93459
  File_specification_cannot_end_in_a_recursive_directory_wildcard_Asterisk_Asterisk_Colon_0: diag(5010, 1, "File_specification_cannot_end_in_a_recursive_directory_wildcard_Asterisk_Asterisk_Colon_0_5010", "File specification cannot end in a recursive directory wildcard ('**'): '{0}'."),
@@ -93930,11 +94026,13 @@ ${lanes.join("\n")}
93930
94026
  Specify_emit_Slashchecking_behavior_for_imports_that_are_only_used_for_types: diag(6718, 3, "Specify_emit_Slashchecking_behavior_for_imports_that_are_only_used_for_types_6718", "Specify emit/checking behavior for imports that are only used for types."),
93931
94027
  Require_sufficient_annotation_on_exports_so_other_tools_can_trivially_generate_declaration_files: diag(6719, 3, "Require_sufficient_annotation_on_exports_so_other_tools_can_trivially_generate_declaration_files_6719", "Require sufficient annotation on exports so other tools can trivially generate declaration files."),
93932
94028
  Built_in_iterators_are_instantiated_with_a_TReturn_type_of_undefined_instead_of_any: diag(6720, 3, "Built_in_iterators_are_instantiated_with_a_TReturn_type_of_undefined_instead_of_any_6720", "Built-in iterators are instantiated with a 'TReturn' type of 'undefined' instead of 'any'."),
94029
+ Do_not_allow_runtime_constructs_that_are_not_part_of_ECMAScript: diag(6721, 3, "Do_not_allow_runtime_constructs_that_are_not_part_of_ECMAScript_6721", "Do not allow runtime constructs that are not part of ECMAScript."),
93933
94030
  Default_catch_clause_variables_as_unknown_instead_of_any: diag(6803, 3, "Default_catch_clause_variables_as_unknown_instead_of_any_6803", "Default catch clause variables as 'unknown' instead of 'any'."),
93934
94031
  Do_not_transform_or_elide_any_imports_or_exports_not_marked_as_type_only_ensuring_they_are_written_in_the_output_file_s_format_based_on_the_module_setting: diag(6804, 3, "Do_not_transform_or_elide_any_imports_or_exports_not_marked_as_type_only_ensuring_they_are_written_i_6804", "Do not transform or elide any imports or exports not marked as type-only, ensuring they are written in the output file's format based on the 'module' setting."),
93935
94032
  Disable_full_type_checking_only_critical_parse_and_emit_errors_will_be_reported: diag(6805, 3, "Disable_full_type_checking_only_critical_parse_and_emit_errors_will_be_reported_6805", "Disable full type checking (only critical parse and emit errors will be reported)."),
93936
94033
  Check_side_effect_imports: diag(6806, 3, "Check_side_effect_imports_6806", "Check side effect imports."),
93937
94034
  This_operation_can_be_simplified_This_shift_is_identical_to_0_1_2: diag(6807, 1, "This_operation_can_be_simplified_This_shift_is_identical_to_0_1_2_6807", "This operation can be simplified. This shift is identical to `{0} {1} {2}`."),
94035
+ Enable_lib_replacement: diag(6808, 3, "Enable_lib_replacement_6808", "Enable lib replacement."),
93938
94036
  one_of_Colon: diag(6900, 3, "one_of_Colon_6900", "one of:"),
93939
94037
  one_or_more_Colon: diag(6901, 3, "one_or_more_Colon_6901", "one or more:"),
93940
94038
  type_Colon: diag(6902, 3, "type_Colon_6902", "type:"),
@@ -105521,6 +105619,9 @@ ${lanes.join("\n")}
105521
105619
  "trunc",
105522
105620
  "fround",
105523
105621
  "cbrt"
105622
+ ],
105623
+ esnext: [
105624
+ "f16round"
105524
105625
  ]
105525
105626
  })),
105526
105627
  Map: new Map(Object.entries({
@@ -105690,6 +105791,10 @@ ${lanes.join("\n")}
105690
105791
  "setBigUint64",
105691
105792
  "getBigInt64",
105692
105793
  "getBigUint64"
105794
+ ],
105795
+ esnext: [
105796
+ "setFloat16",
105797
+ "getFloat16"
105693
105798
  ]
105694
105799
  })),
105695
105800
  BigInt: new Map(Object.entries({
@@ -105793,6 +105898,9 @@ ${lanes.join("\n")}
105793
105898
  "with"
105794
105899
  ]
105795
105900
  })),
105901
+ Float16Array: new Map(Object.entries({
105902
+ esnext: emptyArray
105903
+ })),
105796
105904
  Float32Array: new Map(Object.entries({
105797
105905
  es2022: [
105798
105906
  "at"
@@ -106000,7 +106108,7 @@ ${lanes.join("\n")}
106000
106108
  }
106001
106109
  __name(getNonAugmentationDeclaration, "getNonAugmentationDeclaration");
106002
106110
  function isCommonJSContainingModuleKind(kind) {
106003
- return kind === 1 || kind === 100 || kind === 199;
106111
+ return kind === 1 || 100 <= kind && kind <= 199;
106004
106112
  }
106005
106113
  __name(isCommonJSContainingModuleKind, "isCommonJSContainingModuleKind");
106006
106114
  function isEffectiveExternalModule(node, compilerOptions) {
@@ -106801,10 +106909,6 @@ ${lanes.join("\n")}
106801
106909
  });
106802
106910
  }
106803
106911
  __name(forEachPropertyAssignment, "forEachPropertyAssignment");
106804
- function getPropertyArrayElementValue(objectLiteral, propKey, elementValue) {
106805
- return forEachPropertyAssignment(objectLiteral, propKey, (property) => isArrayLiteralExpression(property.initializer) ? find2(property.initializer.elements, (element) => isStringLiteral(element) && element.text === elementValue) : void 0);
106806
- }
106807
- __name(getPropertyArrayElementValue, "getPropertyArrayElementValue");
106808
106912
  function getTsConfigObjectLiteralExpression(tsConfigSourceFile) {
106809
106913
  if (tsConfigSourceFile && tsConfigSourceFile.statements.length) {
106810
106914
  const expression = tsConfigSourceFile.statements[0].expression;
@@ -111190,7 +111294,7 @@ ${lanes.join("\n")}
111190
111294
  ],
111191
111295
  computeValue: /* @__PURE__ */ __name((compilerOptions) => {
111192
111296
  const target = compilerOptions.target === 0 ? void 0 : compilerOptions.target;
111193
- return target ?? (compilerOptions.module === 100 && 9 || compilerOptions.module === 199 && 99 || 1);
111297
+ return target ?? (compilerOptions.module === 100 && 9 || compilerOptions.module === 101 && 9 || compilerOptions.module === 199 && 99 || 1);
111194
111298
  }, "computeValue")
111195
111299
  },
111196
111300
  module: {
@@ -111214,6 +111318,7 @@ ${lanes.join("\n")}
111214
111318
  moduleResolution = 2;
111215
111319
  break;
111216
111320
  case 100:
111321
+ case 101:
111217
111322
  moduleResolution = 3;
111218
111323
  break;
111219
111324
  case 199:
@@ -111236,7 +111341,11 @@ ${lanes.join("\n")}
111236
111341
  "target"
111237
111342
  ],
111238
111343
  computeValue: /* @__PURE__ */ __name((compilerOptions) => {
111239
- return compilerOptions.moduleDetection || (_computedOptions.module.computeValue(compilerOptions) === 100 || _computedOptions.module.computeValue(compilerOptions) === 199 ? 3 : 2);
111344
+ if (compilerOptions.moduleDetection !== void 0) {
111345
+ return compilerOptions.moduleDetection;
111346
+ }
111347
+ const moduleKind = _computedOptions.module.computeValue(compilerOptions);
111348
+ return 100 <= moduleKind && moduleKind <= 199 ? 3 : 2;
111240
111349
  }, "computeValue")
111241
111350
  },
111242
111351
  isolatedModules: {
@@ -111258,6 +111367,7 @@ ${lanes.join("\n")}
111258
111367
  }
111259
111368
  switch (_computedOptions.module.computeValue(compilerOptions)) {
111260
111369
  case 100:
111370
+ case 101:
111261
111371
  case 199:
111262
111372
  case 200:
111263
111373
  return true;
@@ -111502,6 +111612,10 @@ ${lanes.join("\n")}
111502
111612
  return moduleResolution >= 3 && moduleResolution <= 99 || moduleResolution === 100;
111503
111613
  }
111504
111614
  __name(moduleResolutionSupportsPackageJsonExportsAndImports, "moduleResolutionSupportsPackageJsonExportsAndImports");
111615
+ function moduleSupportsImportAttributes(moduleKind) {
111616
+ return 101 <= moduleKind && moduleKind <= 199 || moduleKind === 200 || moduleKind === 99;
111617
+ }
111618
+ __name(moduleSupportsImportAttributes, "moduleSupportsImportAttributes");
111505
111619
  function getStrictOptionValue(compilerOptions, flag) {
111506
111620
  return compilerOptions[flag] === void 0 ? !!compilerOptions.strict : !!compilerOptions[flag];
111507
111621
  }
@@ -112463,7 +112577,7 @@ ${lanes.join("\n")}
112463
112577
  }
112464
112578
  __name(isValidBigIntString, "isValidBigIntString");
112465
112579
  function isValidTypeOnlyAliasUseSite(useSite) {
112466
- return !!(useSite.flags & 33554432) || isPartOfTypeQuery(useSite) || isIdentifierInNonEmittingHeritageClause(useSite) || isPartOfPossiblyValidTypeOrAbstractComputedPropertyName(useSite) || !(isExpressionNode(useSite) || isShorthandPropertyNameUseSite(useSite));
112580
+ return !!(useSite.flags & 33554432) || isInJSDoc(useSite) || isPartOfTypeQuery(useSite) || isIdentifierInNonEmittingHeritageClause(useSite) || isPartOfPossiblyValidTypeOrAbstractComputedPropertyName(useSite) || !(isExpressionNode(useSite) || isShorthandPropertyNameUseSite(useSite));
112467
112581
  }
112468
112582
  __name(isValidTypeOnlyAliasUseSite, "isValidTypeOnlyAliasUseSite");
112469
112583
  function isShorthandPropertyNameUseSite(useSite) {
@@ -113744,6 +113858,67 @@ ${lanes.join("\n")}
113744
113858
  return isFunctionLike(node) || isJSDocSignature(node) || isMappedTypeNode(node);
113745
113859
  }
113746
113860
  __name(isNewScopeNode, "isNewScopeNode");
113861
+ function getLibNameFromLibReference(libReference) {
113862
+ return toFileNameLowerCase(libReference.fileName);
113863
+ }
113864
+ __name(getLibNameFromLibReference, "getLibNameFromLibReference");
113865
+ function getLibFileNameFromLibReference(libReference) {
113866
+ const libName = getLibNameFromLibReference(libReference);
113867
+ return libMap.get(libName);
113868
+ }
113869
+ __name(getLibFileNameFromLibReference, "getLibFileNameFromLibReference");
113870
+ function forEachResolvedProjectReference(resolvedProjectReferences, cb) {
113871
+ return forEachProjectReference(
113872
+ /*projectReferences*/
113873
+ void 0,
113874
+ resolvedProjectReferences,
113875
+ (resolvedRef, parent2) => resolvedRef && cb(resolvedRef, parent2)
113876
+ );
113877
+ }
113878
+ __name(forEachResolvedProjectReference, "forEachResolvedProjectReference");
113879
+ function forEachProjectReference(projectReferences, resolvedProjectReferences, cbResolvedRef, cbRef) {
113880
+ let seenResolvedRefs;
113881
+ return worker(
113882
+ projectReferences,
113883
+ resolvedProjectReferences,
113884
+ /*parent*/
113885
+ void 0
113886
+ );
113887
+ function worker(projectReferences2, resolvedProjectReferences2, parent2) {
113888
+ if (cbRef) {
113889
+ const result = cbRef(projectReferences2, parent2);
113890
+ if (result) return result;
113891
+ }
113892
+ let skipChildren;
113893
+ return forEach3(resolvedProjectReferences2, (resolvedRef, index2) => {
113894
+ if (resolvedRef && (seenResolvedRefs == null ? void 0 : seenResolvedRefs.has(resolvedRef.sourceFile.path))) {
113895
+ (skipChildren ?? (skipChildren = /* @__PURE__ */ new Set())).add(resolvedRef);
113896
+ return void 0;
113897
+ }
113898
+ const result = cbResolvedRef(resolvedRef, parent2, index2);
113899
+ if (result || !resolvedRef) return result;
113900
+ (seenResolvedRefs || (seenResolvedRefs = /* @__PURE__ */ new Set())).add(resolvedRef.sourceFile.path);
113901
+ }) || forEach3(resolvedProjectReferences2, (resolvedRef) => resolvedRef && !(skipChildren == null ? void 0 : skipChildren.has(resolvedRef)) ? worker(resolvedRef.commandLine.projectReferences, resolvedRef.references, resolvedRef) : void 0);
113902
+ }
113903
+ __name(worker, "worker");
113904
+ }
113905
+ __name(forEachProjectReference, "forEachProjectReference");
113906
+ function getOptionsSyntaxByArrayElementValue(optionsObject, name2, value1) {
113907
+ return optionsObject && getPropertyArrayElementValue(optionsObject, name2, value1);
113908
+ }
113909
+ __name(getOptionsSyntaxByArrayElementValue, "getOptionsSyntaxByArrayElementValue");
113910
+ function getPropertyArrayElementValue(objectLiteral, propKey, elementValue) {
113911
+ return forEachPropertyAssignment(objectLiteral, propKey, (property) => isArrayLiteralExpression(property.initializer) ? find2(property.initializer.elements, (element) => isStringLiteral(element) && element.text === elementValue) : void 0);
113912
+ }
113913
+ __name(getPropertyArrayElementValue, "getPropertyArrayElementValue");
113914
+ function getOptionsSyntaxByValue(optionsObject, name2, value1) {
113915
+ return forEachOptionsSyntaxByName(optionsObject, name2, (property) => isStringLiteral(property.initializer) && property.initializer.text === value1 ? property.initializer : void 0);
113916
+ }
113917
+ __name(getOptionsSyntaxByValue, "getOptionsSyntaxByValue");
113918
+ function forEachOptionsSyntaxByName(optionsObject, name2, callback) {
113919
+ return forEachPropertyAssignment(optionsObject, name2, callback);
113920
+ }
113921
+ __name(forEachOptionsSyntaxByName, "forEachOptionsSyntaxByName");
113747
113922
  function createBaseNodeFactory() {
113748
113923
  let NodeConstructor2;
113749
113924
  let TokenConstructor2;
@@ -117034,6 +117209,8 @@ ${lanes.join("\n")}
117034
117209
  );
117035
117210
  node.whenFalse = parenthesizerRules().parenthesizeBranchOfConditionalExpression(whenFalse);
117036
117211
  node.transformFlags |= propagateChildFlags(node.condition) | propagateChildFlags(node.questionToken) | propagateChildFlags(node.whenTrue) | propagateChildFlags(node.colonToken) | propagateChildFlags(node.whenFalse);
117212
+ node.flowNodeWhenFalse = void 0;
117213
+ node.flowNodeWhenTrue = void 0;
117037
117214
  return node;
117038
117215
  }
117039
117216
  __name(createConditionalExpression, "createConditionalExpression");
@@ -119473,7 +119650,7 @@ ${lanes.join("\n")}
119473
119650
  return isParenthesizedExpression(node) && nodeIsSynthesized(node) && nodeIsSynthesized(getSourceMapRange(node)) && nodeIsSynthesized(getCommentRange(node)) && !some(getSyntheticLeadingComments(node)) && !some(getSyntheticTrailingComments(node));
119474
119651
  }
119475
119652
  __name(isIgnorableParen, "isIgnorableParen");
119476
- function restoreOuterExpressions(outerExpression, innerExpression, kinds = 31) {
119653
+ function restoreOuterExpressions(outerExpression, innerExpression, kinds = 63) {
119477
119654
  if (outerExpression && isOuterExpression(outerExpression, kinds) && !isIgnorableParen(outerExpression)) {
119478
119655
  return updateOuterExpression(outerExpression, restoreOuterExpressions(outerExpression.expression, innerExpression));
119479
119656
  }
@@ -119517,7 +119694,7 @@ ${lanes.join("\n")}
119517
119694
  function createCallBinding(expression, recordTempVariable, languageVersion, cacheIdentifiers = false) {
119518
119695
  const callee = skipOuterExpressions(
119519
119696
  expression,
119520
- 31
119697
+ 63
119521
119698
  /* All */
119522
119699
  );
119523
119700
  let thisArg;
@@ -122952,7 +123129,7 @@ ${lanes.join("\n")}
122952
123129
  return type2;
122953
123130
  }
122954
123131
  __name(getJSDocTypeAssertionType, "getJSDocTypeAssertionType");
122955
- function isOuterExpression(node, kinds = 31) {
123132
+ function isOuterExpression(node, kinds = 63) {
122956
123133
  switch (node.kind) {
122957
123134
  case 217:
122958
123135
  if (kinds & -2147483648 && isJSDocTypeAssertion(node)) {
@@ -122961,8 +123138,9 @@ ${lanes.join("\n")}
122961
123138
  return (kinds & 1) !== 0;
122962
123139
  case 216:
122963
123140
  case 234:
122964
- case 238:
122965
123141
  return (kinds & 2) !== 0;
123142
+ case 238:
123143
+ return (kinds & (2 | 32)) !== 0;
122966
123144
  case 233:
122967
123145
  return (kinds & 16) !== 0;
122968
123146
  case 235:
@@ -122973,14 +123151,14 @@ ${lanes.join("\n")}
122973
123151
  return false;
122974
123152
  }
122975
123153
  __name(isOuterExpression, "isOuterExpression");
122976
- function skipOuterExpressions(node, kinds = 31) {
123154
+ function skipOuterExpressions(node, kinds = 63) {
122977
123155
  while (isOuterExpression(node, kinds)) {
122978
123156
  node = node.expression;
122979
123157
  }
122980
123158
  return node;
122981
123159
  }
122982
123160
  __name(skipOuterExpressions, "skipOuterExpressions");
122983
- function walkUpOuterExpressions(node, kinds = 31) {
123161
+ function walkUpOuterExpressions(node, kinds = 63) {
122984
123162
  let parent2 = node.parent;
122985
123163
  while (isOuterExpression(parent2, kinds)) {
122986
123164
  parent2 = parent2.parent;
@@ -132809,6 +132987,7 @@ ${lanes.join("\n")}
132809
132987
  const node = factory2.createExpressionWithTypeArguments(expression, typeArguments);
132810
132988
  const res = finishNode(node, pos);
132811
132989
  if (usedBrace) {
132990
+ skipWhitespace();
132812
132991
  parseExpected(
132813
132992
  20
132814
132993
  /* CloseBraceToken */
@@ -134285,6 +134464,14 @@ ${lanes.join("\n")}
134285
134464
  "esnext.iterator",
134286
134465
  "lib.esnext.iterator.d.ts"
134287
134466
  ],
134467
+ [
134468
+ "esnext.promise",
134469
+ "lib.esnext.promise.d.ts"
134470
+ ],
134471
+ [
134472
+ "esnext.float16",
134473
+ "lib.esnext.float16.d.ts"
134474
+ ],
134288
134475
  [
134289
134476
  "decorators",
134290
134477
  "lib.decorators.d.ts"
@@ -134626,6 +134813,7 @@ ${lanes.join("\n")}
134626
134813
  es2022: 7,
134627
134814
  esnext: 99,
134628
134815
  node16: 100,
134816
+ node18: 101,
134629
134817
  nodenext: 199,
134630
134818
  preserve: 200
134631
134819
  /* Preserve */
@@ -134881,6 +135069,23 @@ ${lanes.join("\n")}
134881
135069
  affectsBuildInfo: true,
134882
135070
  affectsSemanticDiagnostics: true
134883
135071
  },
135072
+ {
135073
+ name: "erasableSyntaxOnly",
135074
+ type: "boolean",
135075
+ category: Diagnostics.Interop_Constraints,
135076
+ description: Diagnostics.Do_not_allow_runtime_constructs_that_are_not_part_of_ECMAScript,
135077
+ defaultValueDescription: false,
135078
+ affectsBuildInfo: true,
135079
+ affectsSemanticDiagnostics: true
135080
+ },
135081
+ {
135082
+ name: "libReplacement",
135083
+ type: "boolean",
135084
+ affectsProgramStructure: true,
135085
+ category: Diagnostics.Language_and_Environment,
135086
+ description: Diagnostics.Enable_lib_replacement,
135087
+ defaultValueDescription: true
135088
+ },
134884
135089
  // Strict Type Checks
134885
135090
  {
134886
135091
  name: "strict",
@@ -139421,9 +139626,7 @@ ${lanes.join("\n")}
139421
139626
  __name(tryFileLookup, "tryFileLookup");
139422
139627
  function loadNodeModuleFromDirectory(extensions, candidate, onlyRecordFailures, state, considerPackageJson = true) {
139423
139628
  const packageInfo = considerPackageJson ? getPackageJsonInfo(candidate, onlyRecordFailures, state) : void 0;
139424
- const packageJsonContent = packageInfo && packageInfo.contents.packageJsonContent;
139425
- const versionPaths = packageInfo && getVersionPathsOfPackageJsonInfo(packageInfo, state);
139426
- return withPackageId(packageInfo, loadNodeModuleFromDirectoryWorker(extensions, candidate, onlyRecordFailures, state, packageJsonContent, versionPaths), state);
139629
+ return withPackageId(packageInfo, loadNodeModuleFromDirectoryWorker(extensions, candidate, onlyRecordFailures, state, packageInfo), state);
139427
139630
  }
139428
139631
  __name(loadNodeModuleFromDirectory, "loadNodeModuleFromDirectory");
139429
139632
  function getEntrypointsFromPackageJsonInfo(packageJsonInfo, options, host, cache5, resolveJs) {
@@ -139442,8 +139645,7 @@ ${lanes.join("\n")}
139442
139645
  /*onlyRecordFailures*/
139443
139646
  false,
139444
139647
  loadPackageJsonMainState,
139445
- packageJsonInfo.contents.packageJsonContent,
139446
- getVersionPathsOfPackageJsonInfo(packageJsonInfo, loadPackageJsonMainState)
139648
+ packageJsonInfo
139447
139649
  );
139448
139650
  entrypoints = append(entrypoints, mainResolution == null ? void 0 : mainResolution.path);
139449
139651
  if (features & 8 && packageJsonInfo.contents.packageJsonContent.exports) {
@@ -139673,13 +139875,14 @@ ${lanes.join("\n")}
139673
139875
  }
139674
139876
  }
139675
139877
  __name(getPackageJsonInfo, "getPackageJsonInfo");
139676
- function loadNodeModuleFromDirectoryWorker(extensions, candidate, onlyRecordFailures, state, jsonContent, versionPaths) {
139878
+ function loadNodeModuleFromDirectoryWorker(extensions, candidate, onlyRecordFailures, state, packageJson) {
139879
+ const versionPaths = packageJson && getVersionPathsOfPackageJsonInfo(packageJson, state);
139677
139880
  let packageFile;
139678
- if (jsonContent) {
139881
+ if (packageJson && arePathsEqual(packageJson == null ? void 0 : packageJson.packageDirectory, candidate, state.host)) {
139679
139882
  if (state.isConfigLookup) {
139680
- packageFile = readPackageJsonTSConfigField(jsonContent, candidate, state);
139883
+ packageFile = readPackageJsonTSConfigField(packageJson.contents.packageJsonContent, packageJson.packageDirectory, state);
139681
139884
  } else {
139682
- packageFile = extensions & 4 && readPackageJsonTypesFields(jsonContent, candidate, state) || extensions & (3 | 4) && readPackageJsonMainField(jsonContent, candidate, state) || void 0;
139885
+ packageFile = extensions & 4 && readPackageJsonTypesFields(packageJson.contents.packageJsonContent, packageJson.packageDirectory, state) || extensions & (3 | 4) && readPackageJsonMainField(packageJson.contents.packageJsonContent, packageJson.packageDirectory, state) || void 0;
139683
139886
  }
139684
139887
  }
139685
139888
  const loader3 = /* @__PURE__ */ __name((extensions2, candidate2, onlyRecordFailures2, state2) => {
@@ -139698,7 +139901,7 @@ ${lanes.join("\n")}
139698
139901
  const features = state2.features;
139699
139902
  const candidateIsFromPackageJsonField = state2.candidateIsFromPackageJsonField;
139700
139903
  state2.candidateIsFromPackageJsonField = true;
139701
- if ((jsonContent == null ? void 0 : jsonContent.type) !== "module") {
139904
+ if ((packageJson == null ? void 0 : packageJson.contents.packageJsonContent.type) !== "module") {
139702
139905
  state2.features &= ~32;
139703
139906
  }
139704
139907
  const result = nodeLoadModuleByRelativeName(
@@ -139987,6 +140190,7 @@ ${lanes.join("\n")}
139987
140190
  function getLoadModuleFromTargetExportOrImport(extensions, state, cache5, redirectedReference, moduleName, scope, isImports) {
139988
140191
  return loadModuleFromTargetExportOrImport;
139989
140192
  function loadModuleFromTargetExportOrImport(target, subpath, pattern, key) {
140193
+ var _a, _b;
139990
140194
  if (typeof target === "string") {
139991
140195
  if (!pattern && subpath.length > 0 && !endsWith(target, "/")) {
139992
140196
  if (state.traceEnabled) {
@@ -140015,6 +140219,8 @@ ${lanes.join("\n")}
140015
140219
  redirectedReference,
140016
140220
  state.conditions
140017
140221
  );
140222
+ (_a = state.failedLookupLocations) == null ? void 0 : _a.push(...result.failedLookupLocations ?? emptyArray);
140223
+ (_b = state.affectingLocations) == null ? void 0 : _b.push(...result.affectingLocations ?? emptyArray);
140018
140224
  return toSearchResult(result.resolvedModule ? {
140019
140225
  path: result.resolvedModule.resolvedFileName,
140020
140226
  extension: result.resolvedModule.extension,
@@ -140122,9 +140328,9 @@ ${lanes.join("\n")}
140122
140328
  void 0
140123
140329
  );
140124
140330
  function toAbsolutePath(path36) {
140125
- var _a, _b;
140331
+ var _a2, _b2;
140126
140332
  if (path36 === void 0) return path36;
140127
- return getNormalizedAbsolutePath(path36, (_b = (_a = state.host).getCurrentDirectory) == null ? void 0 : _b.call(_a));
140333
+ return getNormalizedAbsolutePath(path36, (_b2 = (_a2 = state.host).getCurrentDirectory) == null ? void 0 : _b2.call(_a2));
140128
140334
  }
140129
140335
  __name(toAbsolutePath, "toAbsolutePath");
140130
140336
  function combineDirectoryPath(root, dir) {
@@ -140132,14 +140338,14 @@ ${lanes.join("\n")}
140132
140338
  }
140133
140339
  __name(combineDirectoryPath, "combineDirectoryPath");
140134
140340
  function tryLoadInputFileForPath(finalPath, entry, packagePath, isImports2) {
140135
- var _a, _b, _c, _d;
140341
+ var _a2, _b2, _c, _d;
140136
140342
  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)) {
140137
140343
  const getCanonicalFileName = hostGetCanonicalFileName({
140138
140344
  useCaseSensitiveFileNames: /* @__PURE__ */ __name(() => useCaseSensitiveFileNames(state), "useCaseSensitiveFileNames")
140139
140345
  });
140140
140346
  const commonSourceDirGuesses = [];
140141
140347
  if (state.compilerOptions.rootDir || state.compilerOptions.composite && state.compilerOptions.configFilePath) {
140142
- const commonDir = toAbsolutePath(getCommonSourceDirectory(state.compilerOptions, () => [], ((_b = (_a = state.host).getCurrentDirectory) == null ? void 0 : _b.call(_a)) || "", getCanonicalFileName));
140348
+ const commonDir = toAbsolutePath(getCommonSourceDirectory(state.compilerOptions, () => [], ((_b2 = (_a2 = state.host).getCurrentDirectory) == null ? void 0 : _b2.call(_a2)) || "", getCanonicalFileName));
140143
140349
  commonSourceDirGuesses.push(commonDir);
140144
140350
  } else if (state.requestContainingDirectory) {
140145
140351
  const requestingFile = toAbsolutePath(combinePaths(state.requestContainingDirectory, "index.ts"));
@@ -140207,8 +140413,8 @@ ${lanes.join("\n")}
140207
140413
  }
140208
140414
  return void 0;
140209
140415
  function getOutputDirectoriesForBaseDirectory(commonSourceDirGuess) {
140210
- var _a2, _b2;
140211
- const currentDir = state.compilerOptions.configFile ? ((_b2 = (_a2 = state.host).getCurrentDirectory) == null ? void 0 : _b2.call(_a2)) || "" : commonSourceDirGuess;
140416
+ var _a3, _b3;
140417
+ const currentDir = state.compilerOptions.configFile ? ((_b3 = (_a3 = state.host).getCurrentDirectory) == null ? void 0 : _b3.call(_a3)) || "" : commonSourceDirGuess;
140212
140418
  const candidateDirectories = [];
140213
140419
  if (state.compilerOptions.declarationDir) {
140214
140420
  candidateDirectories.push(toAbsolutePath(combineDirectoryPath(currentDir, state.compilerOptions.declarationDir)));
@@ -140262,7 +140468,7 @@ ${lanes.join("\n")}
140262
140468
  }
140263
140469
  __name(loadModuleFromNearestNodeModulesDirectoryTypesScope, "loadModuleFromNearestNodeModulesDirectoryTypesScope");
140264
140470
  function loadModuleFromNearestNodeModulesDirectoryWorker(extensions, moduleName, directory, state, typesScopeOnly, cache5, redirectedReference) {
140265
- const mode = state.features === 0 ? void 0 : state.features & 32 ? 99 : 1;
140471
+ const mode = state.features === 0 ? void 0 : state.features & 32 || state.conditions.includes("import") ? 99 : 1;
140266
140472
  const priorityExtensions = extensions & (1 | 4);
140267
140473
  const secondaryExtensions = extensions & ~(1 | 4);
140268
140474
  if (priorityExtensions) {
@@ -140335,12 +140541,12 @@ ${lanes.join("\n")}
140335
140541
  if (fromFile) {
140336
140542
  return noPackageId(fromFile);
140337
140543
  }
140338
- const fromDirectory = loadNodeModuleFromDirectoryWorker(extensions, candidate, !nodeModulesDirectoryExists, state, packageInfo.contents.packageJsonContent, getVersionPathsOfPackageJsonInfo(packageInfo, state));
140544
+ const fromDirectory = loadNodeModuleFromDirectoryWorker(extensions, candidate, !nodeModulesDirectoryExists, state, packageInfo);
140339
140545
  return withPackageId(packageInfo, fromDirectory, state);
140340
140546
  }
140341
140547
  const loader3 = /* @__PURE__ */ __name((extensions2, candidate2, onlyRecordFailures, state2) => {
140342
- let pathAndExtension = (rest || !(state2.features & 32)) && loadModuleFromFile(extensions2, candidate2, onlyRecordFailures, state2) || loadNodeModuleFromDirectoryWorker(extensions2, candidate2, onlyRecordFailures, state2, packageInfo && packageInfo.contents.packageJsonContent, packageInfo && getVersionPathsOfPackageJsonInfo(packageInfo, state2));
140343
- if (!pathAndExtension && packageInfo && (packageInfo.contents.packageJsonContent.exports === void 0 || packageInfo.contents.packageJsonContent.exports === null) && state2.features & 32) {
140548
+ let pathAndExtension = (rest || !(state2.features & 32)) && loadModuleFromFile(extensions2, candidate2, onlyRecordFailures, state2) || loadNodeModuleFromDirectoryWorker(extensions2, candidate2, onlyRecordFailures, state2, packageInfo);
140549
+ if (!pathAndExtension && !rest && packageInfo && (packageInfo.contents.packageJsonContent.exports === void 0 || packageInfo.contents.packageJsonContent.exports === null) && state2.features & 32) {
140344
140550
  pathAndExtension = loadModuleFromFile(extensions2, combinePaths(candidate2, "index.js"), onlyRecordFailures, state2);
140345
140551
  }
140346
140552
  return withPackageId(packageInfo, pathAndExtension, state2);
@@ -140815,6 +141021,7 @@ ${lanes.join("\n")}
140815
141021
  var preSwitchCaseFlow;
140816
141022
  var activeLabelList;
140817
141023
  var hasExplicitReturn;
141024
+ var inReturnPosition;
140818
141025
  var hasFlowEffects;
140819
141026
  var emitFlags;
140820
141027
  var inStrictMode;
@@ -140890,6 +141097,7 @@ ${lanes.join("\n")}
140890
141097
  currentExceptionTarget = void 0;
140891
141098
  activeLabelList = void 0;
140892
141099
  hasExplicitReturn = false;
141100
+ inReturnPosition = false;
140893
141101
  hasFlowEffects = false;
140894
141102
  inAssignmentPattern = false;
140895
141103
  emitFlags = 0;
@@ -141149,6 +141357,8 @@ ${lanes.join("\n")}
141149
141357
  const saveContainer = container;
141150
141358
  const saveThisParentContainer = thisParentContainer;
141151
141359
  const savedBlockScopeContainer = blockScopeContainer;
141360
+ const savedInReturnPosition = inReturnPosition;
141361
+ if (node.kind === 219 && node.body.kind !== 241) inReturnPosition = true;
141152
141362
  if (containerFlags & 1) {
141153
141363
  if (node.kind !== 219) {
141154
141364
  thisParentContainer = container;
@@ -141230,6 +141440,7 @@ ${lanes.join("\n")}
141230
141440
  } else {
141231
141441
  bindChildren(node);
141232
141442
  }
141443
+ inReturnPosition = savedInReturnPosition;
141233
141444
  container = saveContainer;
141234
141445
  thisParentContainer = saveThisParentContainer;
141235
141446
  blockScopeContainer = savedBlockScopeContainer;
@@ -141255,6 +141466,9 @@ ${lanes.join("\n")}
141255
141466
  const saveInAssignmentPattern = inAssignmentPattern;
141256
141467
  inAssignmentPattern = false;
141257
141468
  if (checkUnreachable(node)) {
141469
+ if (canHaveFlowNode(node) && node.flowNode) {
141470
+ node.flowNode = void 0;
141471
+ }
141258
141472
  bindEachChild(node);
141259
141473
  bindJSDoc(node);
141260
141474
  inAssignmentPattern = saveInAssignmentPattern;
@@ -141456,7 +141670,9 @@ ${lanes.join("\n")}
141456
141670
  case 36:
141457
141671
  case 37:
141458
141672
  case 38:
141459
- return isNarrowableOperand(expr.left) || isNarrowableOperand(expr.right) || isNarrowingTypeofOperands(expr.right, expr.left) || isNarrowingTypeofOperands(expr.left, expr.right) || isBooleanLiteral(expr.right) && isNarrowingExpression(expr.left) || isBooleanLiteral(expr.left) && isNarrowingExpression(expr.right);
141673
+ const left = skipParentheses(expr.left);
141674
+ const right = skipParentheses(expr.right);
141675
+ return isNarrowableOperand(left) || isNarrowableOperand(right) || isNarrowingTypeofOperands(right, left) || isNarrowingTypeofOperands(left, right) || isBooleanLiteral(right) && isNarrowingExpression(left) || isBooleanLiteral(left) && isNarrowingExpression(right);
141460
141676
  case 104:
141461
141677
  return isNarrowableOperand(expr.left);
141462
141678
  case 103:
@@ -141677,13 +141893,16 @@ ${lanes.join("\n")}
141677
141893
  function bindForStatement(node) {
141678
141894
  const preLoopLabel = setContinueTarget(node, createLoopLabel());
141679
141895
  const preBodyLabel = createBranchLabel();
141896
+ const preIncrementorLabel = createBranchLabel();
141680
141897
  const postLoopLabel = createBranchLabel();
141681
141898
  bind2(node.initializer);
141682
141899
  addAntecedent(preLoopLabel, currentFlow);
141683
141900
  currentFlow = preLoopLabel;
141684
141901
  bindCondition(node.condition, preBodyLabel, postLoopLabel);
141685
141902
  currentFlow = finishFlowLabel(preBodyLabel);
141686
- bindIterativeStatement(node.statement, postLoopLabel, preLoopLabel);
141903
+ bindIterativeStatement(node.statement, postLoopLabel, preIncrementorLabel);
141904
+ addAntecedent(preIncrementorLabel, currentFlow);
141905
+ currentFlow = finishFlowLabel(preIncrementorLabel);
141687
141906
  bind2(node.incrementor);
141688
141907
  addAntecedent(preLoopLabel, currentFlow);
141689
141908
  currentFlow = finishFlowLabel(postLoopLabel);
@@ -141723,7 +141942,10 @@ ${lanes.join("\n")}
141723
141942
  }
141724
141943
  __name(bindIfStatement, "bindIfStatement");
141725
141944
  function bindReturnOrThrow(node) {
141945
+ const savedInReturnPosition = inReturnPosition;
141946
+ inReturnPosition = true;
141726
141947
  bind2(node.expression);
141948
+ inReturnPosition = savedInReturnPosition;
141727
141949
  if (node.kind === 253) {
141728
141950
  hasExplicitReturn = true;
141729
141951
  if (currentReturnTarget) {
@@ -142117,10 +142339,16 @@ ${lanes.join("\n")}
142117
142339
  hasFlowEffects = false;
142118
142340
  bindCondition(node.condition, trueLabel, falseLabel);
142119
142341
  currentFlow = finishFlowLabel(trueLabel);
142342
+ if (inReturnPosition) {
142343
+ node.flowNodeWhenTrue = currentFlow;
142344
+ }
142120
142345
  bind2(node.questionToken);
142121
142346
  bind2(node.whenTrue);
142122
142347
  addAntecedent(postExpressionLabel, currentFlow);
142123
142348
  currentFlow = finishFlowLabel(falseLabel);
142349
+ if (inReturnPosition) {
142350
+ node.flowNodeWhenFalse = currentFlow;
142351
+ }
142124
142352
  bind2(node.colonToken);
142125
142353
  bind2(node.whenFalse);
142126
142354
  addAntecedent(postExpressionLabel, currentFlow);
@@ -146070,6 +146298,7 @@ ${lanes.join("\n")}
146070
146298
  getNumberLiteralType,
146071
146299
  getBigIntType: /* @__PURE__ */ __name(() => bigintType, "getBigIntType"),
146072
146300
  getBigIntLiteralType,
146301
+ getUnknownType: /* @__PURE__ */ __name(() => unknownType2, "getUnknownType"),
146073
146302
  createPromiseType,
146074
146303
  createArrayType,
146075
146304
  getElementTypeOfArrayType,
@@ -146194,8 +146423,14 @@ ${lanes.join("\n")}
146194
146423
  getMemberOverrideModifierStatus,
146195
146424
  isTypeParameterPossiblyReferenced,
146196
146425
  typeHasCallOrConstructSignatures,
146197
- getSymbolFlags
146426
+ getSymbolFlags,
146427
+ getTypeArgumentsForResolvedSignature
146198
146428
  };
146429
+ function getTypeArgumentsForResolvedSignature(signature) {
146430
+ if (signature.mapper === void 0) return void 0;
146431
+ return instantiateTypes((signature.target || signature).typeParameters, signature.mapper);
146432
+ }
146433
+ __name(getTypeArgumentsForResolvedSignature, "getTypeArgumentsForResolvedSignature");
146199
146434
  function getCandidateSignaturesForStringLiteralCompletions(call, editingArgument) {
146200
146435
  const candidatesSet = /* @__PURE__ */ new Set();
146201
146436
  const candidates = [];
@@ -147781,9 +148016,9 @@ ${lanes.join("\n")}
147781
148016
  const containerKind = grandparent.parent.kind;
147782
148017
  if (containerKind === 264 && heritageKind === 96) {
147783
148018
  error22(errorLocation, Diagnostics.An_interface_cannot_extend_a_primitive_type_like_0_It_can_only_extend_other_named_object_types, unescapeLeadingUnderscores(name2));
147784
- } else if (containerKind === 263 && heritageKind === 96) {
148019
+ } else if (isClassLike(grandparent.parent) && heritageKind === 96) {
147785
148020
  error22(errorLocation, Diagnostics.A_class_cannot_extend_a_primitive_type_like_0_Classes_can_only_extend_constructable_values, unescapeLeadingUnderscores(name2));
147786
- } else if (containerKind === 263 && heritageKind === 119) {
148021
+ } else if (isClassLike(grandparent.parent) && heritageKind === 119) {
147787
148022
  error22(errorLocation, Diagnostics.A_class_cannot_implement_a_primitive_type_like_0_It_can_only_implement_other_named_object_types, unescapeLeadingUnderscores(name2));
147788
148023
  }
147789
148024
  } else {
@@ -149008,7 +149243,7 @@ ${lanes.join("\n")}
149008
149243
  moduleReference
149009
149244
  );
149010
149245
  }
149011
- if (errorNode && (moduleResolutionKind === 3 || moduleResolutionKind === 99)) {
149246
+ if (errorNode && (moduleKind === 100 || moduleKind === 101)) {
149012
149247
  const isSyncImport = currentSourceFile.impliedNodeFormat === 1 && !findAncestor(location2, isImportCall) || !!findAncestor(location2, isImportEqualsDeclaration);
149013
149248
  const overrideHost = findAncestor(location2, (l) => isImportTypeNode(l) || isExportDeclaration(l) || isImportDeclaration(l) || isJSDocImportTag(l));
149014
149249
  if (isSyncImport && sourceFile.impliedNodeFormat === 99 && !hasResolutionModeOverride(overrideHost)) {
@@ -150423,12 +150658,7 @@ ${lanes.join("\n")}
150423
150658
  enterNewScope(context, node) {
150424
150659
  if (isFunctionLike(node) || isJSDocSignature(node)) {
150425
150660
  const signature = getSignatureFromDeclaration(node);
150426
- const expandedParams = getExpandedParameters(
150427
- signature,
150428
- /*skipUnionExpanding*/
150429
- true
150430
- )[0];
150431
- return enterNewScope(context, node, expandedParams, signature.typeParameters);
150661
+ return enterNewScope(context, node, signature.parameters, signature.typeParameters);
150432
150662
  } else {
150433
150663
  const typeParameters = isConditionalTypeNode(node) ? getInferTypeParameters(node) : [
150434
150664
  getDeclaredTypeOfTypeParameter(getSymbolOfDeclaration(node.typeParameter))
@@ -151165,7 +151395,7 @@ ${lanes.join("\n")}
151165
151395
  function shouldWriteTypeOfFunctionSymbol() {
151166
151396
  var _a3;
151167
151397
  const isStaticMethodSymbol = !!(symbol.flags & 8192) && // typeof static method
151168
- some(symbol.declarations, (declaration) => isStatic(declaration));
151398
+ some(symbol.declarations, (declaration) => isStatic(declaration) && !isLateBindableIndexSignature(getNameOfDeclaration(declaration)));
151169
151399
  const isNonLocalFunctionSymbol = !!(symbol.flags & 16) && (symbol.parent || // is exported function symbol
151170
151400
  forEach3(
151171
151401
  symbol.declarations,
@@ -151483,6 +151713,40 @@ ${lanes.join("\n")}
151483
151713
  return ids;
151484
151714
  }
151485
151715
  __name(getAccessStack, "getAccessStack");
151716
+ function indexInfoToObjectComputedNamesOrSignatureDeclaration(indexInfo, context2, typeNode) {
151717
+ if (indexInfo.components) {
151718
+ const allComponentComputedNamesSerializable = every(indexInfo.components, (e) => {
151719
+ var _a2;
151720
+ return !!(e.name && isComputedPropertyName(e.name) && isEntityNameExpression(e.name.expression) && context2.enclosingDeclaration && ((_a2 = isEntityNameVisible(
151721
+ e.name.expression,
151722
+ context2.enclosingDeclaration,
151723
+ /*shouldComputeAliasToMakeVisible*/
151724
+ false
151725
+ )) == null ? void 0 : _a2.accessibility) === 0);
151726
+ });
151727
+ if (allComponentComputedNamesSerializable) {
151728
+ const newComponents = filter6(indexInfo.components, (e) => {
151729
+ return !hasLateBindableName(e);
151730
+ });
151731
+ return map4(newComponents, (e) => {
151732
+ trackComputedName(e.name.expression, context2.enclosingDeclaration, context2);
151733
+ return setTextRange2(context2, factory.createPropertySignature(indexInfo.isReadonly ? [
151734
+ factory.createModifier(
151735
+ 148
151736
+ /* ReadonlyKeyword */
151737
+ )
151738
+ ] : void 0, e.name, (isPropertySignature(e) || isPropertyDeclaration(e) || isMethodSignature(e) || isMethodDeclaration(e) || isGetAccessor(e) || isSetAccessor(e)) && e.questionToken ? factory.createToken(
151739
+ 58
151740
+ /* QuestionToken */
151741
+ ) : void 0, typeNode || typeToTypeNodeHelper(getTypeOfSymbol(e.symbol), context2)), e);
151742
+ });
151743
+ }
151744
+ }
151745
+ return [
151746
+ indexInfoToIndexSignatureDeclarationHelper(indexInfo, context2, typeNode)
151747
+ ];
151748
+ }
151749
+ __name(indexInfoToObjectComputedNamesOrSignatureDeclaration, "indexInfoToObjectComputedNamesOrSignatureDeclaration");
151486
151750
  function createTypeNodesFromResolvedType(resolvedType) {
151487
151751
  if (checkTruncationLength(context)) {
151488
151752
  if (context.flags & 1) {
@@ -151511,7 +151775,7 @@ ${lanes.join("\n")}
151511
151775
  typeElements.push(signatureToSignatureDeclarationHelper(signature, 180, context));
151512
151776
  }
151513
151777
  for (const info of resolvedType.indexInfos) {
151514
- typeElements.push(indexInfoToIndexSignatureDeclarationHelper(info, context, resolvedType.objectFlags & 1024 ? createElidedInformationPlaceholder(context) : void 0));
151778
+ typeElements.push(...indexInfoToObjectComputedNamesOrSignatureDeclaration(info, context, resolvedType.objectFlags & 1024 ? createElidedInformationPlaceholder(context) : void 0));
151515
151779
  }
151516
151780
  const properties = resolvedType.properties;
151517
151781
  if (!properties) {
@@ -152305,7 +152569,7 @@ ${lanes.join("\n")}
152305
152569
  if (!context.tracker.canTrackSymbol) return;
152306
152570
  const firstIdentifier = getFirstIdentifier(accessExpression);
152307
152571
  const name2 = resolveName(
152308
- firstIdentifier,
152572
+ enclosingDeclaration,
152309
152573
  firstIdentifier.escapedText,
152310
152574
  111551 | 1048576,
152311
152575
  /*nameNotFoundMessage*/
@@ -152320,6 +152584,24 @@ ${lanes.join("\n")}
152320
152584
  111551
152321
152585
  /* Value */
152322
152586
  );
152587
+ } else {
152588
+ const fallback2 = resolveName(
152589
+ firstIdentifier,
152590
+ firstIdentifier.escapedText,
152591
+ 111551 | 1048576,
152592
+ /*nameNotFoundMessage*/
152593
+ void 0,
152594
+ /*isUse*/
152595
+ true
152596
+ );
152597
+ if (fallback2) {
152598
+ context.tracker.trackSymbol(
152599
+ fallback2,
152600
+ enclosingDeclaration,
152601
+ 111551
152602
+ /* Value */
152603
+ );
152604
+ }
152323
152605
  }
152324
152606
  }
152325
152607
  __name(trackComputedName, "trackComputedName");
@@ -160130,12 +160412,13 @@ ${lanes.join("\n")}
160130
160412
  );
160131
160413
  }
160132
160414
  __name(getIndexSymbolFromSymbolTable, "getIndexSymbolFromSymbolTable");
160133
- function createIndexInfo(keyType, type2, isReadonly, declaration) {
160415
+ function createIndexInfo(keyType, type2, isReadonly, declaration, components) {
160134
160416
  return {
160135
160417
  keyType,
160136
160418
  type: type2,
160137
160419
  isReadonly,
160138
- declaration
160420
+ declaration,
160421
+ components
160139
160422
  };
160140
160423
  }
160141
160424
  __name(createIndexInfo, "createIndexInfo");
@@ -160707,6 +160990,9 @@ ${lanes.join("\n")}
160707
160990
  case "Number":
160708
160991
  checkNoTypeArguments(node);
160709
160992
  return numberType2;
160993
+ case "BigInt":
160994
+ checkNoTypeArguments(node);
160995
+ return bigintType;
160710
160996
  case "Boolean":
160711
160997
  checkNoTypeArguments(node);
160712
160998
  return booleanType2;
@@ -163673,7 +163959,7 @@ ${lanes.join("\n")}
163673
163959
  }
163674
163960
  __name(getSpreadSymbol, "getSpreadSymbol");
163675
163961
  function getIndexInfoWithReadonly(info, readonly) {
163676
- return info.isReadonly !== readonly ? createIndexInfo(info.keyType, info.type, readonly, info.declaration) : info;
163962
+ return info.isReadonly !== readonly ? createIndexInfo(info.keyType, info.type, readonly, info.declaration, info.components) : info;
163677
163963
  }
163678
163964
  __name(getIndexInfoWithReadonly, "getIndexInfoWithReadonly");
163679
163965
  function createLiteralType(flags, value1, symbol, regularType) {
@@ -164530,7 +164816,7 @@ ${lanes.join("\n")}
164530
164816
  }
164531
164817
  __name(getRestrictiveInstantiation, "getRestrictiveInstantiation");
164532
164818
  function instantiateIndexInfo(info, mapper) {
164533
- return createIndexInfo(info.keyType, instantiateType(info.type, mapper), info.isReadonly, info.declaration);
164819
+ return createIndexInfo(info.keyType, instantiateType(info.type, mapper), info.isReadonly, info.declaration, info.components);
164534
164820
  }
164535
164821
  __name(instantiateIndexInfo, "instantiateIndexInfo");
164536
164822
  function isContextSensitive(node) {
@@ -169167,7 +169453,7 @@ ${lanes.join("\n")}
169167
169453
  }
169168
169454
  }
169169
169455
  }
169170
- const result = createAnonymousType(type2.symbol, members, emptyArray, emptyArray, sameMap(getIndexInfosOfType(type2), (info) => createIndexInfo(info.keyType, getWidenedType(info.type), info.isReadonly)));
169456
+ const result = createAnonymousType(type2.symbol, members, emptyArray, emptyArray, sameMap(getIndexInfosOfType(type2), (info) => createIndexInfo(info.keyType, getWidenedType(info.type), info.isReadonly, info.declaration, info.components)));
169171
169457
  result.objectFlags |= getObjectFlags(type2) & (4096 | 262144);
169172
169458
  return result;
169173
169459
  }
@@ -170810,6 +171096,7 @@ ${lanes.join("\n")}
170810
171096
  return target.kind === 108;
170811
171097
  case 235:
170812
171098
  case 217:
171099
+ case 238:
170813
171100
  return isMatchingReference(source.expression, target);
170814
171101
  case 211:
170815
171102
  case 212:
@@ -173018,6 +173305,7 @@ ${lanes.join("\n")}
173018
173305
  if (checkDerived) {
173019
173306
  return filterType(type2, (t) => !isTypeDerivedFrom(t, candidate));
173020
173307
  }
173308
+ type2 = type2.flags & 2 ? unknownUnionType : type2;
173021
173309
  const trueType2 = getNarrowedType(
173022
173310
  type2,
173023
173311
  candidate,
@@ -173026,7 +173314,7 @@ ${lanes.join("\n")}
173026
173314
  /*checkDerived*/
173027
173315
  false
173028
173316
  );
173029
- return filterType(type2, (t) => !isTypeSubsetOf(t, trueType2));
173317
+ return recombineUnknownType(filterType(type2, (t) => !isTypeSubsetOf(t, trueType2)));
173030
173318
  }
173031
173319
  if (type2.flags & 3) {
173032
173320
  return candidate;
@@ -173146,6 +173434,7 @@ ${lanes.join("\n")}
173146
173434
  return narrowTypeByCallExpression(type2, expr, assumeTrue);
173147
173435
  case 217:
173148
173436
  case 235:
173437
+ case 238:
173149
173438
  return narrowType(type2, expr.expression, assumeTrue);
173150
173439
  case 226:
173151
173440
  return narrowTypeByBinaryExpression(type2, expr, assumeTrue);
@@ -173596,8 +173885,9 @@ ${lanes.join("\n")}
173596
173885
  }
173597
173886
  if (isJsxOpeningFragment(node)) {
173598
173887
  const file = getSourceFileOfNode(node);
173599
- const localJsxNamespace = getLocalJsxNamespace(file);
173600
- if (localJsxNamespace) {
173888
+ const entity = getJsxFactoryEntity(file);
173889
+ if (entity) {
173890
+ const localJsxNamespace = getFirstIdentifier(entity).escapedText;
173601
173891
  resolveName(
173602
173892
  jsxFactoryLocation,
173603
173893
  localJsxNamespace,
@@ -176072,12 +176362,23 @@ ${lanes.join("\n")}
176072
176362
  );
176073
176363
  }
176074
176364
  __name(isSymbolWithSymbolName, "isSymbolWithSymbolName");
176365
+ function isSymbolWithComputedName(symbol) {
176366
+ var _a;
176367
+ const firstDecl = (_a = symbol.declarations) == null ? void 0 : _a[0];
176368
+ return firstDecl && isNamedDeclaration(firstDecl) && isComputedPropertyName(firstDecl.name);
176369
+ }
176370
+ __name(isSymbolWithComputedName, "isSymbolWithComputedName");
176075
176371
  function getObjectLiteralIndexInfo(isReadonly, offset, properties, keyType) {
176372
+ var _a;
176076
176373
  const propTypes = [];
176374
+ let components;
176077
176375
  for (let i = offset; i < properties.length; i++) {
176078
176376
  const prop = properties[i];
176079
176377
  if (keyType === stringType2 && !isSymbolWithSymbolName(prop) || keyType === numberType2 && isSymbolWithNumericName(prop) || keyType === esSymbolType && isSymbolWithSymbolName(prop)) {
176080
176378
  propTypes.push(getTypeOfSymbol(properties[i]));
176379
+ if (isSymbolWithComputedName(properties[i])) {
176380
+ components = append(components, (_a = properties[i].declarations) == null ? void 0 : _a[0]);
176381
+ }
176081
176382
  }
176082
176383
  }
176083
176384
  const unionType2 = propTypes.length ? getUnionType(
@@ -176085,7 +176386,14 @@ ${lanes.join("\n")}
176085
176386
  2
176086
176387
  /* Subtype */
176087
176388
  ) : undefinedType2;
176088
- return createIndexInfo(keyType, unionType2, isReadonly);
176389
+ return createIndexInfo(
176390
+ keyType,
176391
+ unionType2,
176392
+ isReadonly,
176393
+ /*declaration*/
176394
+ void 0,
176395
+ components
176396
+ );
176089
176397
  }
176090
176398
  __name(getObjectLiteralIndexInfo, "getObjectLiteralIndexInfo");
176091
176399
  function getImmediateAliasedSymbol(symbol) {
@@ -176702,6 +177010,9 @@ ${lanes.join("\n")}
176702
177010
  }
176703
177011
  __name(getJsxElementPropertiesName, "getJsxElementPropertiesName");
176704
177012
  function getJsxElementChildrenPropertyName(jsxNamespace) {
177013
+ if (compilerOptions.jsx === 4 || compilerOptions.jsx === 5) {
177014
+ return "children";
177015
+ }
176705
177016
  return getNameFromJsxElementAttributesContainer(JsxNames.ElementChildrenAttributeNameContainer, jsxNamespace);
176706
177017
  }
176707
177018
  __name(getJsxElementChildrenPropertyName, "getJsxElementChildrenPropertyName");
@@ -178466,8 +178777,8 @@ ${lanes.join("\n")}
178466
178777
  }
178467
178778
  __name(checkApplicableSignatureForJsxCallLikeElement, "checkApplicableSignatureForJsxCallLikeElement");
178468
178779
  function getEffectiveCheckNode(argument) {
178469
- argument = skipParentheses(argument);
178470
- return isSatisfiesExpression(argument) ? skipParentheses(argument.expression) : argument;
178780
+ const flags = isInJSFile(argument) ? 1 | 32 | -2147483648 : 1 | 32;
178781
+ return skipOuterExpressions(argument, flags);
178471
178782
  }
178472
178783
  __name(getEffectiveCheckNode, "getEffectiveCheckNode");
178473
178784
  function getSignatureApplicabilityError(node, args, signature, relation, checkMode, reportErrors2, containingMessageChain, inferenceContext) {
@@ -178930,11 +179241,16 @@ ${lanes.join("\n")}
178930
179241
  if (!result) {
178931
179242
  result = chooseOverload(candidates, assignableRelation, isSingleNonGenericCandidate, signatureHelpTrailingComma);
178932
179243
  }
179244
+ const links = getNodeLinks(node);
179245
+ if (links.resolvedSignature !== resolvingSignature && !candidatesOutArray) {
179246
+ Debug.assert(links.resolvedSignature);
179247
+ return links.resolvedSignature;
179248
+ }
178933
179249
  if (result) {
178934
179250
  return result;
178935
179251
  }
178936
179252
  result = getCandidateForOverloadFailure(node, candidates, args, !!candidatesOutArray, checkMode);
178937
- getNodeLinks(node).resolvedSignature = result;
179253
+ links.resolvedSignature = result;
178938
179254
  if (reportErrors2) {
178939
179255
  if (!headMessage && isInstanceof) {
178940
179256
  headMessage = Diagnostics.The_left_hand_side_of_an_instanceof_expression_must_be_assignable_to_the_first_argument_of_the_right_hand_side_s_Symbol_hasInstance_method;
@@ -179978,7 +180294,7 @@ ${lanes.join("\n")}
179978
180294
  resolutionStart = resolutionTargets.length;
179979
180295
  }
179980
180296
  links.resolvedSignature = resolvingSignature;
179981
- let result = resolveSignature(
180297
+ const result = resolveSignature(
179982
180298
  node,
179983
180299
  candidatesOutArray,
179984
180300
  checkMode || 0
@@ -179986,9 +180302,6 @@ ${lanes.join("\n")}
179986
180302
  );
179987
180303
  resolutionStart = saveResolutionStart;
179988
180304
  if (result !== resolvingSignature) {
179989
- if (links.resolvedSignature !== resolvingSignature) {
179990
- result = links.resolvedSignature;
179991
- }
179992
180305
  links.resolvedSignature = flowLoopStart === flowLoopCount ? result : cached;
179993
180306
  }
179994
180307
  return result;
@@ -180631,12 +180944,12 @@ ${lanes.join("\n")}
180631
180944
  }
180632
180945
  __name(checkNewTargetMetaProperty, "checkNewTargetMetaProperty");
180633
180946
  function checkImportMetaProperty(node) {
180634
- if (moduleKind === 100 || moduleKind === 199) {
180947
+ if (100 <= moduleKind && moduleKind <= 199) {
180635
180948
  if (getSourceFileOfNode(node).impliedNodeFormat !== 99) {
180636
180949
  error22(node, Diagnostics.The_import_meta_meta_property_is_not_allowed_in_files_which_will_build_into_CommonJS_output);
180637
180950
  }
180638
180951
  } else if (moduleKind < 6 && moduleKind !== 4) {
180639
- error22(node, Diagnostics.The_import_meta_meta_property_is_only_allowed_when_the_module_option_is_es2020_es2022_esnext_system_node16_or_nodenext);
180952
+ error22(node, Diagnostics.The_import_meta_meta_property_is_only_allowed_when_the_module_option_is_es2020_es2022_esnext_system_node16_node18_or_nodenext);
180640
180953
  }
180641
180954
  const file = getSourceFileOfNode(node);
180642
180955
  Debug.assert(!!(file.flags & 8388608), "Containing file is missing import meta node flag.");
@@ -181623,7 +181936,7 @@ ${lanes.join("\n")}
181623
181936
  }
181624
181937
  return !someType(operandConstraint, (t) => getTypeFacts(t, notEqualFacts) === notEqualFacts);
181625
181938
  }
181626
- const type2 = checkExpressionCached(node.expression);
181939
+ const type2 = getBaseConstraintOrType(checkExpressionCached(node.expression));
181627
181940
  if (!isLiteralType(type2)) {
181628
181941
  return false;
181629
181942
  }
@@ -181912,19 +182225,7 @@ ${lanes.join("\n")}
181912
182225
  const exprType = checkExpression(node.body);
181913
182226
  const returnOrPromisedType = returnType && unwrapReturnType(returnType, functionFlags);
181914
182227
  if (returnOrPromisedType) {
181915
- const effectiveCheckNode = getEffectiveCheckNode(node.body);
181916
- if ((functionFlags & 3) === 2) {
181917
- const awaitedType = checkAwaitedType(
181918
- exprType,
181919
- /*withAlias*/
181920
- false,
181921
- effectiveCheckNode,
181922
- Diagnostics.The_return_type_of_an_async_function_must_either_be_a_valid_promise_or_must_not_contain_a_callable_then_member
181923
- );
181924
- checkTypeAssignableToAndOptionallyElaborate(awaitedType, returnOrPromisedType, effectiveCheckNode, effectiveCheckNode);
181925
- } else {
181926
- checkTypeAssignableToAndOptionallyElaborate(exprType, returnOrPromisedType, effectiveCheckNode, effectiveCheckNode);
181927
- }
182228
+ checkReturnExpression(node, returnOrPromisedType, node.body, node.body, exprType);
181928
182229
  }
181929
182230
  }
181930
182231
  }
@@ -181978,7 +182279,7 @@ ${lanes.join("\n")}
181978
182279
  }
181979
182280
  if (isReadonlySymbol(symbol)) {
181980
182281
  if (symbol.flags & 4 && isAccessExpression(expr) && expr.expression.kind === 110) {
181981
- const ctor = getContainingFunction(expr);
182282
+ const ctor = getControlFlowContainer(expr);
181982
182283
  if (!(ctor && (ctor.kind === 176 || isJSConstructor(ctor)))) {
181983
182284
  return true;
181984
182285
  }
@@ -182010,7 +182311,7 @@ ${lanes.join("\n")}
182010
182311
  function checkReferenceExpression(expr, invalidReferenceMessage, invalidOptionalChainMessage) {
182011
182312
  const node = skipOuterExpressions(
182012
182313
  expr,
182013
- 6 | 1
182314
+ 38 | 1
182014
182315
  /* Parentheses */
182015
182316
  );
182016
182317
  if (node.kind !== 80 && !isAccessExpression(node)) {
@@ -182088,6 +182389,7 @@ ${lanes.join("\n")}
182088
182389
  }
182089
182390
  switch (moduleKind) {
182090
182391
  case 100:
182392
+ case 101:
182091
182393
  case 199:
182092
182394
  if (sourceFile.impliedNodeFormat === 1) {
182093
182395
  span ?? (span = getSpanOfTokenAtPosition(sourceFile, node.pos));
@@ -182106,7 +182408,7 @@ ${lanes.join("\n")}
182106
182408
  // fallthrough
182107
182409
  default:
182108
182410
  span ?? (span = getSpanOfTokenAtPosition(sourceFile, node.pos));
182109
- const message = isAwaitExpression(node) ? Diagnostics.Top_level_await_expressions_are_only_allowed_when_the_module_option_is_set_to_es2022_esnext_system_node16_nodenext_or_preserve_and_the_target_option_is_set_to_es2017_or_higher : Diagnostics.Top_level_await_using_statements_are_only_allowed_when_the_module_option_is_set_to_es2022_esnext_system_node16_nodenext_or_preserve_and_the_target_option_is_set_to_es2017_or_higher;
182411
+ const message = isAwaitExpression(node) ? Diagnostics.Top_level_await_expressions_are_only_allowed_when_the_module_option_is_set_to_es2022_esnext_system_node16_node18_nodenext_or_preserve_and_the_target_option_is_set_to_es2017_or_higher : Diagnostics.Top_level_await_using_statements_are_only_allowed_when_the_module_option_is_set_to_es2022_esnext_system_node16_node18_nodenext_or_preserve_and_the_target_option_is_set_to_es2017_or_higher;
182110
182412
  diagnostics.add(createFileDiagnostic(sourceFile, span.start, span.length, message));
182111
182413
  hasError = true;
182112
182414
  break;
@@ -182772,7 +183074,7 @@ ${lanes.join("\n")}
182772
183074
  }
182773
183075
  const leftTarget = skipOuterExpressions(
182774
183076
  left,
182775
- 31
183077
+ 63
182776
183078
  /* All */
182777
183079
  );
182778
183080
  const nullishSemantics = getSyntacticNullishnessSemantics(leftTarget);
@@ -184242,6 +184544,9 @@ ${lanes.join("\n")}
184242
184544
  31
184243
184545
  /* ParameterPropertyModifier */
184244
184546
  )) {
184547
+ if (compilerOptions.erasableSyntaxOnly) {
184548
+ error22(node, Diagnostics.This_syntax_is_not_allowed_when_erasableSyntaxOnly_is_enabled);
184549
+ }
184245
184550
  if (!(func.kind === 176 && nodeIsPresent(func.body))) {
184246
184551
  error22(node, Diagnostics.A_parameter_property_is_only_allowed_in_a_constructor_implementation);
184247
184552
  }
@@ -187947,7 +188252,6 @@ ${lanes.join("\n")}
187947
188252
  }
187948
188253
  const signature = getSignatureFromDeclaration(container);
187949
188254
  const returnType = getReturnTypeOfSignature(signature);
187950
- const functionFlags = getFunctionFlags(container);
187951
188255
  if (strictNullChecks || node.expression || returnType.flags & 131072) {
187952
188256
  const exprType = node.expression ? checkExpressionCached(node.expression) : undefinedType2;
187953
188257
  if (container.kind === 178) {
@@ -187955,27 +188259,59 @@ ${lanes.join("\n")}
187955
188259
  error22(node, Diagnostics.Setters_cannot_return_a_value);
187956
188260
  }
187957
188261
  } else if (container.kind === 176) {
187958
- if (node.expression && !checkTypeAssignableToAndOptionallyElaborate(exprType, returnType, node, node.expression)) {
188262
+ const exprType2 = node.expression ? checkExpressionCached(node.expression) : undefinedType2;
188263
+ if (node.expression && !checkTypeAssignableToAndOptionallyElaborate(exprType2, returnType, node, node.expression)) {
187959
188264
  error22(node, Diagnostics.Return_type_of_constructor_signature_must_be_assignable_to_the_instance_type_of_the_class);
187960
188265
  }
187961
188266
  } else if (getReturnTypeFromAnnotation(container)) {
187962
- const unwrappedReturnType = unwrapReturnType(returnType, functionFlags) ?? returnType;
187963
- const unwrappedExprType = functionFlags & 2 ? checkAwaitedType(
187964
- exprType,
187965
- /*withAlias*/
187966
- false,
187967
- node,
187968
- Diagnostics.The_return_type_of_an_async_function_must_either_be_a_valid_promise_or_must_not_contain_a_callable_then_member
187969
- ) : exprType;
187970
- if (unwrappedReturnType) {
187971
- checkTypeAssignableToAndOptionallyElaborate(unwrappedExprType, unwrappedReturnType, node, node.expression);
187972
- }
188267
+ const unwrappedReturnType = unwrapReturnType(returnType, getFunctionFlags(container)) ?? returnType;
188268
+ checkReturnExpression(container, unwrappedReturnType, node, node.expression, exprType);
187973
188269
  }
187974
188270
  } else if (container.kind !== 176 && compilerOptions.noImplicitReturns && !isUnwrappedReturnTypeUndefinedVoidOrAny(container, returnType)) {
187975
188271
  error22(node, Diagnostics.Not_all_code_paths_return_a_value);
187976
188272
  }
187977
188273
  }
187978
188274
  __name(checkReturnStatement, "checkReturnStatement");
188275
+ function checkReturnExpression(container, unwrappedReturnType, node, expr, exprType, inConditionalExpression = false) {
188276
+ const excludeJSDocTypeAssertions = isInJSFile(node);
188277
+ const functionFlags = getFunctionFlags(container);
188278
+ if (expr) {
188279
+ const unwrappedExpr = skipParentheses(expr, excludeJSDocTypeAssertions);
188280
+ if (isConditionalExpression(unwrappedExpr)) {
188281
+ checkReturnExpression(
188282
+ container,
188283
+ unwrappedReturnType,
188284
+ node,
188285
+ unwrappedExpr.whenTrue,
188286
+ checkExpression(unwrappedExpr.whenTrue),
188287
+ /*inConditionalExpression*/
188288
+ true
188289
+ );
188290
+ checkReturnExpression(
188291
+ container,
188292
+ unwrappedReturnType,
188293
+ node,
188294
+ unwrappedExpr.whenFalse,
188295
+ checkExpression(unwrappedExpr.whenFalse),
188296
+ /*inConditionalExpression*/
188297
+ true
188298
+ );
188299
+ return;
188300
+ }
188301
+ }
188302
+ const inReturnStatement = node.kind === 253;
188303
+ const unwrappedExprType = functionFlags & 2 ? checkAwaitedType(
188304
+ exprType,
188305
+ /*withAlias*/
188306
+ false,
188307
+ node,
188308
+ Diagnostics.The_return_type_of_an_async_function_must_either_be_a_valid_promise_or_must_not_contain_a_callable_then_member
188309
+ ) : exprType;
188310
+ const effectiveExpr = expr && getEffectiveCheckNode(expr);
188311
+ const errorNode = inReturnStatement && !inConditionalExpression ? node : effectiveExpr;
188312
+ checkTypeAssignableToAndOptionallyElaborate(unwrappedExprType, unwrappedReturnType, errorNode, effectiveExpr);
188313
+ }
188314
+ __name(checkReturnExpression, "checkReturnExpression");
187979
188315
  function checkWithStatement(node) {
187980
188316
  if (!checkGrammarStatementInAmbientContext(node)) {
187981
188317
  if (node.flags & 65536) {
@@ -188113,7 +188449,7 @@ ${lanes.join("\n")}
188113
188449
  const typeDeclaration = symbol.valueDeclaration;
188114
188450
  if (typeDeclaration && isClassLike(typeDeclaration)) {
188115
188451
  for (const member of typeDeclaration.members) {
188116
- if (!isStatic(member) && !hasBindableName(member)) {
188452
+ if ((!isStaticIndex && !isStatic(member) || isStaticIndex && isStatic(member)) && !hasBindableName(member)) {
188117
188453
  const symbol2 = getSymbolOfDeclaration(member);
188118
188454
  checkIndexConstraintForProperty(type2, symbol2, getTypeOfExpression(member.name.expression), getNonMissingTypeOfSymbol(symbol2));
188119
188455
  }
@@ -188607,6 +188943,10 @@ ${lanes.join("\n")}
188607
188943
  function checkMemberForOverrideModifier(node, staticType, baseStaticType, baseWithThis, type2, typeWithThis, memberHasOverrideModifier, memberHasAbstractModifier, memberIsStatic, memberIsParameterProperty, member, errorNode) {
188608
188944
  const isJs = isInJSFile(node);
188609
188945
  const nodeInAmbientContext = !!(node.flags & 33554432);
188946
+ if (memberHasOverrideModifier && (member == null ? void 0 : member.valueDeclaration) && isClassElement(member.valueDeclaration) && member.valueDeclaration.name && isNonBindableDynamicName(member.valueDeclaration.name)) {
188947
+ error22(errorNode, isJs ? Diagnostics.This_member_cannot_have_a_JSDoc_comment_with_an_override_tag_because_its_name_is_dynamic : Diagnostics.This_member_cannot_have_an_override_modifier_because_its_name_is_dynamic);
188948
+ return 2;
188949
+ }
188610
188950
  if (baseWithThis && (memberHasOverrideModifier || compilerOptions.noImplicitOverride)) {
188611
188951
  const thisType = memberIsStatic ? staticType : typeWithThis;
188612
188952
  const baseType = memberIsStatic ? baseStaticType : baseWithThis;
@@ -189233,6 +189573,9 @@ ${lanes.join("\n")}
189233
189573
  checkCollisionsForDeclarationName(node, node.name);
189234
189574
  checkExportsOnMergedDeclarations(node);
189235
189575
  node.members.forEach(checkEnumMember);
189576
+ if (compilerOptions.erasableSyntaxOnly && !(node.flags & 33554432)) {
189577
+ error22(node, Diagnostics.This_syntax_is_not_allowed_when_erasableSyntaxOnly_is_enabled);
189578
+ }
189236
189579
  computeEnumMemberValues(node);
189237
189580
  const enumSymbol = getSymbolOfDeclaration(node);
189238
189581
  const firstDeclaration = getDeclarationOfKind(enumSymbol, node.kind);
@@ -189336,6 +189679,9 @@ ${lanes.join("\n")}
189336
189679
  checkExportsOnMergedDeclarations(node);
189337
189680
  const symbol = getSymbolOfDeclaration(node);
189338
189681
  if (symbol.flags & 512 && !inAmbientContext && isInstantiatedModule(node, shouldPreserveConstEnums(compilerOptions))) {
189682
+ if (compilerOptions.erasableSyntaxOnly) {
189683
+ error22(node.name, Diagnostics.This_syntax_is_not_allowed_when_erasableSyntaxOnly_is_enabled);
189684
+ }
189339
189685
  if (getIsolatedModules(compilerOptions) && !getSourceFileOfNode(node).externalModuleIndicator) {
189340
189686
  error22(node.name, Diagnostics.Namespaces_are_not_allowed_in_global_script_files_when_0_is_enabled_If_this_file_is_not_intended_to_be_a_global_script_set_moduleDetection_to_force_or_add_an_empty_export_statement, isolatedModulesLikeFlagName);
189341
189687
  }
@@ -189659,10 +190005,14 @@ ${lanes.join("\n")}
189659
190005
  if (validForTypeAttributes && override) {
189660
190006
  return;
189661
190007
  }
189662
- const mode = moduleKind === 199 && declaration.moduleSpecifier && getEmitSyntaxForModuleSpecifierExpression(declaration.moduleSpecifier);
189663
- if (mode !== 99 && moduleKind !== 99 && moduleKind !== 200) {
189664
- const message = isImportAttributes2 ? moduleKind === 199 ? Diagnostics.Import_attributes_are_not_allowed_on_statements_that_compile_to_CommonJS_require_calls : Diagnostics.Import_attributes_are_only_supported_when_the_module_option_is_set_to_esnext_nodenext_or_preserve : moduleKind === 199 ? Diagnostics.Import_assertions_are_not_allowed_on_statements_that_compile_to_CommonJS_require_calls : Diagnostics.Import_assertions_are_only_supported_when_the_module_option_is_set_to_esnext_nodenext_or_preserve;
189665
- return grammarErrorOnNode(node, message);
190008
+ if (!moduleSupportsImportAttributes(moduleKind)) {
190009
+ return grammarErrorOnNode(node, isImportAttributes2 ? Diagnostics.Import_attributes_are_only_supported_when_the_module_option_is_set_to_esnext_node18_nodenext_or_preserve : Diagnostics.Import_assertions_are_only_supported_when_the_module_option_is_set_to_esnext_node18_nodenext_or_preserve);
190010
+ }
190011
+ if (moduleKind === 199 && !isImportAttributes2) {
190012
+ return grammarErrorOnFirstToken(node, Diagnostics.Import_assertions_have_been_replaced_by_import_attributes_Use_with_instead_of_assert);
190013
+ }
190014
+ if (declaration.moduleSpecifier && getEmitSyntaxForModuleSpecifierExpression(declaration.moduleSpecifier) === 1) {
190015
+ return grammarErrorOnNode(node, isImportAttributes2 ? Diagnostics.Import_attributes_are_not_allowed_on_statements_that_compile_to_CommonJS_require_calls : Diagnostics.Import_assertions_are_not_allowed_on_statements_that_compile_to_CommonJS_require_calls);
189666
190016
  }
189667
190017
  const isTypeOnly = isJSDocImportTag(declaration) || (isImportDeclaration(declaration) ? (_a = declaration.importClause) == null ? void 0 : _a.isTypeOnly : declaration.isTypeOnly);
189668
190018
  if (isTypeOnly) {
@@ -189709,7 +190059,7 @@ ${lanes.join("\n")}
189709
190059
  }
189710
190060
  }
189711
190061
  }
189712
- if (!importClause.isTypeOnly && moduleKind === 199 && isOnlyImportableAsDefault(node.moduleSpecifier, resolvedModule) && !hasTypeJsonImportAttribute(node)) {
190062
+ if (!importClause.isTypeOnly && 101 <= moduleKind && moduleKind <= 199 && isOnlyImportableAsDefault(node.moduleSpecifier, resolvedModule) && !hasTypeJsonImportAttribute(node)) {
189713
190063
  error22(node.moduleSpecifier, Diagnostics.Importing_a_JSON_file_into_an_ECMAScript_module_requires_a_type_Colon_json_import_attribute_when_module_is_set_to_0, ModuleKind[moduleKind]);
189714
190064
  }
189715
190065
  } else if (noUncheckedSideEffectImports && !importClause) {
@@ -189731,6 +190081,9 @@ ${lanes.join("\n")}
189731
190081
  return;
189732
190082
  }
189733
190083
  checkGrammarModifiers(node);
190084
+ if (compilerOptions.erasableSyntaxOnly && !(node.flags & 33554432)) {
190085
+ error22(node, Diagnostics.This_syntax_is_not_allowed_when_erasableSyntaxOnly_is_enabled);
190086
+ }
189734
190087
  if (isInternalModuleImportEqualsDeclaration(node) || checkExternalImportOrExportDeclaration(node)) {
189735
190088
  checkImportBinding(node);
189736
190089
  markLinkedReferences(
@@ -189880,6 +190233,9 @@ ${lanes.join("\n")}
189880
190233
  if (checkGrammarModuleElementContext(node, illegalContextMessage)) {
189881
190234
  return;
189882
190235
  }
190236
+ if (compilerOptions.erasableSyntaxOnly && node.isExportEquals && !(node.flags & 33554432)) {
190237
+ error22(node, Diagnostics.This_syntax_is_not_allowed_when_erasableSyntaxOnly_is_enabled);
190238
+ }
189883
190239
  const container = node.parent.kind === 307 ? node.parent : node.parent.parent;
189884
190240
  if (container.kind === 267 && !isAmbientModule(container)) {
189885
190241
  if (node.isExportEquals) {
@@ -190941,7 +191297,7 @@ ${lanes.join("\n")}
190941
191297
  name2,
190942
191298
  meaning,
190943
191299
  /*ignoreErrors*/
190944
- false,
191300
+ true,
190945
191301
  /*dontResolveAlias*/
190946
191302
  true
190947
191303
  );
@@ -190951,8 +191307,9 @@ ${lanes.join("\n")}
190951
191307
  return resolveEntityName(
190952
191308
  name2,
190953
191309
  /*meaning*/
190954
- 1
190955
- /* FunctionScopedVariable */
191310
+ 1,
191311
+ /*ignoreErrors*/
191312
+ true
190956
191313
  );
190957
191314
  }
190958
191315
  return void 0;
@@ -191150,8 +191507,9 @@ ${lanes.join("\n")}
191150
191507
  if (location2 && location2.kind === 304) {
191151
191508
  return resolveEntityName(
191152
191509
  location2.name,
191153
- 111551 | 2097152
191154
- /* Alias */
191510
+ 111551 | 2097152,
191511
+ /*ignoreErrors*/
191512
+ true
191155
191513
  );
191156
191514
  }
191157
191515
  return void 0;
@@ -191164,15 +191522,17 @@ ${lanes.join("\n")}
191164
191522
  // Skip for invalid syntax like this: export { "x" }
191165
191523
  resolveEntityName(
191166
191524
  name2,
191167
- 111551 | 788968 | 1920 | 2097152
191168
- /* Alias */
191525
+ 111551 | 788968 | 1920 | 2097152,
191526
+ /*ignoreErrors*/
191527
+ true
191169
191528
  )
191170
191529
  );
191171
191530
  } else {
191172
191531
  return resolveEntityName(
191173
191532
  node,
191174
- 111551 | 788968 | 1920 | 2097152
191175
- /* Alias */
191533
+ 111551 | 788968 | 1920 | 2097152,
191534
+ /*ignoreErrors*/
191535
+ true
191176
191536
  );
191177
191537
  }
191178
191538
  }
@@ -192285,6 +192645,46 @@ ${lanes.join("\n")}
192285
192645
  for (const info of infoList) {
192286
192646
  if (info.declaration) continue;
192287
192647
  if (info === anyBaseTypeIndexInfo) continue;
192648
+ if (info.components) {
192649
+ const allComponentComputedNamesSerializable = every(info.components, (e) => {
192650
+ var _a;
192651
+ return !!(e.name && isComputedPropertyName(e.name) && isEntityNameExpression(e.name.expression) && enclosing && ((_a = isEntityNameVisible(
192652
+ e.name.expression,
192653
+ enclosing,
192654
+ /*shouldComputeAliasToMakeVisible*/
192655
+ false
192656
+ )) == null ? void 0 : _a.accessibility) === 0);
192657
+ });
192658
+ if (allComponentComputedNamesSerializable) {
192659
+ const newComponents = filter6(info.components, (e) => {
192660
+ return !hasLateBindableName(e);
192661
+ });
192662
+ result.push(...map4(newComponents, (e) => {
192663
+ trackComputedName(e.name.expression);
192664
+ const mods = infoList === staticInfos ? [
192665
+ factory.createModifier(
192666
+ 126
192667
+ /* StaticKeyword */
192668
+ )
192669
+ ] : void 0;
192670
+ return factory.createPropertyDeclaration(
192671
+ append(mods, info.isReadonly ? factory.createModifier(
192672
+ 148
192673
+ /* ReadonlyKeyword */
192674
+ ) : void 0),
192675
+ e.name,
192676
+ (isPropertySignature(e) || isPropertyDeclaration(e) || isMethodSignature(e) || isMethodDeclaration(e) || isGetAccessor(e) || isSetAccessor(e)) && e.questionToken ? factory.createToken(
192677
+ 58
192678
+ /* QuestionToken */
192679
+ ) : void 0,
192680
+ nodeBuilder.typeToTypeNode(getTypeOfSymbol(e.symbol), enclosing, flags, internalFlags, tracker),
192681
+ /*initializer*/
192682
+ void 0
192683
+ );
192684
+ }));
192685
+ continue;
192686
+ }
192687
+ }
192288
192688
  const node = nodeBuilder.indexInfoToIndexSignatureDeclaration(info, enclosing, flags, internalFlags, tracker);
192289
192689
  if (node && infoList === staticInfos) {
192290
192690
  (node.modifiers || (node.modifiers = factory.createNodeArray())).unshift(factory.createModifier(
@@ -192298,6 +192698,28 @@ ${lanes.join("\n")}
192298
192698
  }
192299
192699
  }
192300
192700
  return result;
192701
+ function trackComputedName(accessExpression) {
192702
+ if (!tracker.trackSymbol) return;
192703
+ const firstIdentifier = getFirstIdentifier(accessExpression);
192704
+ const name2 = resolveName(
192705
+ firstIdentifier,
192706
+ firstIdentifier.escapedText,
192707
+ 111551 | 1048576,
192708
+ /*nameNotFoundMessage*/
192709
+ void 0,
192710
+ /*isUse*/
192711
+ true
192712
+ );
192713
+ if (name2) {
192714
+ tracker.trackSymbol(
192715
+ name2,
192716
+ enclosing,
192717
+ 111551
192718
+ /* Value */
192719
+ );
192720
+ }
192721
+ }
192722
+ __name(trackComputedName, "trackComputedName");
192301
192723
  }, "createLateBoundIndexSignatures")
192302
192724
  };
192303
192725
  function isImportRequiredByAugmentation(node) {
@@ -193507,6 +193929,7 @@ ${lanes.join("\n")}
193507
193929
  }
193508
193930
  switch (moduleKind) {
193509
193931
  case 100:
193932
+ case 101:
193510
193933
  case 199:
193511
193934
  if (sourceFile.impliedNodeFormat === 1) {
193512
193935
  diagnostics.add(createDiagnosticForNode(forInOrOfStatement.awaitModifier, Diagnostics.The_current_file_is_a_CommonJS_module_and_cannot_use_await_at_the_top_level));
@@ -193522,7 +193945,7 @@ ${lanes.join("\n")}
193522
193945
  }
193523
193946
  // fallthrough
193524
193947
  default:
193525
- diagnostics.add(createDiagnosticForNode(forInOrOfStatement.awaitModifier, Diagnostics.Top_level_for_await_loops_are_only_allowed_when_the_module_option_is_set_to_es2022_esnext_system_node16_nodenext_or_preserve_and_the_target_option_is_set_to_es2017_or_higher));
193948
+ diagnostics.add(createDiagnosticForNode(forInOrOfStatement.awaitModifier, Diagnostics.Top_level_for_await_loops_are_only_allowed_when_the_module_option_is_set_to_es2022_esnext_system_node16_node18_nodenext_or_preserve_and_the_target_option_is_set_to_es2017_or_higher));
193526
193949
  break;
193527
193950
  }
193528
193951
  }
@@ -193685,7 +194108,7 @@ ${lanes.join("\n")}
193685
194108
  }
193686
194109
  __name(checkGrammarTypeOperatorNode, "checkGrammarTypeOperatorNode");
193687
194110
  function checkGrammarForInvalidDynamicName(node, message) {
193688
- if (isNonBindableDynamicName(node)) {
194111
+ if (isNonBindableDynamicName(node) && !isEntityNameExpression(isElementAccessExpression(node) ? skipParentheses(node.argumentExpression) : node.expression)) {
193689
194112
  return grammarErrorOnNode(node, message);
193690
194113
  }
193691
194114
  }
@@ -194179,17 +194602,17 @@ ${lanes.join("\n")}
194179
194602
  return grammarErrorOnNode(node, Diagnostics.ESM_syntax_is_not_allowed_in_a_CommonJS_module_when_verbatimModuleSyntax_is_enabled);
194180
194603
  }
194181
194604
  if (moduleKind === 5) {
194182
- return grammarErrorOnNode(node, Diagnostics.Dynamic_imports_are_only_supported_when_the_module_flag_is_set_to_es2020_es2022_esnext_commonjs_amd_system_umd_node16_or_nodenext);
194605
+ return grammarErrorOnNode(node, Diagnostics.Dynamic_imports_are_only_supported_when_the_module_flag_is_set_to_es2020_es2022_esnext_commonjs_amd_system_umd_node16_node18_or_nodenext);
194183
194606
  }
194184
194607
  if (node.typeArguments) {
194185
194608
  return grammarErrorOnNode(node, Diagnostics.This_use_of_import_is_invalid_import_calls_can_be_written_but_they_must_have_parentheses_and_cannot_have_type_arguments);
194186
194609
  }
194187
194610
  const nodeArguments = node.arguments;
194188
- if (moduleKind !== 99 && moduleKind !== 199 && moduleKind !== 100 && moduleKind !== 200) {
194611
+ if (!(100 <= moduleKind && moduleKind <= 199) && moduleKind !== 99 && moduleKind !== 200) {
194189
194612
  checkGrammarForDisallowedTrailingComma(nodeArguments);
194190
194613
  if (nodeArguments.length > 1) {
194191
194614
  const importAttributesArgument = nodeArguments[1];
194192
- return grammarErrorOnNode(importAttributesArgument, Diagnostics.Dynamic_imports_only_support_a_second_argument_when_the_module_option_is_set_to_esnext_node16_nodenext_or_preserve);
194615
+ return grammarErrorOnNode(importAttributesArgument, Diagnostics.Dynamic_imports_only_support_a_second_argument_when_the_module_option_is_set_to_esnext_node16_node18_nodenext_or_preserve);
194193
194616
  }
194194
194617
  }
194195
194618
  if (nodeArguments.length === 0 || nodeArguments.length > 2) {
@@ -198780,7 +199203,7 @@ ${lanes.join("\n")}
198780
199203
  }
198781
199204
  __name(visitVariableDeclaration, "visitVariableDeclaration");
198782
199205
  function visitParenthesizedExpression(node) {
198783
- const innerExpression = skipOuterExpressions(node.expression, ~(6 | 16));
199206
+ const innerExpression = skipOuterExpressions(node.expression, ~(38 | 16));
198784
199207
  if (isAssertionExpression(innerExpression) || isSatisfiesExpression(innerExpression)) {
198785
199208
  const expression = visitNode(node.expression, visitor, isExpression);
198786
199209
  Debug.assert(expression);
@@ -217837,7 +218260,7 @@ ${lanes.join("\n")}
217837
218260
  if (node === (importsAndRequiresToRewriteOrShim == null ? void 0 : importsAndRequiresToRewriteOrShim[0])) {
217838
218261
  return visitImportOrRequireCall(importsAndRequiresToRewriteOrShim.shift());
217839
218262
  }
217840
- break;
218263
+ // fallthrough
217841
218264
  default:
217842
218265
  if ((importsAndRequiresToRewriteOrShim == null ? void 0 : importsAndRequiresToRewriteOrShim.length) && rangeContainsRange(node, importsAndRequiresToRewriteOrShim[0])) {
217843
218266
  return visitEachChild(node, visitor, context);
@@ -218701,11 +219124,7 @@ ${lanes.join("\n")}
218701
219124
  if (isSetAccessor(node.parent)) {
218702
219125
  return createAccessorTypeError(node.parent);
218703
219126
  }
218704
- const addUndefined = resolver.requiresAddingImplicitUndefined(
218705
- node,
218706
- /*enclosingDeclaration*/
218707
- void 0
218708
- );
219127
+ const addUndefined = resolver.requiresAddingImplicitUndefined(node, node.parent);
218709
219128
  if (!addUndefined && node.initializer) {
218710
219129
  return createExpressionError(node.initializer);
218711
219130
  }
@@ -220437,6 +220856,7 @@ ${lanes.join("\n")}
220437
220856
  case 6:
220438
220857
  case 5:
220439
220858
  case 100:
220859
+ case 101:
220440
220860
  case 199:
220441
220861
  case 1:
220442
220862
  return transformImpliedNodeFormatDependentModule;
@@ -227713,42 +228133,6 @@ ${lanes.join("\n")}
227713
228133
  return resolutions;
227714
228134
  }
227715
228135
  __name(loadWithModeAwareCache, "loadWithModeAwareCache");
227716
- function forEachResolvedProjectReference(resolvedProjectReferences, cb) {
227717
- return forEachProjectReference(
227718
- /*projectReferences*/
227719
- void 0,
227720
- resolvedProjectReferences,
227721
- (resolvedRef, parent2) => resolvedRef && cb(resolvedRef, parent2)
227722
- );
227723
- }
227724
- __name(forEachResolvedProjectReference, "forEachResolvedProjectReference");
227725
- function forEachProjectReference(projectReferences, resolvedProjectReferences, cbResolvedRef, cbRef) {
227726
- let seenResolvedRefs;
227727
- return worker(
227728
- projectReferences,
227729
- resolvedProjectReferences,
227730
- /*parent*/
227731
- void 0
227732
- );
227733
- function worker(projectReferences2, resolvedProjectReferences2, parent2) {
227734
- if (cbRef) {
227735
- const result = cbRef(projectReferences2, parent2);
227736
- if (result) return result;
227737
- }
227738
- let skipChildren;
227739
- return forEach3(resolvedProjectReferences2, (resolvedRef, index2) => {
227740
- if (resolvedRef && (seenResolvedRefs == null ? void 0 : seenResolvedRefs.has(resolvedRef.sourceFile.path))) {
227741
- (skipChildren ?? (skipChildren = /* @__PURE__ */ new Set())).add(resolvedRef);
227742
- return void 0;
227743
- }
227744
- const result = cbResolvedRef(resolvedRef, parent2, index2);
227745
- if (result || !resolvedRef) return result;
227746
- (seenResolvedRefs || (seenResolvedRefs = /* @__PURE__ */ new Set())).add(resolvedRef.sourceFile.path);
227747
- }) || forEach3(resolvedProjectReferences2, (resolvedRef) => resolvedRef && !(skipChildren == null ? void 0 : skipChildren.has(resolvedRef)) ? worker(resolvedRef.commandLine.projectReferences, resolvedRef.references, resolvedRef) : void 0);
227748
- }
227749
- __name(worker, "worker");
227750
- }
227751
- __name(forEachProjectReference, "forEachProjectReference");
227752
228136
  var inferredTypesContainingFile = "__inferred type names__.ts";
227753
228137
  function getInferredLibraryNameResolveFrom(options, currentDirectory, libFileName) {
227754
228138
  const containingDirectory = options.configFilePath ? getDirectoryPath(options.configFilePath) : currentDirectory;
@@ -227766,15 +228150,6 @@ ${lanes.join("\n")}
227766
228150
  return "@typescript/lib-" + path36;
227767
228151
  }
227768
228152
  __name(getLibraryNameFromLibFileName, "getLibraryNameFromLibFileName");
227769
- function getLibNameFromLibReference(libReference) {
227770
- return toFileNameLowerCase(libReference.fileName);
227771
- }
227772
- __name(getLibNameFromLibReference, "getLibNameFromLibReference");
227773
- function getLibFileNameFromLibReference(libReference) {
227774
- const libName = getLibNameFromLibReference(libReference);
227775
- return libMap.get(libName);
227776
- }
227777
- __name(getLibFileNameFromLibReference, "getLibFileNameFromLibReference");
227778
228153
  function isReferencedFile(reason) {
227779
228154
  switch (reason == null ? void 0 : reason.kind) {
227780
228155
  case 3:
@@ -228033,11 +228408,13 @@ ${lanes.join("\n")}
228033
228408
  };
228034
228409
  }
228035
228410
  __name(createCreateProgramOptions, "createCreateProgramOptions");
228036
- function createProgram2(rootNamesOrOptions, _options, _host, _oldProgram, _configFileParsingDiagnostics) {
228411
+ function createProgram2(_rootNamesOrOptions, _options, _host, _oldProgram, _configFileParsingDiagnostics) {
228037
228412
  var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p;
228038
- const createProgramOptions = isArray3(rootNamesOrOptions) ? createCreateProgramOptions(rootNamesOrOptions, _options, _host, _oldProgram, _configFileParsingDiagnostics) : rootNamesOrOptions;
228039
- const { rootNames, options, configFileParsingDiagnostics, projectReferences, typeScriptVersion: typeScriptVersion3 } = createProgramOptions;
228040
- let { oldProgram } = createProgramOptions;
228413
+ let _createProgramOptions = isArray3(_rootNamesOrOptions) ? createCreateProgramOptions(_rootNamesOrOptions, _options, _host, _oldProgram, _configFileParsingDiagnostics) : _rootNamesOrOptions;
228414
+ const { rootNames, options, configFileParsingDiagnostics, projectReferences, typeScriptVersion: typeScriptVersion3, host: createProgramOptionsHost } = _createProgramOptions;
228415
+ let { oldProgram } = _createProgramOptions;
228416
+ _createProgramOptions = void 0;
228417
+ _rootNamesOrOptions = void 0;
228041
228418
  for (const option of commandLineOptionOfCustomType) {
228042
228419
  if (hasProperty(options, option.name)) {
228043
228420
  if (typeof options[option.name] === "string") {
@@ -228050,16 +228427,12 @@ ${lanes.join("\n")}
228050
228427
  let processingOtherFiles;
228051
228428
  let files;
228052
228429
  let symlinks;
228053
- let commonSourceDirectory;
228054
228430
  let typeChecker;
228055
228431
  let classifiableNames;
228056
- let fileReasons = createMultiMap();
228057
228432
  let filesWithReferencesProcessed;
228058
- let fileReasonsToChain;
228059
- let reasonToRelatedInfo;
228060
228433
  let cachedBindAndCheckDiagnosticsForFile;
228061
228434
  let cachedDeclarationDiagnosticsForFile;
228062
- let fileProcessingDiagnostics;
228435
+ const programDiagnostics = createProgramDiagnostics(getCompilerOptionsObjectLiteralSyntax);
228063
228436
  let automaticTypeDirectiveNames;
228064
228437
  let automaticTypeDirectiveResolutions;
228065
228438
  let resolvedLibReferences;
@@ -228084,13 +228457,12 @@ ${lanes.join("\n")}
228084
228457
  true
228085
228458
  );
228086
228459
  mark("beforeProgram");
228087
- const host = createProgramOptions.host || createCompilerHost(options);
228460
+ const host = createProgramOptionsHost || createCompilerHost(options);
228088
228461
  const configParsingHost = parseConfigHostFromCompilerHostLike(host);
228089
228462
  let skipDefaultLib = options.noLib;
228090
228463
  const getDefaultLibraryFileName = memoize(() => host.getDefaultLibFileName(options));
228091
228464
  const defaultLibraryPath = host.getDefaultLibLocation ? host.getDefaultLibLocation() : getDirectoryPath(getDefaultLibraryFileName());
228092
- const programDiagnostics = createDiagnosticCollection();
228093
- let lazyProgramDiagnosticExplainingFile = [];
228465
+ let skipVerifyCompilerOptions = false;
228094
228466
  const currentDirectory = host.getCurrentDirectory();
228095
228467
  const supportedExtensions2 = getSupportedExtensions(options);
228096
228468
  const supportedExtensionsWithJsonIfResolveJsonModule = getSupportedExtensionsWithJsonIfResolveJsonModule(options, supportedExtensions2);
@@ -228368,7 +228740,7 @@ ${lanes.join("\n")}
228368
228740
  getTypeCount: /* @__PURE__ */ __name(() => getTypeChecker().getTypeCount(), "getTypeCount"),
228369
228741
  getInstantiationCount: /* @__PURE__ */ __name(() => getTypeChecker().getInstantiationCount(), "getInstantiationCount"),
228370
228742
  getRelationCacheSizes: /* @__PURE__ */ __name(() => getTypeChecker().getRelationCacheSizes(), "getRelationCacheSizes"),
228371
- getFileProcessingDiagnostics: /* @__PURE__ */ __name(() => fileProcessingDiagnostics, "getFileProcessingDiagnostics"),
228743
+ getFileProcessingDiagnostics: /* @__PURE__ */ __name(() => programDiagnostics.getFileProcessingDiagnostics(), "getFileProcessingDiagnostics"),
228372
228744
  getAutomaticTypeDirectiveNames: /* @__PURE__ */ __name(() => automaticTypeDirectiveNames, "getAutomaticTypeDirectiveNames"),
228373
228745
  getAutomaticTypeDirectiveResolutions: /* @__PURE__ */ __name(() => automaticTypeDirectiveResolutions, "getAutomaticTypeDirectiveResolutions"),
228374
228746
  isSourceFileFromExternalLibrary,
@@ -228384,6 +228756,7 @@ ${lanes.join("\n")}
228384
228756
  resolvedModules,
228385
228757
  resolvedTypeReferenceDirectiveNames,
228386
228758
  resolvedLibReferences,
228759
+ getProgramDiagnosticsContainer: /* @__PURE__ */ __name(() => programDiagnostics, "getProgramDiagnosticsContainer"),
228387
228760
  getResolvedModule,
228388
228761
  getResolvedModuleFromModuleSpecifier,
228389
228762
  getResolvedTypeReferenceDirective,
@@ -228416,54 +228789,19 @@ ${lanes.join("\n")}
228416
228789
  realpath: (_o = host.realpath) == null ? void 0 : _o.bind(host),
228417
228790
  useCaseSensitiveFileNames: /* @__PURE__ */ __name(() => host.useCaseSensitiveFileNames(), "useCaseSensitiveFileNames"),
228418
228791
  getCanonicalFileName,
228419
- getFileIncludeReasons: /* @__PURE__ */ __name(() => fileReasons, "getFileIncludeReasons"),
228792
+ getFileIncludeReasons: /* @__PURE__ */ __name(() => programDiagnostics.getFileReasons(), "getFileIncludeReasons"),
228420
228793
  structureIsReused,
228421
228794
  writeFile: writeFile22,
228422
228795
  getGlobalTypingsCacheLocation: maybeBind(host, host.getGlobalTypingsCacheLocation)
228423
228796
  };
228424
228797
  onProgramCreateComplete();
228425
- verifyCompilerOptions();
228798
+ if (!skipVerifyCompilerOptions) {
228799
+ verifyCompilerOptions();
228800
+ }
228426
228801
  mark("afterProgram");
228427
228802
  measure("Program", "beforeProgram", "afterProgram");
228428
228803
  (_p = tracing) == null ? void 0 : _p.pop();
228429
228804
  return program2;
228430
- function updateAndGetProgramDiagnostics() {
228431
- if (lazyProgramDiagnosticExplainingFile) {
228432
- fileProcessingDiagnostics == null ? void 0 : fileProcessingDiagnostics.forEach((diagnostic) => {
228433
- switch (diagnostic.kind) {
228434
- case 1:
228435
- return programDiagnostics.add(createDiagnosticExplainingFile(diagnostic.file && getSourceFileByPath(diagnostic.file), diagnostic.fileProcessingReason, diagnostic.diagnostic, diagnostic.args || emptyArray));
228436
- case 0:
228437
- return programDiagnostics.add(filePreprocessingLibreferenceDiagnostic(diagnostic));
228438
- case 2:
228439
- return diagnostic.diagnostics.forEach((d) => programDiagnostics.add(d));
228440
- default:
228441
- Debug.assertNever(diagnostic);
228442
- }
228443
- });
228444
- lazyProgramDiagnosticExplainingFile.forEach(({ file, diagnostic, args }) => programDiagnostics.add(createDiagnosticExplainingFile(
228445
- file,
228446
- /*fileProcessingReason*/
228447
- void 0,
228448
- diagnostic,
228449
- args
228450
- )));
228451
- lazyProgramDiagnosticExplainingFile = void 0;
228452
- fileReasonsToChain = void 0;
228453
- reasonToRelatedInfo = void 0;
228454
- }
228455
- return programDiagnostics;
228456
- }
228457
- __name(updateAndGetProgramDiagnostics, "updateAndGetProgramDiagnostics");
228458
- function filePreprocessingLibreferenceDiagnostic({ reason }) {
228459
- const { file, pos, end } = getReferencedFileLocation(program2, reason);
228460
- const libReference = file.libReferenceDirectives[reason.index];
228461
- const libName = getLibNameFromLibReference(libReference);
228462
- const unqualifiedLibName = removeSuffix(removePrefix(libName, "lib."), ".d.ts");
228463
- const suggestion = getSpellingSuggestion(unqualifiedLibName, libs, identity2);
228464
- return createFileDiagnostic(file, Debug.checkDefined(pos), Debug.checkDefined(end) - pos, suggestion ? Diagnostics.Cannot_find_lib_definition_for_0_Did_you_mean_1 : Diagnostics.Cannot_find_lib_definition_for_0, libName, suggestion);
228465
- }
228466
- __name(filePreprocessingLibreferenceDiagnostic, "filePreprocessingLibreferenceDiagnostic");
228467
228805
  function getResolvedModule(file, moduleName, mode) {
228468
228806
  var _a2;
228469
228807
  return (_a2 = resolvedModules == null ? void 0 : resolvedModules.get(file.path)) == null ? void 0 : _a2.get(moduleName, mode);
@@ -228518,7 +228856,7 @@ ${lanes.join("\n")}
228518
228856
  function addResolutionDiagnostics(resolution) {
228519
228857
  var _a2;
228520
228858
  if (!((_a2 = resolution.resolutionDiagnostics) == null ? void 0 : _a2.length)) return;
228521
- (fileProcessingDiagnostics ?? (fileProcessingDiagnostics = [])).push({
228859
+ programDiagnostics.addFileProcessingDiagnostic({
228522
228860
  kind: 2,
228523
228861
  diagnostics: resolution.resolutionDiagnostics
228524
228862
  });
@@ -228611,10 +228949,13 @@ ${lanes.join("\n")}
228611
228949
  }
228612
228950
  __name(toPath32, "toPath3");
228613
228951
  function getCommonSourceDirectory2() {
228614
- if (commonSourceDirectory === void 0) {
228615
- const emittedFiles = filter6(files, (file) => sourceFileMayBeEmitted(file, program2));
228616
- commonSourceDirectory = getCommonSourceDirectory(options, () => mapDefined(emittedFiles, (file) => file.isDeclarationFile ? void 0 : file.fileName), currentDirectory, getCanonicalFileName, (commonSourceDirectory2) => checkSourceFilesBelongToPath(emittedFiles, commonSourceDirectory2));
228952
+ let commonSourceDirectory = programDiagnostics.getCommonSourceDirectory();
228953
+ if (commonSourceDirectory !== void 0) {
228954
+ return commonSourceDirectory;
228617
228955
  }
228956
+ const emittedFiles = filter6(files, (file) => sourceFileMayBeEmitted(file, program2));
228957
+ commonSourceDirectory = getCommonSourceDirectory(options, () => mapDefined(emittedFiles, (file) => file.isDeclarationFile ? void 0 : file.fileName), currentDirectory, getCanonicalFileName, (commonSourceDirectory2) => checkSourceFilesBelongToPath(emittedFiles, commonSourceDirectory2));
228958
+ programDiagnostics.setCommonSourceDirectory(commonSourceDirectory);
228618
228959
  return commonSourceDirectory;
228619
228960
  }
228620
228961
  __name(getCommonSourceDirectory2, "getCommonSourceDirectory2");
@@ -228889,9 +229230,10 @@ ${lanes.join("\n")}
228889
229230
  }
228890
229231
  filesByName.set(path36, filesByName.get(oldFile.path));
228891
229232
  });
229233
+ const isConfigIdentical = oldOptions.configFile && oldOptions.configFile === options.configFile || !oldOptions.configFile && !options.configFile && !optionsHaveChanges(oldOptions, options, optionDeclarations);
229234
+ programDiagnostics.reuseStateFromOldProgram(oldProgram.getProgramDiagnosticsContainer(), isConfigIdentical);
229235
+ skipVerifyCompilerOptions = isConfigIdentical;
228892
229236
  files = newSourceFiles;
228893
- fileReasons = oldProgram.getFileIncludeReasons();
228894
- fileProcessingDiagnostics = oldProgram.getFileProcessingDiagnostics();
228895
229237
  automaticTypeDirectiveNames = oldProgram.getAutomaticTypeDirectiveNames();
228896
229238
  automaticTypeDirectiveResolutions = oldProgram.getAutomaticTypeDirectiveResolutions();
228897
229239
  sourceFileToPackageName = oldProgram.sourceFileToPackageName;
@@ -229106,7 +229448,7 @@ ${lanes.join("\n")}
229106
229448
  if (skipTypeChecking(sourceFile, options, program2)) {
229107
229449
  return emptyArray;
229108
229450
  }
229109
- const programDiagnosticsInFile = updateAndGetProgramDiagnostics().getDiagnostics(sourceFile.fileName);
229451
+ const programDiagnosticsInFile = programDiagnostics.getCombinedDiagnostics(program2).getDiagnostics(sourceFile.fileName);
229110
229452
  if (!((_a2 = sourceFile.commentDirectives) == null ? void 0 : _a2.length)) {
229111
229453
  return programDiagnosticsInFile;
229112
229454
  }
@@ -229483,14 +229825,14 @@ ${lanes.join("\n")}
229483
229825
  }
229484
229826
  __name(getDeclarationDiagnosticsForFile, "getDeclarationDiagnosticsForFile");
229485
229827
  function getOptionsDiagnostics() {
229486
- return sortAndDeduplicateDiagnostics(concatenate(updateAndGetProgramDiagnostics().getGlobalDiagnostics(), getOptionsDiagnosticsOfConfigFile()));
229828
+ return sortAndDeduplicateDiagnostics(concatenate(programDiagnostics.getCombinedDiagnostics(program2).getGlobalDiagnostics(), getOptionsDiagnosticsOfConfigFile()));
229487
229829
  }
229488
229830
  __name(getOptionsDiagnostics, "getOptionsDiagnostics");
229489
229831
  function getOptionsDiagnosticsOfConfigFile() {
229490
229832
  if (!options.configFile) return emptyArray;
229491
- let diagnostics = updateAndGetProgramDiagnostics().getDiagnostics(options.configFile.fileName);
229833
+ let diagnostics = programDiagnostics.getCombinedDiagnostics(program2).getDiagnostics(options.configFile.fileName);
229492
229834
  forEachResolvedProjectReference2((resolvedRef) => {
229493
- diagnostics = concatenate(diagnostics, updateAndGetProgramDiagnostics().getDiagnostics(resolvedRef.sourceFile.fileName));
229835
+ diagnostics = concatenate(diagnostics, programDiagnostics.getCombinedDiagnostics(program2).getDiagnostics(resolvedRef.sourceFile.fileName));
229494
229836
  });
229495
229837
  return diagnostics;
229496
229838
  }
@@ -229721,7 +230063,7 @@ ${lanes.join("\n")}
229721
230063
  }
229722
230064
  __name(processProjectReferenceFile, "processProjectReferenceFile");
229723
230065
  function reportFileNamesDifferOnlyInCasingError(fileName, existingFile, reason) {
229724
- const hasExistingReasonToReportErrorOn = !isReferencedFile(reason) && some(fileReasons.get(existingFile.path), isReferencedFile);
230066
+ const hasExistingReasonToReportErrorOn = !isReferencedFile(reason) && some(programDiagnostics.getFileReasons().get(existingFile.path), isReferencedFile);
229725
230067
  if (hasExistingReasonToReportErrorOn) {
229726
230068
  addFilePreprocessingFileExplainingDiagnostic(existingFile, reason, Diagnostics.Already_included_file_name_0_differs_from_file_name_1_only_in_casing, [
229727
230069
  existingFile.fileName,
@@ -229930,7 +230272,7 @@ ${lanes.join("\n")}
229930
230272
  __name(findSourceFileWorker, "findSourceFileWorker");
229931
230273
  function addFileIncludeReason(file, reason, checkExisting) {
229932
230274
  if (file && (!checkExisting || !isReferencedFile(reason) || !(filesWithReferencesProcessed == null ? void 0 : filesWithReferencesProcessed.has(reason.file)))) {
229933
- fileReasons.add(file.path, reason);
230275
+ programDiagnostics.getFileReasons().add(file.path, reason);
229934
230276
  return true;
229935
230277
  }
229936
230278
  return false;
@@ -230130,6 +230472,16 @@ ${lanes.join("\n")}
230130
230472
  var _a2, _b2, _c2, _d2, _e2;
230131
230473
  const existing = resolvedLibProcessing == null ? void 0 : resolvedLibProcessing.get(libFileName);
230132
230474
  if (existing) return existing;
230475
+ if (options.libReplacement === false) {
230476
+ const result2 = {
230477
+ resolution: {
230478
+ resolvedModule: void 0
230479
+ },
230480
+ actual: combinePaths(defaultLibraryPath, libFileName)
230481
+ };
230482
+ (resolvedLibProcessing ?? (resolvedLibProcessing = /* @__PURE__ */ new Map())).set(libFileName, result2);
230483
+ return result2;
230484
+ }
230133
230485
  if (structureIsReused !== 0 && oldProgram && !hasInvalidatedLibResolutions(libFileName)) {
230134
230486
  const oldResolution = (_a2 = oldProgram.resolvedLibReferences) == null ? void 0 : _a2.get(libFileName);
230135
230487
  if (oldResolution) {
@@ -230177,7 +230529,7 @@ ${lanes.join("\n")}
230177
230529
  }
230178
230530
  );
230179
230531
  } else {
230180
- (fileProcessingDiagnostics || (fileProcessingDiagnostics = [])).push({
230532
+ programDiagnostics.addFileProcessingDiagnostic({
230181
230533
  kind: 0,
230182
230534
  reason: {
230183
230535
  kind: 7,
@@ -230251,10 +230603,7 @@ ${lanes.join("\n")}
230251
230603
  if (!sourceFile.isDeclarationFile) {
230252
230604
  const absoluteSourceFilePath = host.getCanonicalFileName(getNormalizedAbsolutePath(sourceFile.fileName, currentDirectory));
230253
230605
  if (absoluteSourceFilePath.indexOf(absoluteRootDirectoryPath) !== 0) {
230254
- addLazyProgramDiagnosticExplainingFile(sourceFile, Diagnostics.File_0_is_not_under_rootDir_1_rootDir_is_expected_to_contain_all_source_files, [
230255
- sourceFile.fileName,
230256
- rootDirectory
230257
- ]);
230606
+ programDiagnostics.addLazyConfigDiagnostic(sourceFile, Diagnostics.File_0_is_not_under_rootDir_1_rootDir_is_expected_to_contain_all_source_files, sourceFile.fileName, rootDirectory);
230258
230607
  allFilesBelongToPath = false;
230259
230608
  }
230260
230609
  }
@@ -230377,7 +230726,7 @@ ${lanes.join("\n")}
230377
230726
  }
230378
230727
  const outputFile = options.outFile;
230379
230728
  if (!options.tsBuildInfoFile && options.incremental && !outputFile && !options.configFilePath) {
230380
- programDiagnostics.add(createCompilerDiagnostic(Diagnostics.Option_incremental_can_only_be_specified_using_tsconfig_emitting_to_single_file_or_when_option_tsBuildInfoFile_is_specified));
230729
+ programDiagnostics.addConfigDiagnostic(createCompilerDiagnostic(Diagnostics.Option_incremental_can_only_be_specified_using_tsconfig_emitting_to_single_file_or_when_option_tsBuildInfoFile_is_specified));
230381
230730
  }
230382
230731
  verifyDeprecatedCompilerOptions();
230383
230732
  verifyProjectReferences();
@@ -230385,10 +230734,7 @@ ${lanes.join("\n")}
230385
230734
  const rootPaths = new Set(rootNames.map(toPath32));
230386
230735
  for (const file of files) {
230387
230736
  if (sourceFileMayBeEmitted(file, program2) && !rootPaths.has(file.path)) {
230388
- addLazyProgramDiagnosticExplainingFile(file, Diagnostics.File_0_is_not_listed_within_the_file_list_of_project_1_Projects_must_list_all_files_or_use_an_include_pattern, [
230389
- file.fileName,
230390
- options.configFilePath || ""
230391
- ]);
230737
+ programDiagnostics.addLazyConfigDiagnostic(file, Diagnostics.File_0_is_not_listed_within_the_file_list_of_project_1_Projects_must_list_all_files_or_use_an_include_pattern, file.fileName, options.configFilePath || "");
230392
230738
  }
230393
230739
  }
230394
230740
  }
@@ -230478,14 +230824,14 @@ ${lanes.join("\n")}
230478
230824
  }
230479
230825
  } else if (firstNonAmbientExternalModuleSourceFile && languageVersion < 2 && options.module === 0) {
230480
230826
  const span = getErrorSpanForNode(firstNonAmbientExternalModuleSourceFile, typeof firstNonAmbientExternalModuleSourceFile.externalModuleIndicator === "boolean" ? firstNonAmbientExternalModuleSourceFile : firstNonAmbientExternalModuleSourceFile.externalModuleIndicator);
230481
- programDiagnostics.add(createFileDiagnostic(firstNonAmbientExternalModuleSourceFile, span.start, span.length, Diagnostics.Cannot_use_imports_exports_or_module_augmentations_when_module_is_none));
230827
+ programDiagnostics.addConfigDiagnostic(createFileDiagnostic(firstNonAmbientExternalModuleSourceFile, span.start, span.length, Diagnostics.Cannot_use_imports_exports_or_module_augmentations_when_module_is_none));
230482
230828
  }
230483
230829
  if (outputFile && !options.emitDeclarationOnly) {
230484
230830
  if (options.module && !(options.module === 2 || options.module === 4)) {
230485
230831
  createDiagnosticForOptionName(Diagnostics.Only_amd_and_system_modules_are_supported_alongside_0, "outFile", "module");
230486
230832
  } else if (options.module === void 0 && firstNonAmbientExternalModuleSourceFile) {
230487
230833
  const span = getErrorSpanForNode(firstNonAmbientExternalModuleSourceFile, typeof firstNonAmbientExternalModuleSourceFile.externalModuleIndicator === "boolean" ? firstNonAmbientExternalModuleSourceFile : firstNonAmbientExternalModuleSourceFile.externalModuleIndicator);
230488
- programDiagnostics.add(createFileDiagnostic(firstNonAmbientExternalModuleSourceFile, span.start, span.length, Diagnostics.Cannot_compile_modules_using_option_0_unless_the_module_flag_is_amd_or_system, "outFile"));
230834
+ programDiagnostics.addConfigDiagnostic(createFileDiagnostic(firstNonAmbientExternalModuleSourceFile, span.start, span.length, Diagnostics.Cannot_compile_modules_using_option_0_unless_the_module_flag_is_amd_or_system, "outFile"));
230489
230835
  }
230490
230836
  }
230491
230837
  if (getResolveJsonModule(options)) {
@@ -230574,7 +230920,8 @@ ${lanes.join("\n")}
230574
230920
  }
230575
230921
  if (ModuleKind[moduleKind] && 100 <= moduleKind && moduleKind <= 199 && !(3 <= moduleResolution && moduleResolution <= 99)) {
230576
230922
  const moduleKindName = ModuleKind[moduleKind];
230577
- createOptionValueDiagnostic("moduleResolution", Diagnostics.Option_moduleResolution_must_be_set_to_0_or_left_unspecified_when_option_module_is_set_to_1, moduleKindName, moduleKindName);
230923
+ const moduleResolutionName = ModuleResolutionKind[moduleKindName] ? moduleKindName : "Node16";
230924
+ createOptionValueDiagnostic("moduleResolution", Diagnostics.Option_moduleResolution_must_be_set_to_0_or_left_unspecified_when_option_module_is_set_to_1, moduleResolutionName, moduleKindName);
230578
230925
  } else if (ModuleResolutionKind[moduleResolution] && 3 <= moduleResolution && moduleResolution <= 99 && !(100 <= moduleKind && moduleKind <= 199)) {
230579
230926
  const moduleResolutionName = ModuleResolutionKind[moduleResolution];
230580
230927
  createOptionValueDiagnostic("module", Diagnostics.Option_module_must_be_set_to_0_when_option_moduleResolution_is_set_to_1, moduleResolutionName, moduleResolutionName);
@@ -230744,99 +231091,8 @@ ${lanes.join("\n")}
230744
231091
  });
230745
231092
  }
230746
231093
  __name(verifyDeprecatedProjectReference, "verifyDeprecatedProjectReference");
230747
- function createDiagnosticExplainingFile(file, fileProcessingReason, diagnostic, args) {
230748
- let seenReasons;
230749
- const reasons = file && fileReasons.get(file.path);
230750
- let fileIncludeReasons;
230751
- let relatedInfo;
230752
- let locationReason = isReferencedFile(fileProcessingReason) ? fileProcessingReason : void 0;
230753
- let fileIncludeReasonDetails;
230754
- let redirectInfo;
230755
- let cachedChain = file && (fileReasonsToChain == null ? void 0 : fileReasonsToChain.get(file.path));
230756
- let chain;
230757
- if (cachedChain) {
230758
- if (cachedChain.fileIncludeReasonDetails) {
230759
- seenReasons = new Set(reasons);
230760
- reasons == null ? void 0 : reasons.forEach(populateRelatedInfo);
230761
- } else {
230762
- reasons == null ? void 0 : reasons.forEach(processReason);
230763
- }
230764
- redirectInfo = cachedChain.redirectInfo;
230765
- } else {
230766
- reasons == null ? void 0 : reasons.forEach(processReason);
230767
- redirectInfo = file && explainIfFileIsRedirectAndImpliedFormat(file, getCompilerOptionsForFile(file));
230768
- }
230769
- if (fileProcessingReason) processReason(fileProcessingReason);
230770
- const processedExtraReason = (seenReasons == null ? void 0 : seenReasons.size) !== (reasons == null ? void 0 : reasons.length);
230771
- if (locationReason && (seenReasons == null ? void 0 : seenReasons.size) === 1) seenReasons = void 0;
230772
- if (seenReasons && cachedChain) {
230773
- if (cachedChain.details && !processedExtraReason) {
230774
- chain = chainDiagnosticMessages(cachedChain.details, diagnostic, ...args || emptyArray);
230775
- } else if (cachedChain.fileIncludeReasonDetails) {
230776
- if (!processedExtraReason) {
230777
- if (!cachedFileIncludeDetailsHasProcessedExtraReason()) {
230778
- fileIncludeReasonDetails = cachedChain.fileIncludeReasonDetails;
230779
- } else {
230780
- fileIncludeReasons = cachedChain.fileIncludeReasonDetails.next.slice(0, reasons.length);
230781
- }
230782
- } else {
230783
- if (!cachedFileIncludeDetailsHasProcessedExtraReason()) {
230784
- fileIncludeReasons = [
230785
- ...cachedChain.fileIncludeReasonDetails.next,
230786
- fileIncludeReasons[0]
230787
- ];
230788
- } else {
230789
- fileIncludeReasons = append(cachedChain.fileIncludeReasonDetails.next.slice(0, reasons.length), fileIncludeReasons[0]);
230790
- }
230791
- }
230792
- }
230793
- }
230794
- if (!chain) {
230795
- if (!fileIncludeReasonDetails) fileIncludeReasonDetails = seenReasons && chainDiagnosticMessages(fileIncludeReasons, Diagnostics.The_file_is_in_the_program_because_Colon);
230796
- chain = chainDiagnosticMessages(redirectInfo ? fileIncludeReasonDetails ? [
230797
- fileIncludeReasonDetails,
230798
- ...redirectInfo
230799
- ] : redirectInfo : fileIncludeReasonDetails, diagnostic, ...args || emptyArray);
230800
- }
230801
- if (file) {
230802
- if (cachedChain) {
230803
- if (!cachedChain.fileIncludeReasonDetails || !processedExtraReason && fileIncludeReasonDetails) {
230804
- cachedChain.fileIncludeReasonDetails = fileIncludeReasonDetails;
230805
- }
230806
- } else {
230807
- (fileReasonsToChain ?? (fileReasonsToChain = /* @__PURE__ */ new Map())).set(file.path, cachedChain = {
230808
- fileIncludeReasonDetails,
230809
- redirectInfo
230810
- });
230811
- }
230812
- if (!cachedChain.details && !processedExtraReason) cachedChain.details = chain.next;
230813
- }
230814
- const location2 = locationReason && getReferencedFileLocation(program2, locationReason);
230815
- return location2 && isReferenceFileLocation(location2) ? createFileDiagnosticFromMessageChain(location2.file, location2.pos, location2.end - location2.pos, chain, relatedInfo) : createCompilerDiagnosticFromMessageChain(chain, relatedInfo);
230816
- function processReason(reason) {
230817
- if (seenReasons == null ? void 0 : seenReasons.has(reason)) return;
230818
- (seenReasons ?? (seenReasons = /* @__PURE__ */ new Set())).add(reason);
230819
- (fileIncludeReasons ?? (fileIncludeReasons = [])).push(fileIncludeReasonToDiagnostics(program2, reason));
230820
- populateRelatedInfo(reason);
230821
- }
230822
- __name(processReason, "processReason");
230823
- function populateRelatedInfo(reason) {
230824
- if (!locationReason && isReferencedFile(reason)) {
230825
- locationReason = reason;
230826
- } else if (locationReason !== reason) {
230827
- relatedInfo = append(relatedInfo, getFileIncludeReasonToRelatedInformation(reason));
230828
- }
230829
- }
230830
- __name(populateRelatedInfo, "populateRelatedInfo");
230831
- function cachedFileIncludeDetailsHasProcessedExtraReason() {
230832
- var _a2;
230833
- return ((_a2 = cachedChain.fileIncludeReasonDetails.next) == null ? void 0 : _a2.length) !== (reasons == null ? void 0 : reasons.length);
230834
- }
230835
- __name(cachedFileIncludeDetailsHasProcessedExtraReason, "cachedFileIncludeDetailsHasProcessedExtraReason");
230836
- }
230837
- __name(createDiagnosticExplainingFile, "createDiagnosticExplainingFile");
230838
231094
  function addFilePreprocessingFileExplainingDiagnostic(file, fileProcessingReason, diagnostic, args) {
230839
- (fileProcessingDiagnostics || (fileProcessingDiagnostics = [])).push({
231095
+ programDiagnostics.addFileProcessingDiagnostic({
230840
231096
  kind: 1,
230841
231097
  file: file && file.path,
230842
231098
  fileProcessingReason,
@@ -230845,92 +231101,6 @@ ${lanes.join("\n")}
230845
231101
  });
230846
231102
  }
230847
231103
  __name(addFilePreprocessingFileExplainingDiagnostic, "addFilePreprocessingFileExplainingDiagnostic");
230848
- function addLazyProgramDiagnosticExplainingFile(file, diagnostic, args) {
230849
- lazyProgramDiagnosticExplainingFile.push({
230850
- file,
230851
- diagnostic,
230852
- args
230853
- });
230854
- }
230855
- __name(addLazyProgramDiagnosticExplainingFile, "addLazyProgramDiagnosticExplainingFile");
230856
- function getFileIncludeReasonToRelatedInformation(reason) {
230857
- let relatedInfo = reasonToRelatedInfo == null ? void 0 : reasonToRelatedInfo.get(reason);
230858
- if (relatedInfo === void 0) (reasonToRelatedInfo ?? (reasonToRelatedInfo = /* @__PURE__ */ new Map())).set(reason, relatedInfo = fileIncludeReasonToRelatedInformation(reason) ?? false);
230859
- return relatedInfo || void 0;
230860
- }
230861
- __name(getFileIncludeReasonToRelatedInformation, "getFileIncludeReasonToRelatedInformation");
230862
- function fileIncludeReasonToRelatedInformation(reason) {
230863
- if (isReferencedFile(reason)) {
230864
- const referenceLocation = getReferencedFileLocation(program2, reason);
230865
- let message2;
230866
- switch (reason.kind) {
230867
- case 3:
230868
- message2 = Diagnostics.File_is_included_via_import_here;
230869
- break;
230870
- case 4:
230871
- message2 = Diagnostics.File_is_included_via_reference_here;
230872
- break;
230873
- case 5:
230874
- message2 = Diagnostics.File_is_included_via_type_library_reference_here;
230875
- break;
230876
- case 7:
230877
- message2 = Diagnostics.File_is_included_via_library_reference_here;
230878
- break;
230879
- default:
230880
- Debug.assertNever(reason);
230881
- }
230882
- return isReferenceFileLocation(referenceLocation) ? createFileDiagnostic(referenceLocation.file, referenceLocation.pos, referenceLocation.end - referenceLocation.pos, message2) : void 0;
230883
- }
230884
- if (!options.configFile) return void 0;
230885
- let configFileNode;
230886
- let message;
230887
- switch (reason.kind) {
230888
- case 0:
230889
- if (!options.configFile.configFileSpecs) return void 0;
230890
- const fileName = getNormalizedAbsolutePath(rootNames[reason.index], currentDirectory);
230891
- const matchedByFiles = getMatchedFileSpec(program2, fileName);
230892
- if (matchedByFiles) {
230893
- configFileNode = getTsConfigPropArrayElementValue(options.configFile, "files", matchedByFiles);
230894
- message = Diagnostics.File_is_matched_by_files_list_specified_here;
230895
- break;
230896
- }
230897
- const matchedByInclude = getMatchedIncludeSpec(program2, fileName);
230898
- if (!matchedByInclude || !isString2(matchedByInclude)) return void 0;
230899
- configFileNode = getTsConfigPropArrayElementValue(options.configFile, "include", matchedByInclude);
230900
- message = Diagnostics.File_is_matched_by_include_pattern_specified_here;
230901
- break;
230902
- case 1:
230903
- case 2:
230904
- const referencedResolvedRef = Debug.checkDefined(resolvedProjectReferences == null ? void 0 : resolvedProjectReferences[reason.index]);
230905
- const referenceInfo = forEachProjectReference(projectReferences, resolvedProjectReferences, (resolvedRef, parent2, index22) => resolvedRef === referencedResolvedRef ? {
230906
- sourceFile: (parent2 == null ? void 0 : parent2.sourceFile) || options.configFile,
230907
- index: index22
230908
- } : void 0);
230909
- if (!referenceInfo) return void 0;
230910
- const { sourceFile, index: index2 } = referenceInfo;
230911
- const referencesSyntax = forEachTsConfigPropArray(sourceFile, "references", (property) => isArrayLiteralExpression(property.initializer) ? property.initializer : void 0);
230912
- return referencesSyntax && referencesSyntax.elements.length > index2 ? createDiagnosticForNodeInSourceFile(sourceFile, referencesSyntax.elements[index2], reason.kind === 2 ? Diagnostics.File_is_output_from_referenced_project_specified_here : Diagnostics.File_is_source_from_referenced_project_specified_here) : void 0;
230913
- case 8:
230914
- if (!options.types) return void 0;
230915
- configFileNode = getOptionsSyntaxByArrayElementValue("types", reason.typeReference);
230916
- message = Diagnostics.File_is_entry_point_of_type_library_specified_here;
230917
- break;
230918
- case 6:
230919
- if (reason.index !== void 0) {
230920
- configFileNode = getOptionsSyntaxByArrayElementValue("lib", options.lib[reason.index]);
230921
- message = Diagnostics.File_is_library_specified_here;
230922
- break;
230923
- }
230924
- const target = getNameOfScriptTarget(getEmitScriptTarget(options));
230925
- configFileNode = target ? getOptionsSyntaxByValue("target", target) : void 0;
230926
- message = Diagnostics.File_is_default_library_for_target_specified_here;
230927
- break;
230928
- default:
230929
- Debug.assertNever(reason);
230930
- }
230931
- return configFileNode && createDiagnosticForNodeInSourceFile(options.configFile, configFileNode, message);
230932
- }
230933
- __name(fileIncludeReasonToRelatedInformation, "fileIncludeReasonToRelatedInformation");
230934
231104
  function verifyProjectReferences() {
230935
231105
  const buildInfoPath = !options.suppressOutputPathCheck ? getTsBuildInfoEmitOutputFilePath(options) : void 0;
230936
231106
  forEachProjectReference(projectReferences, resolvedProjectReferences, (resolvedRef, parent2, index2) => {
@@ -230963,7 +231133,7 @@ ${lanes.join("\n")}
230963
231133
  forEachPropertyAssignment(pathProp.initializer, key, (keyProps) => {
230964
231134
  const initializer = keyProps.initializer;
230965
231135
  if (isArrayLiteralExpression(initializer) && initializer.elements.length > valueIndex) {
230966
- programDiagnostics.add(createDiagnosticForNodeInSourceFile(options.configFile, initializer.elements[valueIndex], message, ...args));
231136
+ programDiagnostics.addConfigDiagnostic(createDiagnosticForNodeInSourceFile(options.configFile, initializer.elements[valueIndex], message, ...args));
230967
231137
  needCompilerDiagnostic = false;
230968
231138
  }
230969
231139
  });
@@ -230994,23 +231164,10 @@ ${lanes.join("\n")}
230994
231164
  }
230995
231165
  }
230996
231166
  __name(createDiagnosticForOptionPaths, "createDiagnosticForOptionPaths");
230997
- function forEachOptionsSyntaxByName(name2, callback) {
230998
- return forEachPropertyAssignment(getCompilerOptionsObjectLiteralSyntax(), name2, callback);
230999
- }
231000
- __name(forEachOptionsSyntaxByName, "forEachOptionsSyntaxByName");
231001
231167
  function forEachOptionPathsSyntax(callback) {
231002
- return forEachOptionsSyntaxByName("paths", callback);
231168
+ return forEachOptionsSyntaxByName(getCompilerOptionsObjectLiteralSyntax(), "paths", callback);
231003
231169
  }
231004
231170
  __name(forEachOptionPathsSyntax, "forEachOptionPathsSyntax");
231005
- function getOptionsSyntaxByValue(name2, value1) {
231006
- return forEachOptionsSyntaxByName(name2, (property) => isStringLiteral(property.initializer) && property.initializer.text === value1 ? property.initializer : void 0);
231007
- }
231008
- __name(getOptionsSyntaxByValue, "getOptionsSyntaxByValue");
231009
- function getOptionsSyntaxByArrayElementValue(name2, value1) {
231010
- const compilerOptionsObjectLiteralSyntax = getCompilerOptionsObjectLiteralSyntax();
231011
- return compilerOptionsObjectLiteralSyntax && getPropertyArrayElementValue(compilerOptionsObjectLiteralSyntax, name2, value1);
231012
- }
231013
- __name(getOptionsSyntaxByArrayElementValue, "getOptionsSyntaxByArrayElementValue");
231014
231171
  function createDiagnosticForOptionName(message, option1, option2, option3) {
231015
231172
  createDiagnosticForOption(
231016
231173
  /*onKey*/
@@ -231039,9 +231196,9 @@ ${lanes.join("\n")}
231039
231196
  function createDiagnosticForReference(sourceFile, index2, message, ...args) {
231040
231197
  const referencesSyntax = forEachTsConfigPropArray(sourceFile || options.configFile, "references", (property) => isArrayLiteralExpression(property.initializer) ? property.initializer : void 0);
231041
231198
  if (referencesSyntax && referencesSyntax.elements.length > index2) {
231042
- programDiagnostics.add(createDiagnosticForNodeInSourceFile(sourceFile || options.configFile, referencesSyntax.elements[index2], message, ...args));
231199
+ programDiagnostics.addConfigDiagnostic(createDiagnosticForNodeInSourceFile(sourceFile || options.configFile, referencesSyntax.elements[index2], message, ...args));
231043
231200
  } else {
231044
- programDiagnostics.add(createCompilerDiagnostic(message, ...args));
231201
+ programDiagnostics.addConfigDiagnostic(createCompilerDiagnostic(message, ...args));
231045
231202
  }
231046
231203
  }
231047
231204
  __name(createDiagnosticForReference, "createDiagnosticForReference");
@@ -231057,14 +231214,14 @@ ${lanes.join("\n")}
231057
231214
  const compilerOptionsProperty = getCompilerOptionsPropertySyntax();
231058
231215
  if (compilerOptionsProperty) {
231059
231216
  if ("messageText" in message) {
231060
- programDiagnostics.add(createDiagnosticForNodeFromMessageChain(options.configFile, compilerOptionsProperty.name, message));
231217
+ programDiagnostics.addConfigDiagnostic(createDiagnosticForNodeFromMessageChain(options.configFile, compilerOptionsProperty.name, message));
231061
231218
  } else {
231062
- programDiagnostics.add(createDiagnosticForNodeInSourceFile(options.configFile, compilerOptionsProperty.name, message, ...args));
231219
+ programDiagnostics.addConfigDiagnostic(createDiagnosticForNodeInSourceFile(options.configFile, compilerOptionsProperty.name, message, ...args));
231063
231220
  }
231064
231221
  } else if ("messageText" in message) {
231065
- programDiagnostics.add(createCompilerDiagnosticFromMessageChain(message));
231222
+ programDiagnostics.addConfigDiagnostic(createCompilerDiagnosticFromMessageChain(message));
231066
231223
  } else {
231067
- programDiagnostics.add(createCompilerDiagnostic(message, ...args));
231224
+ programDiagnostics.addConfigDiagnostic(createCompilerDiagnostic(message, ...args));
231068
231225
  }
231069
231226
  }
231070
231227
  __name(createCompilerOptionsDiagnostic, "createCompilerOptionsDiagnostic");
@@ -231087,9 +231244,9 @@ ${lanes.join("\n")}
231087
231244
  let needsCompilerDiagnostic = false;
231088
231245
  forEachPropertyAssignment(objectLiteral, key1, (prop) => {
231089
231246
  if ("messageText" in message) {
231090
- programDiagnostics.add(createDiagnosticForNodeFromMessageChain(options.configFile, onKey ? prop.name : prop.initializer, message));
231247
+ programDiagnostics.addConfigDiagnostic(createDiagnosticForNodeFromMessageChain(options.configFile, onKey ? prop.name : prop.initializer, message));
231091
231248
  } else {
231092
- programDiagnostics.add(createDiagnosticForNodeInSourceFile(options.configFile, onKey ? prop.name : prop.initializer, message, ...args));
231249
+ programDiagnostics.addConfigDiagnostic(createDiagnosticForNodeInSourceFile(options.configFile, onKey ? prop.name : prop.initializer, message, ...args));
231093
231250
  }
231094
231251
  needsCompilerDiagnostic = true;
231095
231252
  }, key2);
@@ -231098,7 +231255,7 @@ ${lanes.join("\n")}
231098
231255
  __name(createOptionDiagnosticInObjectLiteralSyntax, "createOptionDiagnosticInObjectLiteralSyntax");
231099
231256
  function blockEmittingOfFile(emitFileName, diag2) {
231100
231257
  hasEmitBlockingDiagnostics.set(toPath32(emitFileName), true);
231101
- programDiagnostics.add(diag2);
231258
+ programDiagnostics.addConfigDiagnostic(diag2);
231102
231259
  }
231103
231260
  __name(blockEmittingOfFile, "blockEmittingOfFile");
231104
231261
  function isEmittedFile(file) {
@@ -231484,6 +231641,275 @@ ${lanes.join("\n")}
231484
231641
  Debug.fail("should never ask for module name at index higher than possible module name");
231485
231642
  }
231486
231643
  __name(getModuleNameStringLiteralAt, "getModuleNameStringLiteralAt");
231644
+ function createProgramDiagnostics(getCompilerOptionsObjectLiteralSyntax) {
231645
+ let computedDiagnostics;
231646
+ let fileReasons = createMultiMap();
231647
+ let fileProcessingDiagnostics;
231648
+ let commonSourceDirectory;
231649
+ let configDiagnostics;
231650
+ let lazyConfigDiagnostics;
231651
+ let fileReasonsToChain;
231652
+ let reasonToRelatedInfo;
231653
+ return {
231654
+ addConfigDiagnostic(diag2) {
231655
+ Debug.assert(computedDiagnostics === void 0, "Cannot modify program diagnostic state after requesting combined diagnostics");
231656
+ (configDiagnostics ?? (configDiagnostics = createDiagnosticCollection())).add(diag2);
231657
+ },
231658
+ addLazyConfigDiagnostic(file, message, ...args) {
231659
+ Debug.assert(computedDiagnostics === void 0, "Cannot modify program diagnostic state after requesting combined diagnostics");
231660
+ (lazyConfigDiagnostics ?? (lazyConfigDiagnostics = [])).push({
231661
+ file,
231662
+ diagnostic: message,
231663
+ args
231664
+ });
231665
+ },
231666
+ addFileProcessingDiagnostic(diag2) {
231667
+ Debug.assert(computedDiagnostics === void 0, "Cannot modify program diagnostic state after requesting combined diagnostics");
231668
+ (fileProcessingDiagnostics ?? (fileProcessingDiagnostics = [])).push(diag2);
231669
+ },
231670
+ setCommonSourceDirectory(directory) {
231671
+ commonSourceDirectory = directory;
231672
+ },
231673
+ reuseStateFromOldProgram(oldProgramDiagnostics, isConfigIdentical) {
231674
+ fileReasons = oldProgramDiagnostics.getFileReasons();
231675
+ fileProcessingDiagnostics = oldProgramDiagnostics.getFileProcessingDiagnostics();
231676
+ if (isConfigIdentical) {
231677
+ commonSourceDirectory = oldProgramDiagnostics.getCommonSourceDirectory();
231678
+ configDiagnostics = oldProgramDiagnostics.getConfigDiagnostics();
231679
+ lazyConfigDiagnostics = oldProgramDiagnostics.getLazyConfigDiagnostics();
231680
+ }
231681
+ },
231682
+ getFileProcessingDiagnostics() {
231683
+ return fileProcessingDiagnostics;
231684
+ },
231685
+ getFileReasons() {
231686
+ return fileReasons;
231687
+ },
231688
+ getCommonSourceDirectory() {
231689
+ return commonSourceDirectory;
231690
+ },
231691
+ getConfigDiagnostics() {
231692
+ return configDiagnostics;
231693
+ },
231694
+ getLazyConfigDiagnostics() {
231695
+ return lazyConfigDiagnostics;
231696
+ },
231697
+ getCombinedDiagnostics(program2) {
231698
+ if (computedDiagnostics) {
231699
+ return computedDiagnostics;
231700
+ }
231701
+ computedDiagnostics = createDiagnosticCollection();
231702
+ configDiagnostics == null ? void 0 : configDiagnostics.getDiagnostics().forEach((d) => computedDiagnostics.add(d));
231703
+ fileProcessingDiagnostics == null ? void 0 : fileProcessingDiagnostics.forEach((diagnostic) => {
231704
+ switch (diagnostic.kind) {
231705
+ case 1:
231706
+ return computedDiagnostics.add(createDiagnosticExplainingFile(program2, diagnostic.file && program2.getSourceFileByPath(diagnostic.file), diagnostic.fileProcessingReason, diagnostic.diagnostic, diagnostic.args || emptyArray));
231707
+ case 0:
231708
+ return computedDiagnostics.add(filePreprocessingLibreferenceDiagnostic(program2, diagnostic));
231709
+ case 2:
231710
+ return diagnostic.diagnostics.forEach((d) => computedDiagnostics.add(d));
231711
+ default:
231712
+ Debug.assertNever(diagnostic);
231713
+ }
231714
+ });
231715
+ lazyConfigDiagnostics == null ? void 0 : lazyConfigDiagnostics.forEach(({ file, diagnostic, args }) => computedDiagnostics.add(createDiagnosticExplainingFile(
231716
+ program2,
231717
+ file,
231718
+ /*fileProcessingReason*/
231719
+ void 0,
231720
+ diagnostic,
231721
+ args
231722
+ )));
231723
+ fileReasonsToChain = void 0;
231724
+ reasonToRelatedInfo = void 0;
231725
+ return computedDiagnostics;
231726
+ }
231727
+ };
231728
+ function filePreprocessingLibreferenceDiagnostic(program2, { reason }) {
231729
+ const { file, pos, end } = getReferencedFileLocation(program2, reason);
231730
+ const libReference = file.libReferenceDirectives[reason.index];
231731
+ const libName = getLibNameFromLibReference(libReference);
231732
+ const unqualifiedLibName = removeSuffix(removePrefix(libName, "lib."), ".d.ts");
231733
+ const suggestion = getSpellingSuggestion(unqualifiedLibName, libs, identity2);
231734
+ return createFileDiagnostic(file, Debug.checkDefined(pos), Debug.checkDefined(end) - pos, suggestion ? Diagnostics.Cannot_find_lib_definition_for_0_Did_you_mean_1 : Diagnostics.Cannot_find_lib_definition_for_0, libName, suggestion);
231735
+ }
231736
+ __name(filePreprocessingLibreferenceDiagnostic, "filePreprocessingLibreferenceDiagnostic");
231737
+ function createDiagnosticExplainingFile(program2, file, fileProcessingReason, diagnostic, args) {
231738
+ let seenReasons;
231739
+ let fileIncludeReasons;
231740
+ let relatedInfo;
231741
+ let fileIncludeReasonDetails;
231742
+ let redirectInfo;
231743
+ let chain;
231744
+ const reasons = file && fileReasons.get(file.path);
231745
+ let locationReason = isReferencedFile(fileProcessingReason) ? fileProcessingReason : void 0;
231746
+ let cachedChain = file && (fileReasonsToChain == null ? void 0 : fileReasonsToChain.get(file.path));
231747
+ if (cachedChain) {
231748
+ if (cachedChain.fileIncludeReasonDetails) {
231749
+ seenReasons = new Set(reasons);
231750
+ reasons == null ? void 0 : reasons.forEach(populateRelatedInfo);
231751
+ } else {
231752
+ reasons == null ? void 0 : reasons.forEach(processReason);
231753
+ }
231754
+ redirectInfo = cachedChain.redirectInfo;
231755
+ } else {
231756
+ reasons == null ? void 0 : reasons.forEach(processReason);
231757
+ redirectInfo = file && explainIfFileIsRedirectAndImpliedFormat(file, program2.getCompilerOptionsForFile(file));
231758
+ }
231759
+ if (fileProcessingReason) processReason(fileProcessingReason);
231760
+ const processedExtraReason = (seenReasons == null ? void 0 : seenReasons.size) !== (reasons == null ? void 0 : reasons.length);
231761
+ if (locationReason && (seenReasons == null ? void 0 : seenReasons.size) === 1) seenReasons = void 0;
231762
+ if (seenReasons && cachedChain) {
231763
+ if (cachedChain.details && !processedExtraReason) {
231764
+ chain = chainDiagnosticMessages(cachedChain.details, diagnostic, ...args ?? emptyArray);
231765
+ } else if (cachedChain.fileIncludeReasonDetails) {
231766
+ if (!processedExtraReason) {
231767
+ if (!cachedFileIncludeDetailsHasProcessedExtraReason()) {
231768
+ fileIncludeReasonDetails = cachedChain.fileIncludeReasonDetails;
231769
+ } else {
231770
+ fileIncludeReasons = cachedChain.fileIncludeReasonDetails.next.slice(0, reasons.length);
231771
+ }
231772
+ } else {
231773
+ if (!cachedFileIncludeDetailsHasProcessedExtraReason()) {
231774
+ fileIncludeReasons = [
231775
+ ...cachedChain.fileIncludeReasonDetails.next,
231776
+ fileIncludeReasons[0]
231777
+ ];
231778
+ } else {
231779
+ fileIncludeReasons = append(cachedChain.fileIncludeReasonDetails.next.slice(0, reasons.length), fileIncludeReasons[0]);
231780
+ }
231781
+ }
231782
+ }
231783
+ }
231784
+ if (!chain) {
231785
+ if (!fileIncludeReasonDetails) fileIncludeReasonDetails = seenReasons && chainDiagnosticMessages(fileIncludeReasons, Diagnostics.The_file_is_in_the_program_because_Colon);
231786
+ chain = chainDiagnosticMessages(redirectInfo ? fileIncludeReasonDetails ? [
231787
+ fileIncludeReasonDetails,
231788
+ ...redirectInfo
231789
+ ] : redirectInfo : fileIncludeReasonDetails, diagnostic, ...args || emptyArray);
231790
+ }
231791
+ if (file) {
231792
+ if (cachedChain) {
231793
+ if (!cachedChain.fileIncludeReasonDetails || !processedExtraReason && fileIncludeReasonDetails) {
231794
+ cachedChain.fileIncludeReasonDetails = fileIncludeReasonDetails;
231795
+ }
231796
+ } else {
231797
+ (fileReasonsToChain ?? (fileReasonsToChain = /* @__PURE__ */ new Map())).set(file.path, cachedChain = {
231798
+ fileIncludeReasonDetails,
231799
+ redirectInfo
231800
+ });
231801
+ }
231802
+ if (!cachedChain.details && !processedExtraReason) cachedChain.details = chain.next;
231803
+ }
231804
+ const location2 = locationReason && getReferencedFileLocation(program2, locationReason);
231805
+ return location2 && isReferenceFileLocation(location2) ? createFileDiagnosticFromMessageChain(location2.file, location2.pos, location2.end - location2.pos, chain, relatedInfo) : createCompilerDiagnosticFromMessageChain(chain, relatedInfo);
231806
+ function processReason(reason) {
231807
+ if (seenReasons == null ? void 0 : seenReasons.has(reason)) return;
231808
+ (seenReasons ?? (seenReasons = /* @__PURE__ */ new Set())).add(reason);
231809
+ (fileIncludeReasons ?? (fileIncludeReasons = [])).push(fileIncludeReasonToDiagnostics(program2, reason));
231810
+ populateRelatedInfo(reason);
231811
+ }
231812
+ __name(processReason, "processReason");
231813
+ function populateRelatedInfo(reason) {
231814
+ if (!locationReason && isReferencedFile(reason)) {
231815
+ locationReason = reason;
231816
+ } else if (locationReason !== reason) {
231817
+ relatedInfo = append(relatedInfo, getFileIncludeReasonToRelatedInformation(program2, reason));
231818
+ }
231819
+ }
231820
+ __name(populateRelatedInfo, "populateRelatedInfo");
231821
+ function cachedFileIncludeDetailsHasProcessedExtraReason() {
231822
+ var _a;
231823
+ return ((_a = cachedChain.fileIncludeReasonDetails.next) == null ? void 0 : _a.length) !== (reasons == null ? void 0 : reasons.length);
231824
+ }
231825
+ __name(cachedFileIncludeDetailsHasProcessedExtraReason, "cachedFileIncludeDetailsHasProcessedExtraReason");
231826
+ }
231827
+ __name(createDiagnosticExplainingFile, "createDiagnosticExplainingFile");
231828
+ function getFileIncludeReasonToRelatedInformation(program2, reason) {
231829
+ let relatedInfo = reasonToRelatedInfo == null ? void 0 : reasonToRelatedInfo.get(reason);
231830
+ if (relatedInfo === void 0) (reasonToRelatedInfo ?? (reasonToRelatedInfo = /* @__PURE__ */ new Map())).set(reason, relatedInfo = fileIncludeReasonToRelatedInformation(program2, reason) ?? false);
231831
+ return relatedInfo || void 0;
231832
+ }
231833
+ __name(getFileIncludeReasonToRelatedInformation, "getFileIncludeReasonToRelatedInformation");
231834
+ function fileIncludeReasonToRelatedInformation(program2, reason) {
231835
+ if (isReferencedFile(reason)) {
231836
+ const referenceLocation = getReferencedFileLocation(program2, reason);
231837
+ let message2;
231838
+ switch (reason.kind) {
231839
+ case 3:
231840
+ message2 = Diagnostics.File_is_included_via_import_here;
231841
+ break;
231842
+ case 4:
231843
+ message2 = Diagnostics.File_is_included_via_reference_here;
231844
+ break;
231845
+ case 5:
231846
+ message2 = Diagnostics.File_is_included_via_type_library_reference_here;
231847
+ break;
231848
+ case 7:
231849
+ message2 = Diagnostics.File_is_included_via_library_reference_here;
231850
+ break;
231851
+ default:
231852
+ Debug.assertNever(reason);
231853
+ }
231854
+ return isReferenceFileLocation(referenceLocation) ? createFileDiagnostic(referenceLocation.file, referenceLocation.pos, referenceLocation.end - referenceLocation.pos, message2) : void 0;
231855
+ }
231856
+ const currentDirectory = program2.getCurrentDirectory();
231857
+ const rootNames = program2.getRootFileNames();
231858
+ const options = program2.getCompilerOptions();
231859
+ if (!options.configFile) return void 0;
231860
+ let configFileNode;
231861
+ let message;
231862
+ switch (reason.kind) {
231863
+ case 0:
231864
+ if (!options.configFile.configFileSpecs) return void 0;
231865
+ const fileName = getNormalizedAbsolutePath(rootNames[reason.index], currentDirectory);
231866
+ const matchedByFiles = getMatchedFileSpec(program2, fileName);
231867
+ if (matchedByFiles) {
231868
+ configFileNode = getTsConfigPropArrayElementValue(options.configFile, "files", matchedByFiles);
231869
+ message = Diagnostics.File_is_matched_by_files_list_specified_here;
231870
+ break;
231871
+ }
231872
+ const matchedByInclude = getMatchedIncludeSpec(program2, fileName);
231873
+ if (!matchedByInclude || !isString2(matchedByInclude)) return void 0;
231874
+ configFileNode = getTsConfigPropArrayElementValue(options.configFile, "include", matchedByInclude);
231875
+ message = Diagnostics.File_is_matched_by_include_pattern_specified_here;
231876
+ break;
231877
+ case 1:
231878
+ case 2:
231879
+ const resolvedProjectReferences = program2.getResolvedProjectReferences();
231880
+ const projectReferences = program2.getProjectReferences();
231881
+ const referencedResolvedRef = Debug.checkDefined(resolvedProjectReferences == null ? void 0 : resolvedProjectReferences[reason.index]);
231882
+ const referenceInfo = forEachProjectReference(projectReferences, resolvedProjectReferences, (resolvedRef, parent2, index22) => resolvedRef === referencedResolvedRef ? {
231883
+ sourceFile: (parent2 == null ? void 0 : parent2.sourceFile) || options.configFile,
231884
+ index: index22
231885
+ } : void 0);
231886
+ if (!referenceInfo) return void 0;
231887
+ const { sourceFile, index: index2 } = referenceInfo;
231888
+ const referencesSyntax = forEachTsConfigPropArray(sourceFile, "references", (property) => isArrayLiteralExpression(property.initializer) ? property.initializer : void 0);
231889
+ return referencesSyntax && referencesSyntax.elements.length > index2 ? createDiagnosticForNodeInSourceFile(sourceFile, referencesSyntax.elements[index2], reason.kind === 2 ? Diagnostics.File_is_output_from_referenced_project_specified_here : Diagnostics.File_is_source_from_referenced_project_specified_here) : void 0;
231890
+ case 8:
231891
+ if (!options.types) return void 0;
231892
+ configFileNode = getOptionsSyntaxByArrayElementValue(getCompilerOptionsObjectLiteralSyntax(), "types", reason.typeReference);
231893
+ message = Diagnostics.File_is_entry_point_of_type_library_specified_here;
231894
+ break;
231895
+ case 6:
231896
+ if (reason.index !== void 0) {
231897
+ configFileNode = getOptionsSyntaxByArrayElementValue(getCompilerOptionsObjectLiteralSyntax(), "lib", options.lib[reason.index]);
231898
+ message = Diagnostics.File_is_library_specified_here;
231899
+ break;
231900
+ }
231901
+ const target = getNameOfScriptTarget(getEmitScriptTarget(options));
231902
+ configFileNode = target ? getOptionsSyntaxByValue(getCompilerOptionsObjectLiteralSyntax(), "target", target) : void 0;
231903
+ message = Diagnostics.File_is_default_library_for_target_specified_here;
231904
+ break;
231905
+ default:
231906
+ Debug.assertNever(reason);
231907
+ }
231908
+ return configFileNode && createDiagnosticForNodeInSourceFile(options.configFile, configFileNode, message);
231909
+ }
231910
+ __name(fileIncludeReasonToRelatedInformation, "fileIncludeReasonToRelatedInformation");
231911
+ }
231912
+ __name(createProgramDiagnostics, "createProgramDiagnostics");
231487
231913
  function getFileEmitOutput(program2, sourceFile, emitOnlyDtsFiles, cancellationToken, customTransformers, forceDtsEmit) {
231488
231914
  const outputFiles = [];
231489
231915
  const { emitSkipped, diagnostics } = program2.emit(sourceFile, writeFile22, cancellationToken, emitOnlyDtsFiles, customTransformers, forceDtsEmit);
@@ -239750,18 +240176,15 @@ ${lanes.join("\n")}
239750
240176
  }
239751
240177
  __name(typeFromExpression, "typeFromExpression");
239752
240178
  function typeFromFunctionLikeExpression(fnNode, context) {
239753
- const oldNoInferenceFallback = context.noInferenceFallback;
239754
- context.noInferenceFallback = true;
239755
- createReturnFromSignature(
240179
+ const returnType = createReturnFromSignature(
239756
240180
  fnNode,
239757
240181
  /*symbol*/
239758
240182
  void 0,
239759
240183
  context
239760
240184
  );
239761
- reuseTypeParameters(fnNode.typeParameters, context);
239762
- fnNode.parameters.map((p) => ensureParameter(p, context));
239763
- context.noInferenceFallback = oldNoInferenceFallback;
239764
- return notImplemented2;
240185
+ const typeParameters = reuseTypeParameters(fnNode.typeParameters, context);
240186
+ const parameters = fnNode.parameters.map((p) => ensureParameter(p, context));
240187
+ return syntacticResult(factory.createFunctionTypeNode(typeParameters, parameters, returnType));
239765
240188
  }
239766
240189
  __name(typeFromFunctionLikeExpression, "typeFromFunctionLikeExpression");
239767
240190
  function canGetTypeFromArrayLiteral(arrayLiteral, context, isConstContext) {
@@ -243813,7 +244236,7 @@ ${lanes.join("\n")}
243813
244236
  }
243814
244237
  __name(moduleSymbolToValidIdentifier, "moduleSymbolToValidIdentifier");
243815
244238
  function moduleSpecifierToValidIdentifier(moduleSpecifier, target, forceCapitalize) {
243816
- const baseName = getBaseFileName(removeSuffix(moduleSpecifier, "/index"));
244239
+ const baseName = getBaseFileName(removeSuffix(removeFileExtension(moduleSpecifier), "/index"));
243817
244240
  let res = "";
243818
244241
  let lastCharWasValid = true;
243819
244242
  const firstCharCode = baseName.charCodeAt(0);
@@ -250650,7 +251073,7 @@ interface Symbol {
250650
251073
  const unusedImportsFromOldFile = /* @__PURE__ */ new Set();
250651
251074
  for (const statement of toMove) {
250652
251075
  forEachReference(statement, checker, enclosingRange, (symbol, isValidTypeOnlyUseSite) => {
250653
- if (!symbol.declarations) {
251076
+ if (!some(symbol.declarations)) {
250654
251077
  return;
250655
251078
  }
250656
251079
  if (existingTargetLocals.has(skipAlias(symbol, checker))) {
@@ -262704,6 +263127,7 @@ ${newComment.split("\n").map((c) => ` * ${c}`).join("\n")}
262704
263127
  Diagnostics.Cannot_find_name_0_Do_you_need_to_install_type_definitions_for_node_Try_npm_i_save_dev_types_Slashnode.code,
262705
263128
  Diagnostics.Cannot_find_name_0_Do_you_need_to_install_type_definitions_for_node_Try_npm_i_save_dev_types_Slashnode_and_then_add_node_to_the_types_field_in_your_tsconfig.code,
262706
263129
  Diagnostics.Cannot_find_namespace_0_Did_you_mean_1.code,
263130
+ Diagnostics.Cannot_extend_an_interface_0_Did_you_mean_implements.code,
262707
263131
  Diagnostics.This_JSX_tag_requires_0_to_be_in_scope_but_it_could_not_be_found.code
262708
263132
  ];
262709
263133
  registerCodeFix({
@@ -263963,6 +264387,7 @@ ${newComment.split("\n").map((c) => ` * ${c}`).join("\n")}
263963
264387
  case 200:
263964
264388
  return 2;
263965
264389
  case 100:
264390
+ case 101:
263966
264391
  case 199:
263967
264392
  return getImpliedNodeFormatForEmit(importingFile, program2) === 99 ? 2 : 3;
263968
264393
  default:
@@ -265564,7 +265989,8 @@ ${newComment.split("\n").map((c) => ` * ${c}`).join("\n")}
265564
265989
  Diagnostics.Type_0_is_missing_the_following_properties_from_type_1_Colon_2.code,
265565
265990
  Diagnostics.Type_0_is_missing_the_following_properties_from_type_1_Colon_2_and_3_more.code,
265566
265991
  Diagnostics.Argument_of_type_0_is_not_assignable_to_parameter_of_type_1.code,
265567
- Diagnostics.Cannot_find_name_0.code
265992
+ Diagnostics.Cannot_find_name_0.code,
265993
+ Diagnostics.Type_0_does_not_satisfy_the_expected_type_1.code
265568
265994
  ];
265569
265995
  registerCodeFix({
265570
265996
  errorCodes: errorCodes28,
@@ -265620,9 +266046,9 @@ ${newComment.split("\n").map((c) => ` * ${c}`).join("\n")}
265620
266046
  return createCombinedCodeActions(ts_textChanges_exports.ChangeTracker.with(context, (changes) => {
265621
266047
  eachDiagnostic(context, errorCodes28, (diag2) => {
265622
266048
  const info = getInfo10(diag2.file, diag2.start, diag2.code, checker, context.program);
265623
- if (!info || !addToSeen(seen, getNodeId(info.parentDeclaration) + "#" + (info.kind === 3 ? info.identifier : info.token.text))) {
265624
- return;
265625
- }
266049
+ if (info === void 0) return;
266050
+ const nodeId = getNodeId(info.parentDeclaration) + "#" + (info.kind === 3 ? info.identifier || getNodeId(info.token) : info.token.text);
266051
+ if (!addToSeen(seen, nodeId)) return;
265626
266052
  if (fixId56 === fixMissingFunctionDeclaration && (info.kind === 2 || info.kind === 5)) {
265627
266053
  addFunctionDeclaration(changes, context, info);
265628
266054
  } else if (fixId56 === fixMissingProperties && info.kind === 3) {
@@ -265674,7 +266100,7 @@ ${newComment.split("\n").map((c) => ` * ${c}`).join("\n")}
265674
266100
  }, "getAllCodeActions")
265675
266101
  });
265676
266102
  function getInfo10(sourceFile, tokenPos, errorCode, checker, program2) {
265677
- var _a, _b, _c;
266103
+ var _a, _b;
265678
266104
  const token = getTokenAtPosition(sourceFile, tokenPos);
265679
266105
  const parent2 = token.parent;
265680
266106
  if (errorCode === Diagnostics.Argument_of_type_0_is_not_assignable_to_parameter_of_type_1.code) {
@@ -265702,29 +266128,32 @@ ${newComment.split("\n").map((c) => ` * ${c}`).join("\n")}
265702
266128
  parentDeclaration: parent2
265703
266129
  };
265704
266130
  }
265705
- if (token.kind === 19 && isObjectLiteralExpression(parent2)) {
265706
- const targetType = (_a = checker.getContextualType(parent2) || checker.getTypeAtLocation(parent2)) == null ? void 0 : _a.getNonNullableType();
265707
- const properties = arrayFrom(checker.getUnmatchedProperties(
265708
- checker.getTypeAtLocation(parent2),
265709
- targetType,
265710
- /*requireOptionalProperties*/
265711
- false,
265712
- /*matchDiscriminantProperties*/
265713
- false
265714
- ));
265715
- if (!length(properties)) return void 0;
265716
- const identifier = "";
265717
- return {
265718
- kind: 3,
265719
- token: parent2,
265720
- identifier,
265721
- properties,
265722
- parentDeclaration: parent2
265723
- };
266131
+ if (token.kind === 19 || isSatisfiesExpression(parent2) || isReturnStatement(parent2)) {
266132
+ const expression = (isSatisfiesExpression(parent2) || isReturnStatement(parent2)) && parent2.expression ? parent2.expression : parent2;
266133
+ if (isObjectLiteralExpression(expression)) {
266134
+ const targetType = isSatisfiesExpression(parent2) ? checker.getTypeFromTypeNode(parent2.type) : checker.getContextualType(expression) || checker.getTypeAtLocation(expression);
266135
+ const properties = arrayFrom(checker.getUnmatchedProperties(
266136
+ checker.getTypeAtLocation(parent2),
266137
+ targetType.getNonNullableType(),
266138
+ /*requireOptionalProperties*/
266139
+ false,
266140
+ /*matchDiscriminantProperties*/
266141
+ false
266142
+ ));
266143
+ if (!length(properties)) return void 0;
266144
+ return {
266145
+ kind: 3,
266146
+ token: parent2,
266147
+ identifier: void 0,
266148
+ properties,
266149
+ parentDeclaration: expression,
266150
+ indentation: isReturnStatement(expression.parent) || isYieldExpression(expression.parent) ? 0 : void 0
266151
+ };
266152
+ }
265724
266153
  }
265725
266154
  if (!isMemberName(token)) return void 0;
265726
266155
  if (isIdentifier(token) && hasInitializer(parent2) && parent2.initializer && isObjectLiteralExpression(parent2.initializer)) {
265727
- const targetType = (_b = checker.getContextualType(token) || checker.getTypeAtLocation(token)) == null ? void 0 : _b.getNonNullableType();
266156
+ const targetType = (_a = checker.getContextualType(token) || checker.getTypeAtLocation(token)) == null ? void 0 : _a.getNonNullableType();
265728
266157
  const properties = arrayFrom(checker.getUnmatchedProperties(
265729
266158
  checker.getTypeAtLocation(parent2.initializer),
265730
266159
  targetType,
@@ -265754,7 +266183,7 @@ ${newComment.split("\n").map((c) => ` * ${c}`).join("\n")}
265754
266183
  };
265755
266184
  }
265756
266185
  if (isIdentifier(token)) {
265757
- const type2 = (_c = checker.getContextualType(token)) == null ? void 0 : _c.getNonNullableType();
266186
+ const type2 = (_b = checker.getContextualType(token)) == null ? void 0 : _b.getNonNullableType();
265758
266187
  if (type2 && getObjectFlags(type2) & 16) {
265759
266188
  const signature = firstOrUndefined(checker.getSignaturesOfType(
265760
266189
  type2,
@@ -266941,9 +267370,9 @@ ${newComment.split("\n").map((c) => ` * ${c}`).join("\n")}
266941
267370
  __name(getSuggestion, "getSuggestion");
266942
267371
  registerCodeFix({
266943
267372
  errorCodes: [
266944
- Diagnostics.Top_level_await_expressions_are_only_allowed_when_the_module_option_is_set_to_es2022_esnext_system_node16_nodenext_or_preserve_and_the_target_option_is_set_to_es2017_or_higher.code,
266945
- Diagnostics.Top_level_await_using_statements_are_only_allowed_when_the_module_option_is_set_to_es2022_esnext_system_node16_nodenext_or_preserve_and_the_target_option_is_set_to_es2017_or_higher.code,
266946
- Diagnostics.Top_level_for_await_loops_are_only_allowed_when_the_module_option_is_set_to_es2022_esnext_system_node16_nodenext_or_preserve_and_the_target_option_is_set_to_es2017_or_higher.code
267373
+ Diagnostics.Top_level_await_expressions_are_only_allowed_when_the_module_option_is_set_to_es2022_esnext_system_node16_node18_nodenext_or_preserve_and_the_target_option_is_set_to_es2017_or_higher.code,
267374
+ Diagnostics.Top_level_await_using_statements_are_only_allowed_when_the_module_option_is_set_to_es2022_esnext_system_node16_node18_nodenext_or_preserve_and_the_target_option_is_set_to_es2017_or_higher.code,
267375
+ Diagnostics.Top_level_for_await_loops_are_only_allowed_when_the_module_option_is_set_to_es2022_esnext_system_node16_node18_nodenext_or_preserve_and_the_target_option_is_set_to_es2017_or_higher.code
266947
267376
  ],
266948
267377
  getCodeActions: /* @__PURE__ */ __name(function getCodeActionsToFixModuleAndTarget(context) {
266949
267378
  const compilerOptions = context.program.getCompilerOptions();
@@ -267513,6 +267942,8 @@ ${newComment.split("\n").map((c) => ` * ${c}`).join("\n")}
267513
267942
  break;
267514
267943
  } else if (canDeleteEntireVariableStatement(sourceFile, token)) {
267515
267944
  deleteEntireVariableStatement(changes, sourceFile, token.parent);
267945
+ } else if (isIdentifier(token) && isFunctionDeclaration(token.parent)) {
267946
+ deleteFunctionLikeDeclaration(changes, sourceFile, token.parent);
267516
267947
  } else {
267517
267948
  tryDeleteDeclaration(
267518
267949
  sourceFile,
@@ -270781,12 +271212,10 @@ ${newComment.split("\n").map((c) => ` * ${c}`).join("\n")}
270781
271212
  }
270782
271213
  __name(typeToAutoImportableTypeNode, "typeToAutoImportableTypeNode");
270783
271214
  function typeNodeToAutoImportableTypeNode(typeNode, importAdder, scriptTarget) {
270784
- if (typeNode && isImportTypeNode(typeNode)) {
270785
- const importableReference = tryGetAutoImportableReferenceFromTypeNode(typeNode, scriptTarget);
270786
- if (importableReference) {
270787
- importSymbols(importAdder, importableReference.symbols);
270788
- typeNode = importableReference.typeNode;
270789
- }
271215
+ const importableReference = tryGetAutoImportableReferenceFromTypeNode(typeNode, scriptTarget);
271216
+ if (importableReference) {
271217
+ importSymbols(importAdder, importableReference.symbols);
271218
+ typeNode = importableReference.typeNode;
270790
271219
  }
270791
271220
  return getSynthesizedDeepClone(typeNode);
270792
271221
  }
@@ -280519,7 +280948,7 @@ ${newComment.split("\n").map((c) => ` * ${c}`).join("\n")}
280519
280948
  } else {
280520
280949
  addIfImplementation(body);
280521
280950
  }
280522
- } else if (isAssertionExpression(typeHavingNode)) {
280951
+ } else if (isAssertionExpression(typeHavingNode) || isSatisfiesExpression(typeHavingNode)) {
280523
280952
  addIfImplementation(typeHavingNode.expression);
280524
280953
  }
280525
280954
  }
@@ -281034,7 +281463,10 @@ ${newComment.split("\n").map((c) => ` * ${c}`).join("\n")}
281034
281463
  const { parent: parent2 } = node;
281035
281464
  const typeChecker = program2.getTypeChecker();
281036
281465
  if (node.kind === 164 || isIdentifier(node) && isJSDocOverrideTag(parent2) && parent2.tagName === node) {
281037
- return getDefinitionFromOverriddenMember(typeChecker, node) || emptyArray;
281466
+ const def = getDefinitionFromOverriddenMember(typeChecker, node);
281467
+ if (def !== void 0 || node.kind !== 164) {
281468
+ return def || emptyArray;
281469
+ }
281038
281470
  }
281039
281471
  if (isJumpStatementTarget(node)) {
281040
281472
  const label = getTargetLabel(node.parent, node.text);
@@ -281050,11 +281482,6 @@ ${newComment.split("\n").map((c) => ` * ${c}`).join("\n")}
281050
281482
  ] : void 0;
281051
281483
  }
281052
281484
  switch (node.kind) {
281053
- case 107:
281054
- const functionDeclaration = findAncestor(node.parent, (n) => isClassStaticBlockDeclaration(n) ? "quit" : isFunctionLikeDeclaration(n));
281055
- return functionDeclaration ? [
281056
- createDefinitionFromSignatureDeclaration(typeChecker, functionDeclaration)
281057
- ] : void 0;
281058
281485
  case 90:
281059
281486
  if (!isDefaultClause(node.parent)) {
281060
281487
  break;
@@ -281069,23 +281496,16 @@ ${newComment.split("\n").map((c) => ` * ${c}`).join("\n")}
281069
281496
  }
281070
281497
  break;
281071
281498
  }
281072
- if (node.kind === 135) {
281073
- const functionDeclaration = findAncestor(node, (n) => isFunctionLikeDeclaration(n));
281074
- const isAsyncFunction2 = functionDeclaration && some(
281075
- functionDeclaration.modifiers,
281076
- (node2) => node2.kind === 134
281077
- /* AsyncKeyword */
281078
- );
281079
- return isAsyncFunction2 ? [
281080
- createDefinitionFromSignatureDeclaration(typeChecker, functionDeclaration)
281081
- ] : void 0;
281082
- }
281083
- if (node.kind === 127) {
281084
- const functionDeclaration = findAncestor(node, (n) => isFunctionLikeDeclaration(n));
281085
- const isGeneratorFunction = functionDeclaration && functionDeclaration.asteriskToken;
281086
- return isGeneratorFunction ? [
281087
- createDefinitionFromSignatureDeclaration(typeChecker, functionDeclaration)
281088
- ] : void 0;
281499
+ let findFunctionDecl;
281500
+ switch (node.kind) {
281501
+ case 107:
281502
+ case 135:
281503
+ case 127:
281504
+ findFunctionDecl = isFunctionLikeDeclaration;
281505
+ const functionDeclaration = findAncestor(node, findFunctionDecl);
281506
+ return functionDeclaration ? [
281507
+ createDefinitionFromSignatureDeclaration(typeChecker, functionDeclaration)
281508
+ ] : void 0;
281089
281509
  }
281090
281510
  if (isStaticModifier(node) && isClassStaticBlockDeclaration(node.parent)) {
281091
281511
  const classDecl = node.parent.parent;
@@ -281143,6 +281563,9 @@ ${newComment.split("\n").map((c) => ` * ${c}`).join("\n")}
281143
281563
  ];
281144
281564
  }
281145
281565
  }
281566
+ if (isModifier(node) && (isClassElement(parent2) || isNamedDeclaration(parent2))) {
281567
+ symbol = parent2.symbol;
281568
+ }
281146
281569
  if (!symbol) {
281147
281570
  return concatenate(fileReferenceDefinition, getDefinitionInfoForIndexSignatures(node, typeChecker));
281148
281571
  }
@@ -281372,12 +281795,16 @@ ${newComment.split("\n").map((c) => ` * ${c}`).join("\n")}
281372
281795
  false
281373
281796
  );
281374
281797
  }
281375
- const { symbol, failedAliasResolution } = getSymbol(
281798
+ let { symbol, failedAliasResolution } = getSymbol(
281376
281799
  node,
281377
281800
  typeChecker,
281378
281801
  /*stopAtAlias*/
281379
281802
  false
281380
281803
  );
281804
+ if (isModifier(node) && (isClassElement(node.parent) || isNamedDeclaration(node.parent))) {
281805
+ symbol = node.parent.symbol;
281806
+ failedAliasResolution = false;
281807
+ }
281381
281808
  if (!symbol) return void 0;
281382
281809
  const typeAtLocation = typeChecker.getTypeOfSymbolAtLocation(symbol, node);
281383
281810
  const returnType = tryGetReturnTypeOfFunction(symbol, typeAtLocation, typeChecker);
@@ -281951,23 +282378,26 @@ ${newComment.split("\n").map((c) => ` * ${c}`).join("\n")}
281951
282378
  if (!signature) {
281952
282379
  return;
281953
282380
  }
281954
- for (let i = 0; i < node.parameters.length && i < signature.parameters.length; ++i) {
281955
- const param = node.parameters[i];
281956
- if (!isHintableDeclaration(param)) {
281957
- continue;
281958
- }
281959
- const effectiveTypeAnnotation = getEffectiveTypeAnnotationNode(param);
281960
- if (effectiveTypeAnnotation) {
281961
- continue;
282381
+ let pos = 0;
282382
+ for (const param of node.parameters) {
282383
+ if (isHintableDeclaration(param)) {
282384
+ addParameterTypeHint(param, parameterIsThisKeyword(param) ? signature.thisParameter : signature.parameters[pos]);
281962
282385
  }
281963
- const typeHints = getParameterDeclarationTypeHints(signature.parameters[i]);
281964
- if (!typeHints) {
282386
+ if (parameterIsThisKeyword(param)) {
281965
282387
  continue;
281966
282388
  }
281967
- addTypeHints(typeHints, param.questionToken ? param.questionToken.end : param.name.end);
282389
+ pos++;
281968
282390
  }
281969
282391
  }
281970
282392
  __name(visitFunctionLikeForParameterType, "visitFunctionLikeForParameterType");
282393
+ function addParameterTypeHint(node, symbol) {
282394
+ const effectiveTypeAnnotation = getEffectiveTypeAnnotationNode(node);
282395
+ if (effectiveTypeAnnotation || symbol === void 0) return;
282396
+ const typeHints = getParameterDeclarationTypeHints(symbol);
282397
+ if (typeHints === void 0) return;
282398
+ addTypeHints(typeHints, node.questionToken ? node.questionToken.end : node.name.end);
282399
+ }
282400
+ __name(addParameterTypeHint, "addParameterTypeHint");
281971
282401
  function getParameterDeclarationTypeHints(symbol) {
281972
282402
  const valueDeclaration = symbol.valueDeclaration;
281973
282403
  if (!valueDeclaration || !isParameter(valueDeclaration)) {
@@ -293285,6 +293715,7 @@ ${options.prefix}` : "\n" : options.prefix
293285
293715
  createPrinterWithRemoveCommentsNeverAsciiEscape: /* @__PURE__ */ __name(() => createPrinterWithRemoveCommentsNeverAsciiEscape, "createPrinterWithRemoveCommentsNeverAsciiEscape"),
293286
293716
  createPrinterWithRemoveCommentsOmitTrailingSemicolon: /* @__PURE__ */ __name(() => createPrinterWithRemoveCommentsOmitTrailingSemicolon, "createPrinterWithRemoveCommentsOmitTrailingSemicolon"),
293287
293717
  createProgram: /* @__PURE__ */ __name(() => createProgram2, "createProgram"),
293718
+ createProgramDiagnostics: /* @__PURE__ */ __name(() => createProgramDiagnostics, "createProgramDiagnostics"),
293288
293719
  createProgramHost: /* @__PURE__ */ __name(() => createProgramHost, "createProgramHost"),
293289
293720
  createPropertyNameNodeForIdentifierOrLiteral: /* @__PURE__ */ __name(() => createPropertyNameNodeForIdentifierOrLiteral, "createPropertyNameNodeForIdentifierOrLiteral"),
293290
293721
  createQueue: /* @__PURE__ */ __name(() => createQueue, "createQueue"),
@@ -293454,6 +293885,8 @@ ${options.prefix}` : "\n" : options.prefix
293454
293885
  forEachLeadingCommentRange: /* @__PURE__ */ __name(() => forEachLeadingCommentRange, "forEachLeadingCommentRange"),
293455
293886
  forEachNameInAccessChainWalkingLeft: /* @__PURE__ */ __name(() => forEachNameInAccessChainWalkingLeft, "forEachNameInAccessChainWalkingLeft"),
293456
293887
  forEachNameOfDefaultExport: /* @__PURE__ */ __name(() => forEachNameOfDefaultExport, "forEachNameOfDefaultExport"),
293888
+ forEachOptionsSyntaxByName: /* @__PURE__ */ __name(() => forEachOptionsSyntaxByName, "forEachOptionsSyntaxByName"),
293889
+ forEachProjectReference: /* @__PURE__ */ __name(() => forEachProjectReference, "forEachProjectReference"),
293457
293890
  forEachPropertyAssignment: /* @__PURE__ */ __name(() => forEachPropertyAssignment, "forEachPropertyAssignment"),
293458
293891
  forEachResolvedProjectReference: /* @__PURE__ */ __name(() => forEachResolvedProjectReference, "forEachResolvedProjectReference"),
293459
293892
  forEachReturnStatement: /* @__PURE__ */ __name(() => forEachReturnStatement, "forEachReturnStatement"),
@@ -293693,6 +294126,8 @@ ${options.prefix}` : "\n" : options.prefix
293693
294126
  getLeadingCommentRangesOfNode: /* @__PURE__ */ __name(() => getLeadingCommentRangesOfNode, "getLeadingCommentRangesOfNode"),
293694
294127
  getLeftmostAccessExpression: /* @__PURE__ */ __name(() => getLeftmostAccessExpression, "getLeftmostAccessExpression"),
293695
294128
  getLeftmostExpression: /* @__PURE__ */ __name(() => getLeftmostExpression, "getLeftmostExpression"),
294129
+ getLibFileNameFromLibReference: /* @__PURE__ */ __name(() => getLibFileNameFromLibReference, "getLibFileNameFromLibReference"),
294130
+ getLibNameFromLibReference: /* @__PURE__ */ __name(() => getLibNameFromLibReference, "getLibNameFromLibReference"),
293696
294131
  getLibraryNameFromLibFileName: /* @__PURE__ */ __name(() => getLibraryNameFromLibFileName, "getLibraryNameFromLibFileName"),
293697
294132
  getLineAndCharacterOfPosition: /* @__PURE__ */ __name(() => getLineAndCharacterOfPosition, "getLineAndCharacterOfPosition"),
293698
294133
  getLineInfo: /* @__PURE__ */ __name(() => getLineInfo, "getLineInfo"),
@@ -293765,6 +294200,8 @@ ${options.prefix}` : "\n" : options.prefix
293765
294200
  getOptionFromName: /* @__PURE__ */ __name(() => getOptionFromName, "getOptionFromName"),
293766
294201
  getOptionsForLibraryResolution: /* @__PURE__ */ __name(() => getOptionsForLibraryResolution, "getOptionsForLibraryResolution"),
293767
294202
  getOptionsNameMap: /* @__PURE__ */ __name(() => getOptionsNameMap, "getOptionsNameMap"),
294203
+ getOptionsSyntaxByArrayElementValue: /* @__PURE__ */ __name(() => getOptionsSyntaxByArrayElementValue, "getOptionsSyntaxByArrayElementValue"),
294204
+ getOptionsSyntaxByValue: /* @__PURE__ */ __name(() => getOptionsSyntaxByValue, "getOptionsSyntaxByValue"),
293768
294205
  getOrCreateEmitNode: /* @__PURE__ */ __name(() => getOrCreateEmitNode, "getOrCreateEmitNode"),
293769
294206
  getOrUpdate: /* @__PURE__ */ __name(() => getOrUpdate, "getOrUpdate"),
293770
294207
  getOriginalNode: /* @__PURE__ */ __name(() => getOriginalNode, "getOriginalNode"),
@@ -293801,7 +294238,6 @@ ${options.prefix}` : "\n" : options.prefix
293801
294238
  getPrivateIdentifier: /* @__PURE__ */ __name(() => getPrivateIdentifier, "getPrivateIdentifier"),
293802
294239
  getProperties: /* @__PURE__ */ __name(() => getProperties, "getProperties"),
293803
294240
  getProperty: /* @__PURE__ */ __name(() => getProperty, "getProperty"),
293804
- getPropertyArrayElementValue: /* @__PURE__ */ __name(() => getPropertyArrayElementValue, "getPropertyArrayElementValue"),
293805
294241
  getPropertyAssignmentAliasLikeExpression: /* @__PURE__ */ __name(() => getPropertyAssignmentAliasLikeExpression, "getPropertyAssignmentAliasLikeExpression"),
293806
294242
  getPropertyNameForPropertyNameNode: /* @__PURE__ */ __name(() => getPropertyNameForPropertyNameNode, "getPropertyNameForPropertyNameNode"),
293807
294243
  getPropertyNameFromType: /* @__PURE__ */ __name(() => getPropertyNameFromType, "getPropertyNameFromType"),
@@ -294712,6 +295148,7 @@ ${options.prefix}` : "\n" : options.prefix
294712
295148
  moduleResolutionUsesNodeModules: /* @__PURE__ */ __name(() => moduleResolutionUsesNodeModules, "moduleResolutionUsesNodeModules"),
294713
295149
  moduleSpecifierToValidIdentifier: /* @__PURE__ */ __name(() => moduleSpecifierToValidIdentifier, "moduleSpecifierToValidIdentifier"),
294714
295150
  moduleSpecifiers: /* @__PURE__ */ __name(() => ts_moduleSpecifiers_exports, "moduleSpecifiers"),
295151
+ moduleSupportsImportAttributes: /* @__PURE__ */ __name(() => moduleSupportsImportAttributes, "moduleSupportsImportAttributes"),
294715
295152
  moduleSymbolToValidIdentifier: /* @__PURE__ */ __name(() => moduleSymbolToValidIdentifier, "moduleSymbolToValidIdentifier"),
294716
295153
  moveEmitHelpers: /* @__PURE__ */ __name(() => moveEmitHelpers, "moveEmitHelpers"),
294717
295154
  moveRangeEnd: /* @__PURE__ */ __name(() => moveRangeEnd, "moveRangeEnd"),
@@ -296142,6 +296579,7 @@ ${options.prefix}` : "\n" : options.prefix
296142
296579
  ModuleKind3["ES2022"] = "es2022";
296143
296580
  ModuleKind3["ESNext"] = "esnext";
296144
296581
  ModuleKind3["Node16"] = "node16";
296582
+ ModuleKind3["Node18"] = "node18";
296145
296583
  ModuleKind3["NodeNext"] = "nodenext";
296146
296584
  ModuleKind3["Preserve"] = "preserve";
296147
296585
  return ModuleKind3;
@@ -306526,18 +306964,19 @@ Project '${project.projectName}' (${ProjectKind[project.projectKind]}) ${counter
306526
306964
  try {
306527
306965
  codeActions = project.getLanguageService().getCodeFixesAtPosition(file, startPosition, endPosition, args.errorCodes, this.getFormatOptions(file), this.getPreferences(file));
306528
306966
  } catch (e) {
306967
+ const error22 = e instanceof Error ? e : new Error(e);
306529
306968
  const ls = project.getLanguageService();
306530
306969
  const existingDiagCodes = [
306531
306970
  ...ls.getSyntacticDiagnostics(file),
306532
306971
  ...ls.getSemanticDiagnostics(file),
306533
306972
  ...ls.getSuggestionDiagnostics(file)
306534
- ].map((d) => decodedTextSpanIntersectsWith(startPosition, endPosition - startPosition, d.start, d.length) && d.code);
306973
+ ].filter((d) => decodedTextSpanIntersectsWith(startPosition, endPosition - startPosition, d.start, d.length)).map((d) => d.code);
306535
306974
  const badCode = args.errorCodes.find((c) => !existingDiagCodes.includes(c));
306536
306975
  if (badCode !== void 0) {
306537
- e.message = `BADCLIENT: Bad error code, ${badCode} not found in range ${startPosition}..${endPosition} (found: ${existingDiagCodes.join(", ")}); could have caused this error:
306538
- ${e.message}`;
306976
+ error22.message += `
306977
+ Additional information: BADCLIENT: Bad error code, ${badCode} not found in range ${startPosition}..${endPosition} (found: ${existingDiagCodes.join(", ")})`;
306539
306978
  }
306540
- throw e;
306979
+ throw error22;
306541
306980
  }
306542
306981
  return simplifiedResult ? codeActions.map((codeAction) => this.mapCodeFixAction(codeAction)) : codeActions;
306543
306982
  }
@@ -338640,11 +339079,11 @@ function interpolate(target, source = {}, parse8 = (v) => v) {
338640
339079
  __name(interpolate, "interpolate");
338641
339080
  var _normalize = /* @__PURE__ */ __name((p) => p?.replace(/\\/g, "/"), "_normalize");
338642
339081
  var ASYNC_LOADERS = {
338643
- ".yaml": /* @__PURE__ */ __name(() => import("./yaml-ODZRTFYX.js").then((r) => r.parseYAML), ".yaml"),
338644
- ".yml": /* @__PURE__ */ __name(() => import("./yaml-ODZRTFYX.js").then((r) => r.parseYAML), ".yml"),
338645
- ".jsonc": /* @__PURE__ */ __name(() => import("./jsonc-HBV365B7.js").then((r) => r.parseJSONC), ".jsonc"),
338646
- ".json5": /* @__PURE__ */ __name(() => import("./json5-OPEY7IVI.js").then((r) => r.parseJSON5), ".json5"),
338647
- ".toml": /* @__PURE__ */ __name(() => import("./toml-4KC5RP7Q.js").then((r) => r.parseTOML), ".toml")
339082
+ ".yaml": /* @__PURE__ */ __name(() => import("./yaml-TI2L6CZN.js").then((r) => r.parseYAML), ".yaml"),
339083
+ ".yml": /* @__PURE__ */ __name(() => import("./yaml-TI2L6CZN.js").then((r) => r.parseYAML), ".yml"),
339084
+ ".jsonc": /* @__PURE__ */ __name(() => import("./jsonc-KYPEKHOV.js").then((r) => r.parseJSONC), ".jsonc"),
339085
+ ".json5": /* @__PURE__ */ __name(() => import("./json5-WUIP5FMS.js").then((r) => r.parseJSON5), ".json5"),
339086
+ ".toml": /* @__PURE__ */ __name(() => import("./toml-BAOM6BGG.js").then((r) => r.parseTOML), ".toml")
338648
339087
  };
338649
339088
  var SUPPORTED_EXTENSIONS = [
338650
339089
  // with jiti
@@ -338846,8 +339285,8 @@ async function resolveConfig(source, options, sourceOptions = {}) {
338846
339285
  }
338847
339286
  const _merger = options.merger || defu;
338848
339287
  if (options.giget !== false && GIGET_PREFIXES.some((prefix) => source.startsWith(prefix))) {
338849
- const { downloadTemplate } = await import("./dist-VPVBHEYK.js");
338850
- const { digest } = await import("./dist-25H3BHT5.js");
339288
+ const { downloadTemplate } = await import("./dist-VFELXY4D.js");
339289
+ const { digest } = await import("./dist-RWR2JNAL.js");
338851
339290
  const cloneName = source.replace(/\W+/g, "_").split("_").splice(0, 3).join("_") + "_" + digest(source).slice(0, 10).replace(/[-_]/g, "");
338852
339291
  let cloneDir;
338853
339292
  const localNodeModules = resolve(options.cwd, "node_modules");
@@ -338970,8 +339409,23 @@ init_esm_shims();
338970
339409
  init_esm_shims();
338971
339410
  var STORM_DEFAULT_DOCS = "https://docs.stormsoftware.com";
338972
339411
  var STORM_DEFAULT_HOMEPAGE = "https://stormsoftware.com";
339412
+ var STORM_DEFAULT_CONTACT = "https://stormsoftware.com/contact";
338973
339413
  var STORM_DEFAULT_LICENSING = "https://license.stormsoftware.com";
338974
339414
  var STORM_DEFAULT_LICENSE = "Apache-2.0";
339415
+ var STORM_DEFAULT_RELEASE_BANNER = "https://public.storm-cdn.com/brand-banner.png";
339416
+ var STORM_DEFAULT_ACCOUNT_TWITTER = "StormSoftwareHQ";
339417
+ var STORM_DEFAULT_ACCOUNT_DISCORD = "https://discord.gg/MQ6YVzakM5";
339418
+ var STORM_DEFAULT_ACCOUNT_TELEGRAM = "https://t.me/storm_software";
339419
+ var STORM_DEFAULT_ACCOUNT_SLACK = "https://join.slack.com/t/storm-software/shared_invite/zt-2gsmk04hs-i6yhK_r6urq0dkZYAwq2pA";
339420
+ var STORM_DEFAULT_ACCOUNT_MEDIUM = "https://medium.com/storm-software";
339421
+ var STORM_DEFAULT_ACCOUNT_GITHUB = "https://github.com/storm-software";
339422
+ var STORM_DEFAULT_RELEASE_FOOTER = `
339423
+ Storm Software is an open source software development organization with the mission is to make software development more accessible. Our ideal future is one where anyone can create software without years of prior development experience serving as a barrier to entry. We hope to achieve this via LLMs, Generative AI, and intuitive, high-level data modeling/programming languages.
339424
+
339425
+ Join us on [Discord](${STORM_DEFAULT_ACCOUNT_DISCORD}) to chat with the team, receive release notifications, ask questions, and get involved.
339426
+
339427
+ If this sounds interesting, and you would like to help us in creating the next generation of development tools, please reach out on our [website](${STORM_DEFAULT_CONTACT}) or join our [Slack](${STORM_DEFAULT_ACCOUNT_SLACK}) channel!
339428
+ `;
338975
339429
 
338976
339430
  // ../config/src/define-config.ts
338977
339431
  init_esm_shims();
@@ -343270,9 +343724,22 @@ var ColorConfigMapSchema = z.union([
343270
343724
  var ExtendsItemSchema = z.string().trim().describe("The path to a base config file to use as a configuration preset file. Documentation can be found at https://github.com/unjs/c12#extending-configuration.");
343271
343725
  var ExtendsSchema = ExtendsItemSchema.or(z.array(ExtendsItemSchema)).describe("The path to a base config file to use as a configuration preset file. Documentation can be found at https://github.com/unjs/c12#extending-configuration.");
343272
343726
  var WorkspaceBotConfigSchema = z.object({
343273
- name: z.string().trim().default("Stormie-Bot").describe("The workspace bot user's name (this is the bot that will be used to perform various tasks)"),
343727
+ name: z.string().trim().default("stormie-bot").describe("The workspace bot user's name (this is the bot that will be used to perform various tasks)"),
343274
343728
  email: z.string().trim().email().default("bot@stormsoftware.com").describe("The email of the workspace bot")
343275
343729
  }).describe("The workspace's bot user's config used to automated various operations tasks");
343730
+ var WorkspaceReleaseConfigSchema = z.object({
343731
+ banner: z.string().trim().default(STORM_DEFAULT_RELEASE_BANNER).describe("A URL to a banner image used to display the workspace's release"),
343732
+ header: z.string().trim().optional().describe("A header message appended to the start of the workspace's release notes"),
343733
+ footer: z.string().trim().default(STORM_DEFAULT_RELEASE_FOOTER).describe("A footer message appended to the end of the workspace's release notes")
343734
+ }).describe("The workspace's release config used during the release process");
343735
+ var WorkspaceAccountConfigSchema = z.object({
343736
+ twitter: z.string().trim().default(STORM_DEFAULT_ACCOUNT_TWITTER).describe("A Twitter/X account associated with the organization/project"),
343737
+ discord: z.string().trim().default(STORM_DEFAULT_ACCOUNT_DISCORD).describe("A Discord account associated with the organization/project"),
343738
+ telegram: z.string().trim().default(STORM_DEFAULT_ACCOUNT_TELEGRAM).describe("A Telegram account associated with the organization/project"),
343739
+ slack: z.string().trim().default(STORM_DEFAULT_ACCOUNT_SLACK).describe("A Slack account associated with the organization/project"),
343740
+ medium: z.string().trim().default(STORM_DEFAULT_ACCOUNT_MEDIUM).describe("A Medium account associated with the organization/project"),
343741
+ github: z.string().trim().default(STORM_DEFAULT_ACCOUNT_GITHUB).describe("A GitHub account associated with the organization/project")
343742
+ }).describe("The workspace's account config used to store various social media links");
343276
343743
  var WorkspaceDirectoryConfigSchema = z.object({
343277
343744
  cache: z.string().trim().optional().describe("The directory used to store the environment's cached file data"),
343278
343745
  data: z.string().trim().optional().describe("The directory used to store the environment's data files"),
@@ -343292,10 +343759,13 @@ var StormConfigSchema = z.object({
343292
343759
  homepage: z.string().trim().url().default(STORM_DEFAULT_HOMEPAGE).describe("The homepage of the workspace"),
343293
343760
  docs: z.string().trim().url().default(STORM_DEFAULT_DOCS).describe("The base documentation site for the workspace"),
343294
343761
  licensing: z.string().trim().url().default(STORM_DEFAULT_LICENSING).describe("The base licensing site for the workspace"),
343762
+ contact: z.string().trim().url().default(STORM_DEFAULT_CONTACT).describe("The base contact site for the workspace"),
343295
343763
  branch: z.string().trim().default("main").describe("The branch of the workspace"),
343296
343764
  preid: z.string().optional().describe("A tag specifying the version pre-release identifier"),
343297
343765
  owner: z.string().trim().default("@storm-software/admin").describe("The owner of the package"),
343298
343766
  bot: WorkspaceBotConfigSchema,
343767
+ release: WorkspaceReleaseConfigSchema,
343768
+ account: WorkspaceAccountConfigSchema,
343299
343769
  mode: z.enum([
343300
343770
  "development",
343301
343771
  "staging",
@@ -343771,7 +344241,7 @@ var getLogFn = /* @__PURE__ */ __name((logLevel = LogLevel.INFO, config = {}, _c
343771
344241
  if (typeof logLevel === "number" && LogLevel.FATAL >= logLevel) {
343772
344242
  return (message) => {
343773
344243
  console.error(`
343774
- ${_chalk.gray(formatTimestamp())} ${_chalk.hex(colors.fatal ?? "#7d1a1a")(`[${CONSOLE_ICONS[LogLevelLabel.FATAL]} Fatal] `)}${_chalk.bold.whiteBright(formatLogMessage(message))}
344244
+ ${_chalk.gray(formatTimestamp())} ${_chalk.hex(colors.fatal ?? "#7d1a1a")(`[${CONSOLE_ICONS[LogLevelLabel.FATAL]} Fatal] `)}${_chalk.bold.whiteBright(formatLogMessage(message))}
343775
344245
  `);
343776
344246
  };
343777
344247
  }
@@ -343960,12 +344430,26 @@ var getConfigEnv = /* @__PURE__ */ __name(() => {
343960
344430
  name: process.env[`${prefix}BOT_NAME`] || void 0,
343961
344431
  email: process.env[`${prefix}BOT_EMAIL`] || void 0
343962
344432
  },
344433
+ release: {
344434
+ banner: process.env[`${prefix}RELEASE_BANNER`] || void 0,
344435
+ header: process.env[`${prefix}RELEASE_HEADER`] || void 0,
344436
+ footer: process.env[`${prefix}RELEASE_FOOTER`] || void 0
344437
+ },
344438
+ account: {
344439
+ twitter: process.env[`${prefix}ACCOUNT_TWITTER`] || void 0,
344440
+ discord: process.env[`${prefix}ACCOUNT_DISCORD`] || void 0,
344441
+ telegram: process.env[`${prefix}ACCOUNT_TELEGRAM`] || void 0,
344442
+ slack: process.env[`${prefix}ACCOUNT_SLACK`] || void 0,
344443
+ medium: process.env[`${prefix}ACCOUNT_MEDIUM`] || void 0,
344444
+ github: process.env[`${prefix}ACCOUNT_GITHUB`] || void 0
344445
+ },
343963
344446
  organization: process.env[`${prefix}ORGANIZATION`] || void 0,
343964
344447
  packageManager: process.env[`${prefix}PACKAGE_MANAGER`] || void 0,
343965
344448
  license: process.env[`${prefix}LICENSE`] || void 0,
343966
344449
  homepage: process.env[`${prefix}HOMEPAGE`] || void 0,
343967
344450
  docs: process.env[`${prefix}DOCS`] || void 0,
343968
344451
  licensing: process.env[`${prefix}LICENSING`] || void 0,
344452
+ contact: process.env[`${prefix}CONTACT`] || void 0,
343969
344453
  timezone: process.env[`${prefix}TIMEZONE`] || process.env.TZ || void 0,
343970
344454
  locale: process.env[`${prefix}LOCALE`] || process.env.LOCALE || void 0,
343971
344455
  configFile: process.env[`${prefix}CONFIG_FILE`] ? correctPaths(process.env[`${prefix}CONFIG_FILE`]) : void 0,
@@ -344125,6 +344609,31 @@ var setConfigEnv = /* @__PURE__ */ __name((config) => {
344125
344609
  process.env[`${prefix}BOT_NAME`] = config.bot.name;
344126
344610
  process.env[`${prefix}BOT_EMAIL`] = config.bot.email;
344127
344611
  }
344612
+ if (config.release) {
344613
+ process.env[`${prefix}RELEASE_BANNER`] = config.release.banner;
344614
+ process.env[`${prefix}RELEASE_HEADER`] = config.release.header;
344615
+ process.env[`${prefix}RELEASE_FOOTER`] = config.release.footer;
344616
+ }
344617
+ if (config.account) {
344618
+ if (config.account.twitter) {
344619
+ process.env[`${prefix}ACCOUNT_TWITTER`] = config.account.twitter;
344620
+ }
344621
+ if (config.account.discord) {
344622
+ process.env[`${prefix}ACCOUNT_DISCORD`] = config.account.discord;
344623
+ }
344624
+ if (config.account.telegram) {
344625
+ process.env[`${prefix}ACCOUNT_TELEGRAM`] = config.account.telegram;
344626
+ }
344627
+ if (config.account.slack) {
344628
+ process.env[`${prefix}ACCOUNT_SLACK`] = config.account.slack;
344629
+ }
344630
+ if (config.account.medium) {
344631
+ process.env[`${prefix}ACCOUNT_MEDIUM`] = config.account.medium;
344632
+ }
344633
+ if (config.account.github) {
344634
+ process.env[`${prefix}ACCOUNT_GITHUB`] = config.account.github;
344635
+ }
344636
+ }
344128
344637
  if (config.organization) {
344129
344638
  process.env[`${prefix}ORGANIZATION`] = config.organization;
344130
344639
  }
@@ -344143,6 +344652,9 @@ var setConfigEnv = /* @__PURE__ */ __name((config) => {
344143
344652
  if (config.licensing) {
344144
344653
  process.env[`${prefix}LICENSING`] = config.licensing;
344145
344654
  }
344655
+ if (config.contact) {
344656
+ process.env[`${prefix}CONTACT`] = config.contact;
344657
+ }
344146
344658
  if (config.timezone) {
344147
344659
  process.env[`${prefix}TIMEZONE`] = config.timezone;
344148
344660
  process.env.TZ = config.timezone;
@@ -344241,7 +344753,9 @@ var setConfigEnv = /* @__PURE__ */ __name((config) => {
344241
344753
  }
344242
344754
  process.env[`${prefix}CONFIG`] = JSON.stringify(config);
344243
344755
  for (const key of Object.keys(config.extensions ?? {})) {
344244
- config.extensions[key] && Object.keys(config.extensions[key]) && setExtensionEnv(key, config.extensions[key]);
344756
+ if (config.extensions[key] && Object.keys(config.extensions[key])) {
344757
+ setExtensionEnv(key, config.extensions[key]);
344758
+ }
344245
344759
  }
344246
344760
  }, "setConfigEnv");
344247
344761
  var setThemeColorConfigEnv = /* @__PURE__ */ __name((prefix, config) => {
@@ -377114,7 +377628,7 @@ import * as path15 from "node:path";
377114
377628
  init_esm_shims();
377115
377629
  import * as path14 from "node:path";
377116
377630
 
377117
- // ../../node_modules/.pnpm/find-up-simple@1.0.0/node_modules/find-up-simple/index.js
377631
+ // ../../node_modules/.pnpm/find-up-simple@1.0.1/node_modules/find-up-simple/index.js
377118
377632
  init_esm_shims();
377119
377633
  import process7 from "node:process";
377120
377634
  import fsPromises from "node:fs/promises";
@@ -377125,8 +377639,9 @@ async function findUp2(name2, { cwd = process7.cwd(), type: type2 = "file", stop
377125
377639
  let directory = path13.resolve(toPath2(cwd) ?? "");
377126
377640
  const { root } = path13.parse(directory);
377127
377641
  stopAt = path13.resolve(directory, toPath2(stopAt ?? root));
377128
- while (directory && directory !== stopAt && directory !== root) {
377129
- const filePath2 = path13.isAbsolute(name2) ? name2 : path13.join(directory, name2);
377642
+ const isAbsoluteName = path13.isAbsolute(name2);
377643
+ while (directory) {
377644
+ const filePath2 = isAbsoluteName ? name2 : path13.join(directory, name2);
377130
377645
  try {
377131
377646
  const stats2 = await fsPromises.stat(filePath2);
377132
377647
  if (type2 === "file" && stats2.isFile() || type2 === "directory" && stats2.isDirectory()) {
@@ -377134,6 +377649,9 @@ async function findUp2(name2, { cwd = process7.cwd(), type: type2 = "file", stop
377134
377649
  }
377135
377650
  } catch {
377136
377651
  }
377652
+ if (directory === stopAt || directory === root) {
377653
+ break;
377654
+ }
377137
377655
  directory = path13.dirname(directory);
377138
377656
  }
377139
377657
  }
@@ -407793,7 +408311,7 @@ var Octokit = class Octokit2 {
407793
408311
  auth;
407794
408312
  };
407795
408313
 
407796
- // ../../node_modules/.pnpm/@octokit+plugin-paginate-rest@11.4.2_@octokit+core@6.1.4/node_modules/@octokit/plugin-paginate-rest/dist-bundle/index.js
408314
+ // ../../node_modules/.pnpm/@octokit+plugin-paginate-rest@11.4.3_@octokit+core@6.1.4/node_modules/@octokit/plugin-paginate-rest/dist-bundle/index.js
407797
408315
  init_esm_shims();
407798
408316
  var VERSION5 = "0.0.0-development";
407799
408317
  function normalizePaginatedListResponse(response) {
@@ -413509,7 +414027,7 @@ var OAuthApp = class {
413509
414027
  deleteAuthorization;
413510
414028
  };
413511
414029
 
413512
- // ../../node_modules/.pnpm/@octokit+webhooks@13.6.1/node_modules/@octokit/webhooks/dist-bundle/index.js
414030
+ // ../../node_modules/.pnpm/@octokit+webhooks@13.7.4/node_modules/@octokit/webhooks/dist-bundle/index.js
413513
414031
  init_esm_shims();
413514
414032
 
413515
414033
  // ../../node_modules/.pnpm/@octokit+webhooks-methods@5.1.1/node_modules/@octokit/webhooks-methods/dist-node/index.js
@@ -413563,7 +414081,7 @@ async function verifyWithFallback(secret, payload, signature, additionalSecrets)
413563
414081
  }
413564
414082
  __name(verifyWithFallback, "verifyWithFallback");
413565
414083
 
413566
- // ../../node_modules/.pnpm/@octokit+webhooks@13.6.1/node_modules/@octokit/webhooks/dist-bundle/index.js
414084
+ // ../../node_modules/.pnpm/@octokit+webhooks@13.7.4/node_modules/@octokit/webhooks/dist-bundle/index.js
413567
414085
  var createLogger = /* @__PURE__ */ __name((logger) => ({
413568
414086
  debug: /* @__PURE__ */ __name(() => {
413569
414087
  }, "debug"),
@@ -415409,7 +415927,7 @@ __name(upgradeDependency, "upgradeDependency");
415409
415927
  var npmRequestLimit = (0, import_p_limit2.default)(40);
415410
415928
  function getPackageInfo(pkgName) {
415411
415929
  return npmRequestLimit(async () => {
415412
- const getPackageJson = (await import("./package-json-BISGQCQA.js")).default;
415930
+ const getPackageJson = (await import("./package-json-V5Z5DK5X.js")).default;
415413
415931
  return getPackageJson(pkgName, {
415414
415932
  allVersions: true
415415
415933
  });