scip-query 0.22.0 → 0.24.0

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 (470) hide show
  1. package/CHANGELOG.md +500 -0
  2. package/README.md +13 -0
  3. package/dist/augment-vue-worker.js +1 -1
  4. package/dist/by-kind-H3P6BR5G.js +2 -0
  5. package/dist/call-graph-VTG2CUOQ.js +2 -0
  6. package/dist/call-graph-evidence-BociKRpF.d.ts +19 -0
  7. package/dist/chunk-2BMSSRBH.js +2 -0
  8. package/dist/{chunk-TAYD3AE7.js → chunk-2GJSD5GY.js} +2 -2
  9. package/dist/{chunk-TUQIPUDS.js → chunk-2M2LSIMY.js} +3 -3
  10. package/dist/{chunk-GIQ6CSL4.js → chunk-2N6WBNDC.js} +2 -2
  11. package/dist/{chunk-JHH5SCZ3.js → chunk-2OOY75BW.js} +2 -2
  12. package/dist/{chunk-EELPBR7E.js → chunk-2USA3S3P.js} +2 -2
  13. package/dist/chunk-2VAHDDLM.js +133 -0
  14. package/dist/chunk-2XWIUW5Z.js +455 -0
  15. package/dist/{chunk-57N6LN2A.js → chunk-3AF4TUFK.js} +2 -2
  16. package/dist/chunk-3D4BOXW6.js +20 -0
  17. package/dist/{chunk-FFJQZG6J.js → chunk-3LO4FST5.js} +2 -2
  18. package/dist/{chunk-HXOU4XNH.js → chunk-3WTY4LP2.js} +2 -2
  19. package/dist/{chunk-DPWKKNKI.js → chunk-3Z5AMSK6.js} +2 -2
  20. package/dist/{chunk-F24G5NBE.js → chunk-44IETFOU.js} +2 -2
  21. package/dist/chunk-4FR6GQIT.js +2 -0
  22. package/dist/chunk-4KBTHJLP.js +2 -0
  23. package/dist/chunk-5BIKR67W.js +2 -0
  24. package/dist/{chunk-DJAO2OZJ.js → chunk-5PROPLHI.js} +2 -2
  25. package/dist/chunk-5V7EPTII.js +2 -0
  26. package/dist/{chunk-VZ7NXSHV.js → chunk-62LPZCBQ.js} +2 -2
  27. package/dist/{chunk-LXQUF2RP.js → chunk-64O2JHQA.js} +2 -2
  28. package/dist/chunk-6D4F5VWG.js +10 -0
  29. package/dist/{chunk-NEIQPFBI.js → chunk-6ERFBC3X.js} +2 -2
  30. package/dist/{chunk-4HE7MVWD.js → chunk-6ILKOOGH.js} +2 -2
  31. package/dist/chunk-6MFXCMZC.js +2 -0
  32. package/dist/chunk-6O7FACKB.js +2 -0
  33. package/dist/{chunk-R6M456QG.js → chunk-6TS3KOXR.js} +2 -2
  34. package/dist/{chunk-7U2YQSDE.js → chunk-76QOU4PK.js} +2 -2
  35. package/dist/{chunk-25GWKRUZ.js → chunk-7DUI77BN.js} +2 -2
  36. package/dist/chunk-7F45LJKI.js +2 -0
  37. package/dist/{chunk-DEAB5TGT.js → chunk-7F7T6DCR.js} +2 -2
  38. package/dist/chunk-7H6VHWWJ.js +2 -0
  39. package/dist/chunk-7HXT6YLU.js +5 -0
  40. package/dist/{chunk-KZYID5KV.js → chunk-7R4V5ES6.js} +4 -4
  41. package/dist/chunk-7RIRIADH.js +7 -0
  42. package/dist/chunk-7ZLWLOGT.js +2 -0
  43. package/dist/{chunk-WHADK6OS.js → chunk-A4WEAK35.js} +2 -2
  44. package/dist/chunk-AADQLOQ4.js +38 -0
  45. package/dist/{chunk-XFMVKFSF.js → chunk-AN76MGUE.js} +2 -2
  46. package/dist/chunk-ANLNLY66.js +2 -0
  47. package/dist/chunk-ATXPTSEI.js +81 -0
  48. package/dist/{chunk-EELG7D3Q.js → chunk-AX7IDVFT.js} +2 -2
  49. package/dist/chunk-B3PYOSCX.js +2 -0
  50. package/dist/chunk-B7MPDEAK.js +3 -0
  51. package/dist/chunk-BBB5FBX4.js +2 -0
  52. package/dist/{chunk-Y2VM4CJC.js → chunk-BHKK5RJY.js} +2 -2
  53. package/dist/chunk-BJWFVAA5.js +2 -0
  54. package/dist/chunk-BKVWUP7Y.js +2 -0
  55. package/dist/{chunk-7XA3OM44.js → chunk-BKZYTLGE.js} +2 -2
  56. package/dist/chunk-BL6DCHQP.js +2 -0
  57. package/dist/chunk-BOW7SSQH.js +43 -0
  58. package/dist/{chunk-KQHJEU6V.js → chunk-C4RHHCKL.js} +2 -2
  59. package/dist/chunk-C7C6AKAT.js +117 -0
  60. package/dist/chunk-CD6M6LS2.js +16 -0
  61. package/dist/chunk-CFE6PSG6.js +2 -0
  62. package/dist/{chunk-GPGRZJ3R.js → chunk-CFNIGQMT.js} +2 -2
  63. package/dist/{chunk-K3XFWJI2.js → chunk-CKBUBRYD.js} +2 -2
  64. package/dist/chunk-CZW5MZ5B.js +2 -0
  65. package/dist/chunk-DBBZ63ZX.js +2 -0
  66. package/dist/chunk-DBN7DMJB.js +18 -0
  67. package/dist/{chunk-CKRWA452.js → chunk-DUULLZHZ.js} +2 -2
  68. package/dist/{chunk-6HRZQLOI.js → chunk-DV5Y5NOS.js} +2 -2
  69. package/dist/chunk-DZOIKCTM.js +3 -0
  70. package/dist/chunk-E4PKTOL3.js +2 -0
  71. package/dist/{chunk-GVOMSPGL.js → chunk-E65ELFKU.js} +2 -2
  72. package/dist/{chunk-VXJJTQYE.js → chunk-E7QR35ST.js} +2 -2
  73. package/dist/{chunk-2RE5OCHZ.js → chunk-EFSXAINW.js} +2 -2
  74. package/dist/{chunk-GY7CCCEZ.js → chunk-EHVEIEQN.js} +2 -2
  75. package/dist/{chunk-BVFYEEBH.js → chunk-EHYDXE3Z.js} +2 -2
  76. package/dist/{chunk-HISEUIL2.js → chunk-EP63Y6LD.js} +2 -2
  77. package/dist/chunk-EPX6NQN6.js +4 -0
  78. package/dist/chunk-ETC674NS.js +5 -0
  79. package/dist/{chunk-5H5WTJSD.js → chunk-F5GSBHC6.js} +2 -2
  80. package/dist/chunk-FH3DGXC6.js +2 -0
  81. package/dist/{chunk-2XCGSDIT.js → chunk-FI7VGOR4.js} +2 -2
  82. package/dist/chunk-FJF6VO2P.js +2 -0
  83. package/dist/{chunk-FELGD32K.js → chunk-FLMTCX5R.js} +2 -2
  84. package/dist/chunk-FVFDOIM3.js +2 -0
  85. package/dist/{chunk-AQ2PORIO.js → chunk-G2HU5WRN.js} +2 -2
  86. package/dist/{chunk-7YQOCABQ.js → chunk-G4ALYS4J.js} +2 -2
  87. package/dist/{chunk-SWK4XPUS.js → chunk-G56I7K4W.js} +2 -2
  88. package/dist/{chunk-JFQBRL3J.js → chunk-GC4DG2V5.js} +2 -2
  89. package/dist/chunk-GG45PK4S.js +4 -0
  90. package/dist/{chunk-XN22RGSR.js → chunk-GHNPACNP.js} +2 -2
  91. package/dist/{chunk-XU75YQN4.js → chunk-GINH3YQU.js} +2 -2
  92. package/dist/chunk-GTZZVLKJ.js +2 -0
  93. package/dist/chunk-GXXW5ZHH.js +2 -0
  94. package/dist/{chunk-RNKPYYYE.js → chunk-HAXXKRTD.js} +2 -2
  95. package/dist/chunk-HEZWBAZY.js +2 -0
  96. package/dist/chunk-HMEWLMML.js +2 -0
  97. package/dist/{chunk-2KVU55CW.js → chunk-HOBOVYPO.js} +2 -2
  98. package/dist/{chunk-2YC7YNKT.js → chunk-HRFQ6GW5.js} +2 -2
  99. package/dist/{chunk-RYOYJMGF.js → chunk-HX4X7KG3.js} +2 -2
  100. package/dist/{chunk-AZS7YPCB.js → chunk-HYT2R7LX.js} +2 -2
  101. package/dist/chunk-IKQVBVQL.js +40 -0
  102. package/dist/chunk-J6GLBBRK.js +4 -0
  103. package/dist/{chunk-TNG2FYS5.js → chunk-J7A4PWFX.js} +2 -2
  104. package/dist/chunk-JCSAZ35V.js +2 -0
  105. package/dist/{chunk-EWWY2ZFL.js → chunk-JDU2IV3A.js} +2 -2
  106. package/dist/{chunk-SB25YMEQ.js → chunk-JFMEXGFE.js} +2 -2
  107. package/dist/chunk-JFMI5SGB.js +4 -0
  108. package/dist/chunk-JJP37RGX.js +57 -0
  109. package/dist/chunk-JZ2A7LDM.js +5 -0
  110. package/dist/chunk-KNLQGXVH.js +80 -0
  111. package/dist/chunk-KVQCECPR.js +2 -0
  112. package/dist/{chunk-F24QUEQP.js → chunk-KXXORBZ2.js} +2 -2
  113. package/dist/{chunk-IKVNEGTW.js → chunk-L5KYH6U3.js} +2 -2
  114. package/dist/chunk-L6XHYJPZ.js +21 -0
  115. package/dist/chunk-L7KTFEAV.js +43 -0
  116. package/dist/{chunk-UAQ4T73O.js → chunk-LDXHR5EL.js} +2 -2
  117. package/dist/chunk-LEECKFCJ.js +2 -0
  118. package/dist/{chunk-LO5JSW2C.js → chunk-MHGDSBFX.js} +2 -2
  119. package/dist/{chunk-JUN5DOAK.js → chunk-MLQVVDG3.js} +2 -2
  120. package/dist/chunk-MOKUWRHO.js +3 -0
  121. package/dist/{chunk-44T4DUAA.js → chunk-MPYAPMNE.js} +2 -2
  122. package/dist/{chunk-ARVO6TTW.js → chunk-MV6SPXCR.js} +2 -2
  123. package/dist/{chunk-NRBNAECH.js → chunk-MWN53KRN.js} +2 -2
  124. package/dist/{chunk-TH6IC56G.js → chunk-MZPXPSUJ.js} +2 -2
  125. package/dist/{chunk-FBCVASUG.js → chunk-N55KIE46.js} +2 -2
  126. package/dist/{chunk-VMWUV6WB.js → chunk-NB4D3BNM.js} +2 -2
  127. package/dist/{chunk-JAT6C3VX.js → chunk-NGKBOT6G.js} +2 -2
  128. package/dist/{chunk-Q6T2CAJL.js → chunk-NJGKXKQF.js} +2 -2
  129. package/dist/chunk-NJQISBL4.js +8 -0
  130. package/dist/chunk-NJT3ZEKY.js +16 -0
  131. package/dist/{chunk-KFVSJX25.js → chunk-NKMKZP6A.js} +2 -2
  132. package/dist/chunk-NODFZ6ED.js +2 -0
  133. package/dist/{chunk-ERCYGVAM.js → chunk-NSM5IEVW.js} +2 -2
  134. package/dist/{chunk-YAGYMBEX.js → chunk-NTGUVNR2.js} +2 -2
  135. package/dist/{chunk-N7FP5H5U.js → chunk-NU3KFF2O.js} +8 -8
  136. package/dist/chunk-NWLVNU66.js +557 -0
  137. package/dist/{chunk-Q55NF3ZG.js → chunk-NYKZMCRC.js} +2 -2
  138. package/dist/{chunk-I6UTXNHU.js → chunk-O6BUXZEH.js} +2 -2
  139. package/dist/chunk-ODPDP7A4.js +3 -0
  140. package/dist/{chunk-ZAZGGSM3.js → chunk-OHIV323X.js} +2 -2
  141. package/dist/chunk-OIAPEKMT.js +3 -0
  142. package/dist/chunk-OIOC5EHF.js +3 -0
  143. package/dist/{chunk-YIHNPKWD.js → chunk-ONPPQM4G.js} +2 -2
  144. package/dist/{chunk-RHHCLWQ6.js → chunk-OUHEZBYI.js} +2 -2
  145. package/dist/{chunk-MSR2QRUE.js → chunk-OVGYW7UD.js} +2 -2
  146. package/dist/{chunk-OPSAW5DT.js → chunk-OYKU4B3Y.js} +2 -2
  147. package/dist/{chunk-5YRQIE2B.js → chunk-POBJ6FR2.js} +2 -2
  148. package/dist/{chunk-ZGW4HLPD.js → chunk-PSZPMMWN.js} +2 -2
  149. package/dist/chunk-PXTRBKRK.js +3 -0
  150. package/dist/{chunk-U2N2KE7A.js → chunk-Q5JRIHT3.js} +2 -2
  151. package/dist/{chunk-GRX7JOXQ.js → chunk-Q7ATHARX.js} +2 -2
  152. package/dist/{chunk-5ZMBRQFC.js → chunk-Q7CSKIDM.js} +2 -2
  153. package/dist/{chunk-HG722PO7.js → chunk-QBQE7ZJ5.js} +2 -2
  154. package/dist/{chunk-Z2PZVKPR.js → chunk-QH22UIXP.js} +2 -2
  155. package/dist/chunk-QXCKQTKR.js +60 -0
  156. package/dist/chunk-RBAD4GJ2.js +13 -0
  157. package/dist/chunk-RMDPFPNW.js +2 -0
  158. package/dist/chunk-ROPJDEJZ.js +4 -0
  159. package/dist/{chunk-56NQAEPJ.js → chunk-RVZC6TJE.js} +2 -2
  160. package/dist/{chunk-XJX6LGHL.js → chunk-S4QZBKSR.js} +2 -2
  161. package/dist/chunk-SCPMZ73U.js +2 -0
  162. package/dist/{chunk-7IQXARSQ.js → chunk-SIAP5RGI.js} +2 -2
  163. package/dist/{chunk-4TQU4TX2.js → chunk-SIX4RFR3.js} +2 -2
  164. package/dist/{chunk-AYPDH2LU.js → chunk-SKKXTABJ.js} +2 -2
  165. package/dist/{chunk-ZYM4HOFA.js → chunk-SSRFUQBD.js} +2 -2
  166. package/dist/chunk-SYVJEEUJ.js +3 -0
  167. package/dist/chunk-T3CZAZSI.js +8 -0
  168. package/dist/chunk-T3I6NHBH.js +2 -0
  169. package/dist/{chunk-GDRJB3SB.js → chunk-T6DWDI5E.js} +2 -2
  170. package/dist/chunk-T6HRIROJ.js +7 -0
  171. package/dist/{chunk-OTSPRVNW.js → chunk-TAA7HXHE.js} +2 -2
  172. package/dist/{chunk-IJMD6BRI.js → chunk-TJ2JQYT3.js} +2 -2
  173. package/dist/chunk-TULNMD5T.js +368 -0
  174. package/dist/chunk-U2FPY5XA.js +3 -0
  175. package/dist/chunk-U3SXIMII.js +38 -0
  176. package/dist/{chunk-ENWQWA2R.js → chunk-U6KCHXJ4.js} +2 -2
  177. package/dist/chunk-UH3XSKS5.js +9 -0
  178. package/dist/{chunk-UDY7MIAW.js → chunk-UIFUZVCC.js} +2 -2
  179. package/dist/{chunk-BDGTPN27.js → chunk-UXKURIVI.js} +2 -2
  180. package/dist/{chunk-FGNCOQUX.js → chunk-V2RBODHL.js} +2 -2
  181. package/dist/chunk-VBKUWB6N.js +2 -0
  182. package/dist/{chunk-PIFTZEEM.js → chunk-VBV6ALJE.js} +2 -2
  183. package/dist/{chunk-2OXVP5U5.js → chunk-VDGFWCQV.js} +2 -2
  184. package/dist/chunk-VDSDOEWF.js +2 -0
  185. package/dist/{chunk-C76O5MDS.js → chunk-VZPWVCLN.js} +2 -2
  186. package/dist/chunk-WDSFQDPN.js +2 -0
  187. package/dist/{chunk-BTVKZGWT.js → chunk-WFA35BGR.js} +2 -2
  188. package/dist/{chunk-H7CG6LOE.js → chunk-WLMP3OCW.js} +2 -2
  189. package/dist/{chunk-WOOAY3PA.js → chunk-WSA52GOR.js} +2 -2
  190. package/dist/chunk-WYPL7GF7.js +2 -0
  191. package/dist/{chunk-RDULNRSJ.js → chunk-X3YVZAKZ.js} +2 -2
  192. package/dist/chunk-X6OGVFIT.js +2 -0
  193. package/dist/{chunk-ISWFRGJ6.js → chunk-XKXTR6ZI.js} +2 -2
  194. package/dist/chunk-Y5DFAW5W.js +4 -0
  195. package/dist/chunk-YSYPDRD5.js +3 -0
  196. package/dist/chunk-ZFVPWH62.js +5 -0
  197. package/dist/chunk-ZGIHTH27.js +2 -0
  198. package/dist/{chunk-QKT4UI2Y.js → chunk-ZGIQN2SX.js} +2 -2
  199. package/dist/chunk-ZHG4WAHR.js +12 -0
  200. package/dist/{chunk-CLG6DWVS.js → chunk-ZKB2XUEN.js} +2 -2
  201. package/dist/chunk-ZLMXIQLC.js +21 -0
  202. package/dist/chunk-ZMCQIHI4.js +2 -0
  203. package/dist/cli-main.js +2 -2
  204. package/dist/code-TAVIKWJI.js +2 -0
  205. package/dist/code-result-json-5FEFQCAQ.js +2 -0
  206. package/dist/command-descriptors-7BKH53Y3.js +343 -0
  207. package/dist/dataflow-GFBTVDH3.js +2 -0
  208. package/dist/dependence-slice-GWGQCODG.js +2 -0
  209. package/dist/deps-4QHVDPYA.js +2 -0
  210. package/dist/direct-navigation-4UBC6HNW.js +3 -0
  211. package/dist/entry-map-QCTF4RVY.js +2 -0
  212. package/dist/files-M2UBF5HJ.js +2 -0
  213. package/dist/frontend-profile-roles-D7eCum8P.d.ts +10 -0
  214. package/dist/{health-CPp2Jf1Z.d.ts → health-BI2a9WPy.d.ts} +60 -2
  215. package/dist/hierarchy-2UIHRLW4.js +2 -0
  216. package/dist/imports-WIE3YZOB.js +2 -0
  217. package/dist/index.d.ts +1 -1
  218. package/dist/index.js +1 -1
  219. package/dist/members-YKD636DA.js +2 -0
  220. package/dist/methods-VDF4IMYG.js +2 -0
  221. package/dist/output-continuation-command-4UMDOOLO.js +3 -0
  222. package/dist/output-pagination-2GME6OPY.js +19 -0
  223. package/dist/postinstall.js +1 -1
  224. package/dist/project-reindex-XEQTRCV5.js +3 -0
  225. package/dist/queries/affected.js +1 -1
  226. package/dist/queries/anchors.d.ts +1 -1
  227. package/dist/queries/anchors.js +1 -1
  228. package/dist/queries/architecture.js +1 -1
  229. package/dist/queries/bottlenecks.js +1 -1
  230. package/dist/queries/by-kind.js +1 -1
  231. package/dist/queries/call-graph.d.ts +2 -0
  232. package/dist/queries/call-graph.js +1 -1
  233. package/dist/queries/change-surface.js +1 -1
  234. package/dist/queries/cleanup-plan.js +1 -1
  235. package/dist/queries/co-change.d.ts +20 -2
  236. package/dist/queries/co-change.js +1 -1
  237. package/dist/queries/code.js +1 -1
  238. package/dist/queries/complexity-hotspots.js +1 -1
  239. package/dist/queries/complexity.js +1 -1
  240. package/dist/queries/context.js +1 -1
  241. package/dist/queries/convergence.js +1 -1
  242. package/dist/queries/coupling.js +1 -1
  243. package/dist/queries/cycles.js +1 -1
  244. package/dist/queries/dataflow.js +1 -1
  245. package/dist/queries/dead.d.ts +2 -0
  246. package/dist/queries/dead.js +1 -1
  247. package/dist/queries/decorative-checkers.js +1 -1
  248. package/dist/queries/deep-chains.js +1 -1
  249. package/dist/queries/dependence-slice.js +1 -1
  250. package/dist/queries/dependency-depth.js +1 -1
  251. package/dist/queries/deps.js +1 -1
  252. package/dist/queries/diff-impact.d.ts +9 -0
  253. package/dist/queries/diff-impact.js +1 -1
  254. package/dist/queries/doc-drift.js +1 -1
  255. package/dist/queries/drift.js +1 -1
  256. package/dist/queries/duplicate-bodies.d.ts +28 -1
  257. package/dist/queries/duplicate-bodies.js +1 -1
  258. package/dist/queries/entry-map.d.ts +1 -1
  259. package/dist/queries/entry-map.js +1 -1
  260. package/dist/queries/evidence.js +1 -1
  261. package/dist/queries/extract-candidates.d.ts +50 -23
  262. package/dist/queries/extract-candidates.js +1 -1
  263. package/dist/queries/fan.js +1 -1
  264. package/dist/queries/files.js +1 -1
  265. package/dist/queries/health.d.ts +1 -1
  266. package/dist/queries/health.js +1 -1
  267. package/dist/queries/hierarchy.js +1 -1
  268. package/dist/queries/hotspots.js +1 -1
  269. package/dist/queries/imports.js +1 -1
  270. package/dist/queries/incomplete-migration.js +1 -1
  271. package/dist/queries/index.d.ts +4 -3
  272. package/dist/queries/index.js +1 -1
  273. package/dist/queries/isolated.js +1 -1
  274. package/dist/queries/locality-candidates.js +1 -1
  275. package/dist/queries/members.js +1 -1
  276. package/dist/queries/methods.js +1 -1
  277. package/dist/queries/not-implemented.js +1 -1
  278. package/dist/queries/outline.js +1 -1
  279. package/dist/queries/passthrough-candidates.d.ts +9 -1
  280. package/dist/queries/passthrough-candidates.js +1 -1
  281. package/dist/queries/plan-context.js +1 -1
  282. package/dist/queries/react-component-duplicates.d.ts +19 -3
  283. package/dist/queries/react-component-duplicates.js +1 -1
  284. package/dist/queries/react-hook-candidates.d.ts +22 -3
  285. package/dist/queries/react-hook-candidates.js +1 -1
  286. package/dist/queries/react-large-component-pressure.d.ts +17 -3
  287. package/dist/queries/react-large-component-pressure.js +1 -1
  288. package/dist/queries/recent-duplicates.js +1 -1
  289. package/dist/queries/redundant-reexports.js +1 -1
  290. package/dist/queries/reference-neighborhood.js +1 -1
  291. package/dist/queries/reference-reachability.js +1 -1
  292. package/dist/queries/refs.js +1 -1
  293. package/dist/queries/self-audit.d.ts +7 -1
  294. package/dist/queries/self-audit.js +1 -1
  295. package/dist/queries/similar-chains.js +1 -1
  296. package/dist/queries/similar-files.js +1 -1
  297. package/dist/queries/similar-signatures.js +1 -1
  298. package/dist/queries/similar.js +1 -1
  299. package/dist/queries/slice.js +1 -1
  300. package/dist/queries/source-inspection.js +1 -1
  301. package/dist/queries/source-search.js +1 -1
  302. package/dist/queries/stale-abstractions.js +1 -1
  303. package/dist/queries/surface.js +1 -1
  304. package/dist/queries/symbols.js +1 -1
  305. package/dist/queries/system-map.d.ts +1 -1
  306. package/dist/queries/system-map.js +1 -1
  307. package/dist/queries/system.js +1 -1
  308. package/dist/queries/test-quality.js +1 -1
  309. package/dist/queries/trace.js +1 -1
  310. package/dist/queries/twin-ab.js +1 -1
  311. package/dist/queries/twin-drift.d.ts +22 -6
  312. package/dist/queries/twin-drift.js +1 -1
  313. package/dist/queries/unused-imports.js +1 -1
  314. package/dist/queries/unused-params.js +1 -1
  315. package/dist/queries/value-flow.js +1 -1
  316. package/dist/queries/vue-component-duplicates.js +1 -1
  317. package/dist/queries/vue-composable-candidates.js +1 -1
  318. package/dist/queries/vue-large-view-pressure.js +1 -1
  319. package/dist/queries/wrapper-candidates.d.ts +16 -1
  320. package/dist/queries/wrapper-candidates.js +1 -1
  321. package/dist/query-service-fastpath.js +5 -5
  322. package/dist/query-service-server.js +3 -3
  323. package/dist/refs-JNK5CLM7.js +2 -0
  324. package/dist/refs-pagination-6BLRYGMV.js +2 -0
  325. package/dist/reindex-worker.js +25 -25
  326. package/dist/reindex.d.ts +3 -2
  327. package/dist/reindex.js +35 -35
  328. package/dist/runtime.d.ts +34 -2
  329. package/dist/runtime.js +4 -4
  330. package/dist/rust-semantic-session-server.js +1 -1
  331. package/dist/rust-semantic-session-worker.js +1 -1
  332. package/dist/rust-semantic-worker.js +1 -1
  333. package/dist/{scip-cli-H-n59izO.d.ts → scip-cli-DOerTq-R.d.ts} +42 -4
  334. package/dist/slice-PHPVNCWX.js +2 -0
  335. package/dist/surface-MQX5MPIV.js +2 -0
  336. package/dist/symbol-resolution-DBLVXLBC.js +2 -0
  337. package/dist/system-JOPKV4OG.js +2 -0
  338. package/dist/trace-I2P2YFH4.js +2 -0
  339. package/dist/typescript-mailbox-worker.js +1 -1
  340. package/dist/value-flow-JJVMF7NP.js +2 -0
  341. package/dist/watch-server.js +3 -3
  342. package/docs/COMMAND_REFERENCE.md +2 -2
  343. package/docs/DETECTOR_GUIDE.md +51 -12
  344. package/docs/accuracy-audit-checklist.md +36 -13
  345. package/docs/locality-analyzer-design.md +9 -9
  346. package/package.json +2 -2
  347. package/skills/conductor/SKILL.md +110 -0
  348. package/skills/conductor/agents/openai.yaml +4 -0
  349. package/skills/principal-maintainability-review/SKILL.md +273 -0
  350. package/skills/principal-maintainability-review/agents/openai.yaml +4 -0
  351. package/skills/scip-calibrate/SKILL.md +102 -0
  352. package/skills/scip-calibrate/agents/openai.yaml +4 -0
  353. package/skills/scip-claim-audit/SKILL.md +113 -0
  354. package/skills/scip-claim-audit/agents/openai.yaml +4 -0
  355. package/skills/scip-probe-reachability/SKILL.md +93 -0
  356. package/skills/scip-probe-reachability/agents/openai.yaml +4 -0
  357. package/skills/scip-root-cause/SKILL.md +160 -0
  358. package/skills/scip-root-cause/agents/openai.yaml +4 -0
  359. package/skills/scip-system-compression/SKILL.md +252 -0
  360. package/skills/scip-system-compression/agents/openai.yaml +4 -0
  361. package/skills/scip-system-compression/references/compression-atlas.md +116 -0
  362. package/skills/scip-system-compression/references/compression-patterns.md +87 -0
  363. package/skills/scip-twin-drift/SKILL.md +109 -0
  364. package/skills/scip-twin-drift/agents/openai.yaml +4 -0
  365. package/dist/by-kind-4IYG2SKW.js +0 -2
  366. package/dist/call-graph-WQNXMNNN.js +0 -2
  367. package/dist/call-graph-evidence-lZa2dwQA.d.ts +0 -11
  368. package/dist/chunk-2BTJALUS.js +0 -454
  369. package/dist/chunk-3QXC54FQ.js +0 -3
  370. package/dist/chunk-3TJY6M3B.js +0 -7
  371. package/dist/chunk-42W3LFUK.js +0 -13
  372. package/dist/chunk-4GAQ6FI4.js +0 -43
  373. package/dist/chunk-6NC3YSPY.js +0 -38
  374. package/dist/chunk-6VEFRPTD.js +0 -5
  375. package/dist/chunk-7C26EKLZ.js +0 -4
  376. package/dist/chunk-7JYHQAH2.js +0 -22
  377. package/dist/chunk-7KSO2OAP.js +0 -2
  378. package/dist/chunk-7XZGZBSQ.js +0 -2
  379. package/dist/chunk-A77SCPW2.js +0 -3
  380. package/dist/chunk-AK3PYTIK.js +0 -5
  381. package/dist/chunk-AMIMMNA4.js +0 -11
  382. package/dist/chunk-AUY5BL74.js +0 -2
  383. package/dist/chunk-BDHFVH2M.js +0 -18
  384. package/dist/chunk-BECZLYNU.js +0 -8
  385. package/dist/chunk-BUTEIZKP.js +0 -10
  386. package/dist/chunk-BWVQP3LB.js +0 -38
  387. package/dist/chunk-BYDAFMSR.js +0 -57
  388. package/dist/chunk-BZYSGZRK.js +0 -2
  389. package/dist/chunk-C7IJMOFP.js +0 -134
  390. package/dist/chunk-CBBHFNLX.js +0 -2
  391. package/dist/chunk-D2MVJSP4.js +0 -21
  392. package/dist/chunk-D35XIZGN.js +0 -2
  393. package/dist/chunk-DKM723YF.js +0 -79
  394. package/dist/chunk-DRENNWRG.js +0 -2
  395. package/dist/chunk-E44IVWIJ.js +0 -367
  396. package/dist/chunk-EDMB6SSO.js +0 -7
  397. package/dist/chunk-EETGXQY7.js +0 -3
  398. package/dist/chunk-FKGQOTKD.js +0 -2
  399. package/dist/chunk-GH5YSGZL.js +0 -5
  400. package/dist/chunk-GQIDEID3.js +0 -2
  401. package/dist/chunk-HCVJR2V4.js +0 -3
  402. package/dist/chunk-IMKZEXZG.js +0 -2
  403. package/dist/chunk-ISIQLPJ2.js +0 -61
  404. package/dist/chunk-IXESDH3J.js +0 -2
  405. package/dist/chunk-JJ62MTQH.js +0 -40
  406. package/dist/chunk-JT6XX7QY.js +0 -8
  407. package/dist/chunk-KFOYCQAJ.js +0 -9
  408. package/dist/chunk-LRI5OMPE.js +0 -2
  409. package/dist/chunk-MHIEP7EG.js +0 -4
  410. package/dist/chunk-NK3JMP22.js +0 -2
  411. package/dist/chunk-NVSZNESQ.js +0 -2
  412. package/dist/chunk-OJNK5ALA.js +0 -2
  413. package/dist/chunk-OXYAWIEA.js +0 -2
  414. package/dist/chunk-OZETODHH.js +0 -2
  415. package/dist/chunk-PBUH2P5S.js +0 -3
  416. package/dist/chunk-PLJUQFQN.js +0 -2
  417. package/dist/chunk-PLYUVM4F.js +0 -2
  418. package/dist/chunk-PXXYQK55.js +0 -2
  419. package/dist/chunk-Q5TA4OY4.js +0 -20
  420. package/dist/chunk-Q7GBK5T7.js +0 -81
  421. package/dist/chunk-QLBSG7U5.js +0 -3
  422. package/dist/chunk-QWKHW6VZ.js +0 -2
  423. package/dist/chunk-RPL3ARU7.js +0 -16
  424. package/dist/chunk-SVHTMVA4.js +0 -4
  425. package/dist/chunk-T6QD2ZQB.js +0 -43
  426. package/dist/chunk-TD7VKJ2Y.js +0 -117
  427. package/dist/chunk-TKDNDQA7.js +0 -3
  428. package/dist/chunk-TQZV7KV4.js +0 -2
  429. package/dist/chunk-TUSPIVZ3.js +0 -4
  430. package/dist/chunk-URSGGIZX.js +0 -2
  431. package/dist/chunk-UT7TADJX.js +0 -2
  432. package/dist/chunk-V4NG5OMS.js +0 -554
  433. package/dist/chunk-VTCIYFEK.js +0 -2
  434. package/dist/chunk-VU6LIWHT.js +0 -2
  435. package/dist/chunk-VUSKPCUB.js +0 -2
  436. package/dist/chunk-WN3TCGJ4.js +0 -2
  437. package/dist/chunk-WSLEJSFR.js +0 -2
  438. package/dist/chunk-WYZIHUPZ.js +0 -16
  439. package/dist/chunk-XE33FV5W.js +0 -2
  440. package/dist/chunk-XGGBK66W.js +0 -4
  441. package/dist/chunk-XSWYJCAK.js +0 -2
  442. package/dist/chunk-Y334QQU5.js +0 -3
  443. package/dist/chunk-Z2AWCTN6.js +0 -2
  444. package/dist/chunk-ZOXKSQQB.js +0 -2
  445. package/dist/chunk-ZPASRBLF.js +0 -2
  446. package/dist/chunk-ZZ3Z7D56.js +0 -2
  447. package/dist/code-EQJFDT6I.js +0 -2
  448. package/dist/code-result-json-7UWIWBOO.js +0 -2
  449. package/dist/command-descriptors-ORNTVNYV.js +0 -342
  450. package/dist/dataflow-6VL54GX5.js +0 -2
  451. package/dist/dependence-slice-DT2NUHD2.js +0 -2
  452. package/dist/deps-DB7H5IKC.js +0 -2
  453. package/dist/direct-navigation-O3LUAYWQ.js +0 -3
  454. package/dist/entry-map-6K62RV3D.js +0 -2
  455. package/dist/files-MSLD7MO6.js +0 -2
  456. package/dist/hierarchy-IVBXAKFA.js +0 -2
  457. package/dist/imports-FRAVZ3Y2.js +0 -2
  458. package/dist/members-KJOJDYGO.js +0 -2
  459. package/dist/methods-2AYABBT3.js +0 -2
  460. package/dist/output-continuation-command-JHMPH6NC.js +0 -3
  461. package/dist/output-pagination-3OFL2MJV.js +0 -19
  462. package/dist/project-reindex-HYO4WD7Z.js +0 -3
  463. package/dist/refs-ARMA6XUJ.js +0 -2
  464. package/dist/refs-pagination-VUGIWN6U.js +0 -2
  465. package/dist/slice-YOB5YFAM.js +0 -2
  466. package/dist/surface-VY5EFWTW.js +0 -2
  467. package/dist/symbol-resolution-DGQN4XIV.js +0 -2
  468. package/dist/system-2KQ3QD2P.js +0 -2
  469. package/dist/trace-HTIPTXAE.js +0 -2
  470. package/dist/value-flow-5FV3VQI7.js +0 -2
@@ -1,134 +0,0 @@
1
- import{a as Ie}from"./chunk-YXPUP5G2.js";import{b as q,c as sn,d as on,e as we,g as ut}from"./chunk-DRENNWRG.js";import{b as Yt,c as z,d as Ne,f as Zt,g as en,h as tn,i as nn,j as rn,p as fe}from"./chunk-DKM723YF.js";import{a as Xt,c as N,d as pe,e as Gt,f as de}from"./chunk-IW5XQG5G.js";import{a as at,b as ct,e as lt}from"./chunk-HGFDYOVB.js";import{C as b,h as De,ma as Re,na as ve}from"./chunk-AK3PYTIK.js";var Ae=null;function _e(e){Ae?.(e)}function ec(e,t){let n=Ae;Ae=e;try{return t()}finally{Ae=n}}var vr=N("source-text",{clearGroups:["whole-project","source-file"]}),wr=N("source-lines",{clearGroups:["whole-project","source-file"]});function I(e,t){let n=t.replace(/\\/g,"/");return _e(n),vr.get(e,n,()=>Ar(e,n))}function Ar(e,t){let n=t.replace(/\\/g,"/");_e(n);try{return Re(e.config.projectRoot,n,{inputKind:"indexed source file"})}catch(r){if(ve(r))return"";throw r}}function ic(e){if(e.length===0)return[];let t=e.split(`
2
- `);return e.endsWith(`
3
- `)&&t.pop(),t}function pt(e,t){let n=t.replace(/\\/g,"/");return wr.get(e,n,()=>{let r=I(e,n);return r?r.split(`
4
- `):[]})}var jr=/^\s*(?:\/\/|#|\/\*+|\*)\s*scip-query[\s:-]*ignore(?:[\s:-]+(dead(?:-code)?|stale|wrapper|passthrough|drift|extract|similar|twin))?\b/i;function Or(e){let t=jr.exec(e);return t?t[1]??"":null}function oc(e,t,n){return Mr(e,t,n).length>0}function Mr(e,t,n){if(n<=0)return[];let r=pt(e,t);if(r.length===0)return[];let s=[];for(let i=n-1;i>=0&&i>=n-5;i-=1){let o=(r[i]??"").trim();if(o==="")continue;let a=Or(o);if(a!==null){s.push(a);continue}if(!o.startsWith("//")&&!o.startsWith("*")&&!o.startsWith("/*")&&!o.startsWith("@")&&!o.startsWith("#"))return s}return s}import{extname as an}from"path";var $r={".rs":"rust",".ts":"typescript",".mts":"typescript",".cts":"typescript",".tsx":"tsx",".js":"javascript",".jsx":"javascript",".mjs":"javascript",".cjs":"javascript",".py":"python",".pyi":"python",".java":"java",".kt":"kotlin",".kts":"kotlin",".scala":"scala",".sc":"scala",".rb":"ruby",".c":"c",".h":"c",".cc":"cpp",".cpp":"cpp",".cxx":"cpp",".hpp":"cpp",".hh":"cpp",".hxx":"cpp",".cs":"csharp",".php":"php",".vb":"vb",".clj":"clojure",".cljs":"clojure",".cljc":"clojure"};function O(e){return $r[an(e).toLowerCase()]??null}function M(e){return an(e).toLowerCase()===".vue"}var Br=[h("source-facts",{dependsOn:["content-hash","tool-version"],keyParts:["kind","relativePath","contentHash","payloadVersion"],stalenessTest:"tests/storage/evidence-cache.test.ts",owner:"src/source/source-facts.ts"}),h("file-definitions",{dependsOn:["content-hash","project-fingerprint","indexed-language-set","tool-version"],keyParts:["kind","relativePath","contentHash","projectFingerprint","payloadVersion"],stalenessTest:"tests/storage/evidence-cache.test.ts",owner:"src/symbols/definition-catalog.ts"}),h("definition-exclusions",{dependsOn:["content-hash","tool-version"],keyParts:["kind","relativePath","contentHash","payloadVersion"],stalenessTest:"tests/storage/evidence-cache.test.ts",owner:"src/analysis/framework-patterns.ts"}),h("doc-path-tokens",{dependsOn:["content-hash","tool-version"],keyParts:["kind","relativePath","contentHash","payloadVersion"],stalenessTest:"tests/storage/evidence-products.test.ts",owner:"tests/storage/evidence-cache.test.ts"}),h("doc-path-evidence",{dependsOn:["content-hash","git-history","git-head","tool-version"],keyParts:["kind","relativePath","contentHash","trackedFiles","historyWindow","payloadVersion"],stalenessTest:"tests/storage/evidence-cache.test.ts",owner:"src/queries/cleanup/doc-drift.ts"}),h("source-imports",{dependsOn:["content-hash","import-resolution-fingerprint","config","tool-version"],keyParts:["kind","relativePath","contentHash","importResolutionFingerprint","payloadVersion"],stalenessTest:"tests/storage/evidence-cache.test.ts",owner:"src/language-parsers/index.ts"}),h("source-reexports",{dependsOn:["content-hash","import-resolution-fingerprint","config","tool-version"],keyParts:["kind","relativePath","contentHash","importResolutionFingerprint","payloadVersion"],stalenessTest:"tests/storage/evidence-cache.test.ts",owner:"src/language-parsers/index.ts"}),h("source-fingerprints",{dependsOn:["content-hash","project-fingerprint","indexed-language-set","tool-version"],keyParts:["kind","relativePath","contentHash","projectFingerprint","payloadVersion"],stalenessTest:"tests/symbols/definition-catalog.test.ts",owner:"src/queries/cleanup/similar.ts"}),h("consumer-file-usage",{dependsOn:["content-hash","project-fingerprint","indexed-language-set","tool-version"],keyParts:["kind","relativePath","contentHash","projectFingerprint","payloadVersion"],stalenessTest:"tests/storage/evidence-cache.test.ts",owner:"src/queries/internal/consumer-evidence.ts"}),h("react-component-behavior-profiles",{dependsOn:["content-hash","tool-version"],keyParts:["kind","relativePath","contentHash","payloadVersion"],stalenessTest:"tests/storage/evidence-cache.test.ts",owner:"src/source/react-profile.ts"}),h("git-file-adds",{dependsOn:["git-head","git-history","tool-version"],keyParts:["kind","cacheKey","head","historyWindow","payloadVersion"],stalenessTest:"tests/storage/evidence-cache.test.ts",owner:"src/analysis/git-history.ts"}),h("typescript-reference-fragments",{dependsOn:["content-hash","transitive-deps-digest","config","tool-version"],keyParts:["kind","relativePath","semanticIdentity","payloadVersion"],stalenessTest:"tests/semantic/typescript/typescript-reference-fragments.test.ts",owner:"src/semantic/typescript/reference-fragment-shadow.ts"}),h("typescript-import-usage",{dependsOn:["content-hash","transitive-deps-digest","config","tool-version"],keyParts:["kind","relativePath","semanticIdentity","payloadVersion"],stalenessTest:"tests/semantic/typescript/typescript-semantic-provider.test.ts",owner:"src/semantic/shared-primitives.ts"}),h("typescript-signatures",{dependsOn:["content-hash","transitive-deps-digest","config","tool-version"],keyParts:["kind","relativePath","semanticIdentity","payloadVersion"],stalenessTest:"tests/semantic/typescript/typescript-semantic-provider.test.ts",owner:"src/semantic/shared-primitives.ts"}),h("runtime-boundary-http-roles",{dependsOn:["content-hash","tool-version"],keyParts:["kind","relativePath","contentHash","payloadVersion"],stalenessTest:"tests/analysis/runtime-boundaries.test.ts",owner:"src/analysis/runtime-boundaries/http-summaries.ts"}),h("runtime-boundary-source-hashes",{dependsOn:["content-hash","tool-version"],keyParts:["kind","relativePath","contentHash","payloadVersion"],stalenessTest:"tests/analysis/runtime-boundaries.test.ts",owner:"src/analysis/runtime-boundaries/graph.ts"}),h("runtime-boundary-direct-extraction",{dependsOn:["content-hash","direct-deps-digest","tool-version"],keyParts:["kind","relativePath","contentHash","payloadVersion"],stalenessTest:"tests/analysis/runtime-boundaries.test.ts",owner:"src/analysis/runtime-boundaries/graph.ts"}),je("file-dependency-graph",{dependsOn:["project-fingerprint","indexed-language-set","import-resolution-fingerprint","tool-version"],keyParts:["kind","scope","projectFingerprint","payloadVersion"],stalenessTest:"tests/symbols/file-dep-graph.test.ts",owner:"src/symbols/graph/file-dep-graph.ts"}),je("semantic-import-usage",{dependsOn:["project-fingerprint","indexed-language-set","import-resolution-fingerprint","tool-version"],keyParts:["kind","relativePath","projectFingerprint","language","semanticEngine","payloadVersion"],stalenessTest:"tests/semantic/rust/rust-semantic-cache-gate.test.ts",owner:"src/semantic/shared-primitives.ts"}),je("semantic-signatures",{dependsOn:["project-fingerprint","indexed-language-set","tool-version"],keyParts:["kind","relativePath","symbol","projectFingerprint","language","semanticEngine","payloadVersion"],stalenessTest:"tests/semantic/rust/rust-semantic-cache-gate.test.ts",owner:"src/semantic/shared-primitives.ts"}),je("health-semantic-prewarm",{dependsOn:["project-fingerprint","indexed-language-set","tool-version"],keyParts:["kind","scope","cliVersion","projectFingerprint","payloadVersion"],stalenessTest:"tests/runtime/cli-support.test.ts",owner:"src/runtime/cli-support.ts"})];function Y(e){let t=new Map;return{kind:e.kind,read(n,r,s){let i=!1,o=0,a;if(at()){let c=Ne(n);if(c){let l=`${c}\0${r}\0${s}`;a=t.get(l),a||(a=ct(["evidence-product-file-read-v1",e.kind,c,r,s]),t.set(l,a))}}return lt("evidence-product.file.read",()=>{let c=Zt(n,e.kind,r,s);if(c===null)return null;o=c.length;try{let l=e.deserialize(c);return i=l!==null,l}catch{return null}},()=>({...a?{workIdentity:a,workOutcome:"computed"}:{},scope:"file",kind:e.kind,available:!0,hit:i,payloadBytes:o}))},write(n,r,s,i){en(n,e.kind,r,s,e.serialize(i))},writeBatch(n,r){tn(n,r.map(s=>({kind:e.kind,relativePath:s.relativePath,contentHash:s.contentHash,payload:e.serialize(s.value)})))}}}function mc(e){let t=new Map;return{kind:e.kind,read(n,r,s){let i=!1,o=0,a;if(at()){let c=`${s}\0${r}`;a=t.get(c),a||(a=ct(["evidence-product-project-read-v1",e.kind,s,r]),t.set(c,a))}return lt("evidence-product.project.read",()=>{let c=nn(n,e.kind,r,s);if(c===null)return null;o=c.length;try{let l=e.deserialize(c);return i=l!==null,l}catch{return null}},()=>({...a?{workIdentity:a,workOutcome:"computed"}:{},scope:"project",kind:e.kind,available:!0,hit:i,payloadBytes:o}))},write(n,r,s,i){rn(n,e.kind,r,s,e.serialize(i))}}}function Z(e){let t=Br.find(n=>n.kind===e);if(!t)throw new Error(`missing evidence product manifest entry for ${e}`);return t.invalidation}function h(e,t){return{scope:"file",kind:e,invalidation:{scope:"file",...t}}}function je(e,t){return{scope:"project",kind:e,invalidation:{scope:"project",...t}}}import{createRequire as zr}from"module";import{setFlagsFromString as cn}from"v8";import{runInNewContext as Vr}from"vm";var ee;function Wr(){if(ee!==void 0)return ee;let e=globalThis.gc;if(typeof e=="function")return ee=e,ee;try{cn("--expose_gc");let t=Vr("gc");cn("--no-expose_gc"),ee=typeof t=="function"?t:null}catch{ee=null}return ee}function Ur(){let e=Wr();return e?(e(),!0):!1}var Hr=512*1024*1024,dt=0;function ln(e,t=Ur){!Number.isFinite(e)||e<=0||(dt+=e,!(dt<Hr)&&(dt=0,t()))}var _=zr(import.meta.url),Oe=null,un=!1;function qr(){if(un)return null;if(Oe)return Oe;try{return Oe=_("tree-sitter"),Oe}catch{return un=!0,null}}var pn=new Map,Me=new Set;function Qr(e){if(Me.has(e))return null;let t=pn.get(e);if(t)return t;let n;try{switch(e){case"rust":n=_("tree-sitter-rust");break;case"typescript":n=_("tree-sitter-typescript").typescript;break;case"tsx":n=_("tree-sitter-typescript").tsx;break;case"javascript":n=_("tree-sitter-javascript");break;case"python":n=_("tree-sitter-python");break;case"java":n=_("tree-sitter-java");break;case"kotlin":n=_("tree-sitter-kotlin");break;case"scala":n=_("tree-sitter-scala");break;case"ruby":n=_("tree-sitter-ruby");break;case"c":n=_("tree-sitter-c");break;case"cpp":n=_("tree-sitter-cpp");break;case"csharp":n=_("tree-sitter-c-sharp");break;case"php":n=_("tree-sitter-php").php;break;case"vb":{let r=_("tree-sitter-vb-dotnet");n=r.language??r;break}case"clojure":return Me.add(e),null}}catch{return Me.add(e),null}return pn.set(e,n),n}var dn=new Map;function Jr(e){let t=dn.get(e);if(t)return t;let n=Qr(e);if(!n)return null;let r=qr();if(!r)return null;let s=new r;try{s.setLanguage(n)}catch{return Me.add(e),null}return dn.set(e,s),s}function Kr(e,t){return e.parse(r=>r>=t.length?null:t.slice(r,Math.min(t.length,r+16384)))}function te(e,t){let n=Jr(e);if(!n)return null;try{let r=Kr(n,t);return ln(t.length*10),r}catch{return null}}import{createRequire as Xr}from"module";import{posix as ft}from"path";var kc=Gt("vue-sfc-units"),Gr=Xr(import.meta.url),Yr;function Zr(){return Yr??=Gr("@vue/compiler-sfc")}function es(...e){return Zr().parse(...e)}function ts(e){return e.replace(/\\/g,"/").replace(/^\.\//,"")}function ns(e){let t=e?.toLowerCase();return!t||t==="js"||t==="javascript"||t==="jsx"?"javascript":t==="ts"||t==="typescript"?"typescript":t==="tsx"?"tsx":null}function gn(e,t,n){let r={relativePath:t,template:null,scripts:[],styles:[],customBlocks:[],errors:[]};if(!n)return r;let s;try{s=es(n,{filename:t})}catch(o){return r.errors.push(mn(o)),r}r.errors.push(...s.errors.map(mn));let{descriptor:i}=s;return i.template&&(r.template=$e(e,t,"template",i.template)),i.script&&r.scripts.push(fn(e,t,i.script,!1)),i.scriptSetup&&r.scripts.push(fn(e,t,i.scriptSetup,!0)),r.styles=i.styles.map(o=>$e(e,t,"style",o)),r.customBlocks=i.customBlocks.map(o=>$e(e,t,"custom",o)),r.errors.push(...[r.template,...r.scripts,...r.styles,...r.customBlocks].flatMap(o=>o?.errors??[])),r}function fn(e,t,n,r){let s=$e(e,t,"script",n);return{...s,kind:"script",setup:r,astLanguage:ns(s.lang)}}function $e(e,t,n,r){let s=ss(r.attrs),i=typeof s.lang=="string"?s.lang:null,o=typeof s.src=="string"?s.src:typeof r.src=="string"?r.src:void 0;if(o){let c=rs(t,o);if(!c)return{kind:n,ownerPath:t,sourcePath:t,external:!0,src:o,attrs:s,lang:i,body:"",startLine:0,endLine:0,errors:[`Could not resolve Vue ${n} block source: ${o}`]};let l=I(e,c),u=l?Math.max(0,l.split(`
5
- `).length-1):0;return{kind:n,ownerPath:t,sourcePath:c,external:!0,src:o,attrs:s,lang:i,body:l,startLine:0,endLine:u,errors:l?[]:[`Vue ${n} block source not found: ${c}`]}}let a=Math.max(0,r.loc.start.line-1);return{kind:n,ownerPath:t,sourcePath:t,external:!1,attrs:s,lang:i,body:r.content,startLine:a,endLine:Math.max(a,r.loc.end.line-1),errors:[]}}function rs(e,t){let n=t.split(/[?#]/,1)[0];if(!n||n.startsWith("/")||n.includes("://"))return null;let r=ts(ft.normalize(ft.join(ft.dirname(e),n)));return r===".."||r.startsWith("../")?null:r}function ss(e){return{...e}}function mn(e){return e instanceof Error?e.message:String(e)}function me(e,t,n){let s=gn(e,t,n).scripts.filter(o=>o.astLanguage&&o.body.length>0),i=s[0]?.astLanguage;return i?{body:s.map(o=>`${`
6
- `.repeat(o.startLine)}${o.body}`).join(`
7
- `),startLine:0,language:i}:null}var Be=de("ast-trees",{clearGroups:["whole-project","source-file"]});function $(e,t){if(M(t))return is(e,t);let n=O(t);if(!n)return null;let r=I(e,t);return r?Be.get(e,t,r,()=>te(n,r)):null}function Ac(e,t,n){if(M(t))return Be.get(e,t,n,()=>{let s=me(e,t,n);return s?te(s.language,`
8
- `.repeat(s.startLine)+s.body):null});let r=O(t);return r?Be.get(e,t,n,()=>te(r,n)):null}function Ce(e,t,n){if(M(t)){let i=me(e,t,n);if(!i)return null;let o=te(i.language,`
9
- `.repeat(i.startLine)+i.body);return o?{tree:o,language:i.language}:null}let r=O(t);if(!r)return null;let s=te(r,n);return s?{tree:s,language:r}:null}function is(e,t){let n=I(e,t);return n?Be.get(e,t,n,()=>{let r=me(e,t,n);if(!r)return null;let s=`
10
- `.repeat(r.startLine)+r.body;return te(r.language,s)}):null}function Ee(e){return e.type==="comment"||e.type==="line_comment"||e.type==="block_comment"}var In=["function_declaration","generator_function_declaration","method_definition","method_signature","function_signature"],os=new Set(In),as=[...In,"variable_declarator","public_field_definition"],cs=["function_item","function_signature_item"],ls=["function_definition"],us=[],yn=new Set(["arrow_function","function_expression","generator_function"]);function _n(e){return e==="rust"?cs:e==="python"?ls:e==="typescript"||e==="tsx"||e==="javascript"?as:us}function Ve(e,t){let n=ds(e,t);if(n)return{name:n.name,startLine:n.definitionNode.startPosition.row,endLine:n.definitionNode.endPosition.row,paramCount:bn(n.functionNode),params:hn(n.functionNode),paramsEndLine:Sn(n.functionNode),isLiteralPassthrough:Nn(n.functionNode,t)};if(!ps(e.type,t))return null;let r=e.childForFieldName("name")??e.namedChildren.find(s=>s.type==="identifier"||s.type==="property_identifier");return r?{name:r.text,startLine:e.startPosition.row,endLine:e.endPosition.row,paramCount:bn(e),params:hn(e),paramsEndLine:Sn(e),isLiteralPassthrough:Nn(e,t)}:null}function Cn(e){return e.namedChildren.find(t=>t.type==="parameters"||t.type==="formal_parameters")}function hn(e){let t=Cn(e);if(!t)return[];let n=[];for(let r of t.namedChildren){if(Ee(r))continue;if(r.type==="identifier"){n.push({name:r.text,simple:!0});continue}let s=r.namedChildren.some(a=>a.type.endsWith("_modifier"))||/^\s*(?:public|private|protected|readonly|override)\b/.test(r.text),i=r.childForFieldName("pattern");if(!s&&i&&i.type==="identifier"){n.push({name:i.text,simple:!0});continue}let o=r.namedChildren.find(a=>a.type==="identifier");n.push({name:i?.type==="identifier"?i.text:o?.text??"",simple:!1})}return n}function Sn(e){let t=Cn(e);return t?t.endPosition.row:e.startPosition.row}function ps(e,t){return t==="rust"?e==="function_item"||e==="function_signature_item":t==="python"?e==="function_definition":t==="typescript"||t==="tsx"||t==="javascript"?os.has(e):!1}function ds(e,t){if(t!=="typescript"&&t!=="tsx"&&t!=="javascript")return null;if(e.type==="variable_declarator"){let n=e.childForFieldName("name")??e.namedChild(0),r=e.childForFieldName("value")??e.namedChild(1);if(!n||!r)return null;let s=xn(r);return s?{name:n.text,definitionNode:e,functionNode:s}:null}if(e.type==="public_field_definition"){let n=e.childForFieldName("name")??e.namedChild(0),r=e.childForFieldName("value")??e.namedChild(1);if(!n||!r)return null;let s=xn(r);return s?{name:n.text,definitionNode:e,functionNode:s}:null}return null}function xn(e){if(yn.has(e.type))return e;if(e.type!=="call_expression"||(e.childForFieldName("function")??e.namedChild(0))?.type!=="call_expression")return null;let r=((e.childForFieldName("arguments")??e.namedChildren.find(s=>s.type==="arguments"))?.namedChildren??[]).filter(s=>yn.has(s.type));return r.length===1?r[0]:null}function bn(e){let t=e.namedChildren.find(r=>r.type==="parameters"||r.type==="formal_parameters");if(!t)return 0;let n=0;for(let r of t.namedChildren)Ee(r)||(n+=1);return n}function Nn(e,t){let n=e.namedChildren.find(p=>p.type==="block"||p.type==="statement_block");if(!n)return!1;let r=n.namedChildren.filter(p=>!Ee(p));if(r.length!==1)return!1;let s=r[0],i=null;if(s.type==="return_statement"||s.type==="expression_statement"?i=s.namedChild(0)??null:t==="rust"&&(s.type==="call_expression"||s.type==="macro_invocation")&&(i=s),!i)return!1;let o=t==="python"?"call":"call_expression";if(i.type!==o)return!1;let a=i.namedChildren.find(p=>p.type==="arguments"||p.type==="argument_list");if(!a)return!1;let c=a.namedChildren.filter(p=>!Ee(p)),l=e.namedChildren.find(p=>p.type==="parameters"||p.type==="formal_parameters");if(!l)return!1;let u=[];for(let p of l.namedChildren){if(p.type==="identifier"){u.push(p.text);continue}let d=p.namedChildren.find(f=>f.type==="identifier");d&&u.push(d.text)}if(c.length!==u.length)return!1;for(let p=0;p<u.length;p+=1){let d=c[p];if(d.type!=="identifier"||d.text!==u[p])return!1}return!0}function $c(e,t){return e.filter(n=>n.startLine<=t&&n.endLine>=t).sort((n,r)=>n.endLine-n.startLine-(r.endLine-r.startLine)||n.startLine-r.startLine)[0]??null}function En(e,t){let n=ms(e,t);if(!n)return null;let r=ne(n);if(!r)return null;let s=gs(n);return{calleeLeaf:r,calleeQualifier:s?fs(n):void 0,calleeText:n.text,memberAccess:s,line:e.startPosition.row}}function fs(e){return(e.childForFieldName("object")??e.childForFieldName("value")??e.namedChild(0)??void 0)?.text||void 0}function ms(e,t){if(t==="rust")return e.type==="call_expression"?e.childForFieldName("function")??e.namedChild(0):e.type==="macro_invocation"?e.childForFieldName("macro")??e.namedChild(0):null;if(t==="python")return e.type!=="call"?null:e.childForFieldName("function")??e.namedChild(0);if(t==="typescript"||t==="tsx"||t==="javascript"){if(e.type==="call_expression")return e.childForFieldName("function")??e.namedChild(0);if(e.type==="new_expression")return e.childForFieldName("constructor")??e.namedChild(0)}return null}function gs(e){switch(e.type){case"field_expression":case"member_expression":case"attribute":return!0;default:return!1}}function ne(e){switch(e.type){case"identifier":case"type_identifier":case"field_identifier":case"property_identifier":case"private_property_identifier":case"shorthand_property_identifier":return e.text.replace(/^#/u,"");case"field_expression":case"member_expression":case"attribute":{let t=e.namedChild(e.namedChildCount-1);return t?ne(t):null}case"generic_function":{let t=e.childForFieldName("function")??e.namedChild(0);return t?ne(t):null}case"scoped_identifier":{let t=e.childForFieldName("name")??e.namedChild(e.namedChildCount-1);return t?ne(t):null}case"super":case"self":case"this":return null;default:return null}}var ys=new Set(["identifier","type_identifier","field_identifier"]),hs=new Set(["identifier"]),Ss=new Set(["identifier","property_identifier","type_identifier","shorthand_property_identifier","shorthand_property_identifier_pattern"]),xs=new Set(["rust","python"]),bs=/\{([^{}]*)\}/g,Ns=/\b([A-Za-z_][\w]*)\b/g;function kn(e,t){return Is(t).has(e.type)}function Pn(e,t){return xs.has(t)&&e.type==="string_content"}function mt(e){let t=0;for(let r of e.values()){let s=r[r.length-1];s!==void 0&&s>t&&(t=s)}let n=new Array(t+1);for(let r=0;r<=t;r+=1)n[r]=new Set;for(let[r,s]of e)for(let i of s)n[i].add(r);return n}function Is(e){return e==="rust"?ys:e==="python"?hs:Ss}function Ln(e,t){let n=e.startPosition.row;for(let r of e.text.matchAll(bs)){let s=r[1]??"";for(let i of s.matchAll(Ns))i[1]&&t(i[1],n)}}var _s=[/\bdefault\s*=\s*"([^"]+)"/g,/\bwith\s*=\s*"([^"]+)"/g,/\bserialize_with\s*=\s*"([^"]+)"/g,/\bdeserialize_with\s*=\s*"([^"]+)"/g,/\bskip_serializing_if\s*=\s*"([^"]+)"/g,/\bgetter\s*=\s*"([^"]+)"/g,/\brename_all_with\s*=\s*"([^"]+)"/g,/\bschema_with\s*=\s*"([^"]+)"/g],Cs=/^#!?\[\s*serde\s*\(/,Es=/^#!?\[\s*schemars\s*\(/,ks=/^#!?\[\s*validate\s*\(/,Ps=new Set(["invoke","invokeTauriCommand","listen","once","emit","subscribe","dispatch","sendCommand","callRust"]);function Tn(e,t,n){if(t!=="typescript"&&t!=="tsx"&&t!=="javascript"||e.type!=="call_expression")return;let r=e.childForFieldName("function")??e.namedChild(0);if(!r)return;let s=ne(r);if(!s||!Ps.has(s))return;let i=e.namedChildren.find(c=>c.type==="arguments");if(!i)return;let o=i.namedChild(0);if(!o||o.type!=="string")return;let a=o.namedChildren.find(c=>c.type==="string_fragment");a&&n.add(a.text)}function Fn(e,t){let n=Cs.test(e),r=Es.test(e),s=ks.test(e);if(!(!n&&!r&&!s))for(let i of _s){i.lastIndex=0;let o;for(;(o=i.exec(e))!==null;){let a=o[1],c=a.split("::").pop()??a;c==="is_none"&&/\bOption\b/.test(a)||c==="is_empty"&&/\b(String|Vec|HashMap|BTreeMap|HashSet|BTreeSet)\b/.test(a)||c&&t.add(c)}}}function Dn(e,t){let n=new Map,r=(o,a)=>{if(o===a)return;let c=n.get(o);c||(c=new Set,n.set(o,c)),c.add(a)},s=t==="python"?new Set(["identifier"]):new Set(["type_identifier"]),i=(o,a)=>{let c=l=>{s.has(l.type)&&l.text!==a&&r(l.text,a);for(let u of l.children)c(u)};for(let l of o.children)c(l)};if(t==="rust")for(let o of e.rootNode.descendantsOfType(["struct_item","enum_item","union_item","type_item"])){let a=o.namedChildren.find(l=>l.type==="type_identifier")?.text;if(!a)continue;let c=o.namedChildren.find(l=>l.type==="field_declaration_list"||l.type==="enum_variant_list"||l.type==="ordered_field_declaration_list");c&&i(c,a),o.type==="type_item"&&i(o,a)}else if(t==="python")for(let o of e.rootNode.descendantsOfType("class_definition")){let a=o.namedChildren.find(u=>u.type==="identifier")?.text;if(!a)continue;let c=o.childForFieldName("superclasses");c&&i(c,a);let l=o.namedChildren.find(u=>u.type==="block");if(l)for(let u of l.descendantsOfType("type"))for(let p of u.descendantsOfType("identifier"))p.text!==a&&r(p.text,a)}else for(let o of e.rootNode.descendantsOfType(["interface_declaration","type_alias_declaration","class_declaration"])){let a=o.namedChildren.find(c=>c.type==="type_identifier")?.text;a&&i(o,a)}return n}var Ls=new Map([["defn","function"],["defn-","function"],["defmacro","macro"],["defmacro-","macro"],["defmethod","method"]]),gt=new Set(["catch","comment","def","defprotocol","defrecord","deftype","defmethod","defmacro","defmacro-","defn","defn-","do","doseq","dotimes","fn","for","if","let","loop","ns","quote","recur","throw","try","extend-protocol","extend-type","when","when-let","when-not"]);function Rn(e){let t=[],n=[],r=[],s=new Map,i=[],o=0,a=0,c=(l,u)=>{let p=s.get(l);if(!p){s.set(l,[u]);return}p[p.length-1]!==u&&p.push(u)};for(;a<e.length;){let l=e[a];if(l===`
11
- `){o+=1,a+=1;continue}if(/\s|,/.test(l)){a+=1;continue}if(l===";"){a=Ue(e,a);continue}if(l==='"'){let x=Pe(e,a,o);o=x.line,a=x.index;continue}if(l==="("||l==="["||l==="{"){i.push({kind:l,startLine:o,endLine:o,headTokens:[],tokens:[],children:[]}),a+=1;continue}if(l===")"||l==="]"||l==="}"){let x=i.pop();x&&(x.endLine=o,Ts(x,{callables:t,callSites:n,clojureMembers:r,recordIdentifier:c}),i[i.length-1]?.children.push(x)),a+=1;continue}if(yt(l)){a+=1;continue}let u=o,p=a;for(;a<e.length&&!ht(e[a]);)a+=1;let d=e.slice(p,a);if(!d)continue;let f={text:d,line:u};Fs(i[i.length-1],f),c(T(d),u)}return{language:"clojure",callables:t,callSites:n,clojureMembers:r,typeContainerMap:new Map,identifierLineMap:s,identifiersByLine:As(s),fileIdentifiers:new Set(s.keys()),rustAttrReferencedNames:new Set,crossLanguageDispatchNames:new Set}}function Ts(e,t){if(e.kind!=="("||e.headTokens.length===0)return;let n=e.headTokens[0],r=T(n.text),s=Ls.get(n.text);if(s){let o=e.headTokens[1];if(o){let a=T(o.text);t.recordIdentifier(a,o.line),t.callables.push({name:a,startLine:e.startLine,endLine:e.endLine,paramCount:0,params:[],paramsEndLine:o.line,isLiteralPassthrough:!1,clojureKind:s})}}if(Ds(e,t),!r||gt.has(n.text)||gt.has(r)||r.startsWith(":"))return;let i=ws(n.text);t.callSites.push({calleeLeaf:i.leaf,calleeQualifier:i.qualifier,calleeText:i.text,memberAccess:!1,line:n.line})}function Fs(e,t){e&&(e.headTokens.length<2&&e.headTokens.push(t),e.tokens.length<200&&e.tokens.push(t))}function Ds(e,t){let n=T(e.tokens[0]?.text??"");if(n==="defprotocol"){let r=T(e.tokens[1]?.text??"");if(!r)return;for(let s of We(e))ke(t,r,"protocol",s,"protocol-method");return}if(n==="defrecord"||n==="deftype"){let r=T(e.tokens[1]?.text??"");if(!r)return;let s=n==="defrecord"?"record":"type",i=n==="defrecord"?"record-method":"type-method";for(let o of We(e))ke(t,r,s,o,i);return}if(n==="extend-type"){let r=T(e.tokens[1]?.text??"");if(!r)return;for(let s of We(e))ke(t,r,"extension",s,"extension-method");return}if(n==="extend-protocol"){let r=T(e.tokens[1]?.text??"");for(let s of We(e)){r&&ke(t,r,"extension",s,"extension-method");let i=vs(e,s.startLine);i&&i!==r&&ke(t,i,"extension",s,"extension-method")}}}function We(e){return e.children.filter(Rs)}function Rs(e){if(e.kind!=="(")return!1;let t=T(e.tokens[0]?.text??"");return!!(t&&!gt.has(t)&&!t.startsWith(":"))}function ke(e,t,n,r,s){let i=r.tokens[0],o=T(i?.text??"");!i||!o||(e.recordIdentifier(o,i.line),e.clojureMembers.push({ownerName:t,ownerKind:n,memberName:o,memberKind:s,startLine:r.startLine,endLine:r.endLine}))}function vs(e,t){let n=null;for(let r=2;r<e.tokens.length;r+=1){let s=e.tokens[r];if(s.line>t)break;let i=T(s.text);i&&!i.startsWith(":")&&(n=i)}return n}function T(e){return e.replace(/^#?['`~@]+/,"").split("/").pop()?.replace(/^\./,"")??""}function ws(e){let t=e.replace(/^#?['`~@]+/,""),n=t.lastIndexOf("/"),r=T(t);if(n<=0)return{leaf:r,text:t};let s=t.slice(0,n);return{leaf:r,qualifier:s,text:t}}function Ue(e,t){let n=t;for(;n<e.length&&e[n]!==`
12
- `;)n+=1;return n}function Pe(e,t,n){let r=t+1,s=n;for(;r<e.length;){let i=e[r];if(i==="\\"){r+=2;continue}if(i===`
13
- `&&(s+=1),r+=1,i==='"')break}return{index:r,line:s}}function yt(e){return e==="'"||e==="`"||e==="~"||e==="@"||e==="^"||e==="#"}function ht(e){return/\s|,/.test(e)||e==="("||e===")"||e==="["||e==="]"||e==="{"||e==="}"||e==='"'||e===";"}function As(e){let t=[];for(let[n,r]of e)for(let s of r)t[s]??=new Set,t[s].add(n);return t}var vn=6,js=de("source-facts",{clearGroups:["whole-project","source-file"]}),St=Y({kind:"source-facts",invalidation:Z("source-facts"),serialize:$s,deserialize:Bs});function ge(e,t){return xt(e,t).facts}function xt(e,t){let n=I(e,t);if(!n)return{facts:null};let r=Os(e,t,n);return r?js.get(e,t,n,()=>Ms(e,t,r,n)):{facts:null}}function Os(e,t,n){return M(t)?me(e,t,n)?.language??null:O(t)}function Ms(e,t,n,r){let s=z(e,t,r),i=St.read(e,t,s);if(i&&i.language===n)return{facts:i};if(n==="clojure"){let c=Rn(r);return St.write(e,t,s,c),{facts:c}}let o=$(e,t);if(!o)return{facts:null,unavailable:{language:n,reason:"parser-unavailable"}};let a=Vs(o,n);return St.write(e,t,s,a),{facts:a}}function $s(e){let t={version:vn,language:e.language,callables:e.callables,callSites:e.callSites,clojureMembers:e.clojureMembers,typeContainerMap:[...e.typeContainerMap.entries()].map(([n,r])=>[n,[...r]]),identifierLineMap:[...e.identifierLineMap.entries()],rustAttrReferencedNames:[...e.rustAttrReferencedNames],crossLanguageDispatchNames:[...e.crossLanguageDispatchNames]};return JSON.stringify(t)}function Bs(e){try{let t=JSON.parse(e);if(t.version!==vn||t.language==="clojure"&&(t.clojureMembers===void 0||t.callSites.some(r=>r.calleeText===void 0)))return null;let n=new Map(t.identifierLineMap);return{language:t.language,callables:t.callables,callSites:t.callSites,clojureMembers:t.clojureMembers??[],typeContainerMap:new Map(t.typeContainerMap.map(([r,s])=>[r,new Set(s)])),identifierLineMap:n,identifiersByLine:mt(n),fileIdentifiers:new Set(n.keys()),rustAttrReferencedNames:new Set(t.rustAttrReferencedNames),crossLanguageDispatchNames:new Set(t.crossLanguageDispatchNames)}}catch{return null}}function Vs(e,t){let n=[],r=[],s=new Set,i=new Set,o=new Map,a=(l,u)=>{let p=o.get(l);if(!p){o.set(l,[u]);return}p[p.length-1]!==u&&p.push(u)},c=l=>{let u=Ve(l,t);u&&n.push(u);let p=En(l,t);p&&r.push(p),Tn(l,t,i),t==="rust"&&(l.type==="attribute_item"||l.type==="inner_attribute_item")&&Fn(l.text,s),kn(l,t)&&a(l.text,l.startPosition.row),Pn(l,t)&&Ln(l,a);for(let d of l.children)c(d)};return c(e.rootNode),{language:t,callables:n,callSites:r,clojureMembers:[],typeContainerMap:Dn(e,t),identifierLineMap:o,identifiersByLine:mt(o),fileIdentifiers:new Set(o.keys()),rustAttrReferencedNames:s,crossLanguageDispatchNames:i}}var wn=new WeakMap,An=new Set(["call_expression","call","decorator","pair","string","string_literal","template_string","variable_declarator"]);function Ws(e,t){let n=Array.isArray(t)?t:[t];if(!n.every(i=>An.has(i)))return e.descendantsOfType(t);let r=Us(e);return n.length===1?r.get(n[0])??[]:n.flatMap(i=>r.get(i)??[]).sort((i,o)=>i.startIndex-o.startIndex)}function bt(e,t){let n=e.walk(),r=0,s=!1;for(;!s;){if(t(n),n.gotoFirstChild()){r+=1;continue}for(;;){if(r===0){s=!0;break}if(n.gotoNextSibling())break;n.gotoParent(),r-=1}}}function Us(e){let t=wn.get(e);if(t)return t;let n=new Map;return bt(e,r=>{let s=r.nodeType;if(!An.has(s))return;let i=n.get(s);i?i.push(r.currentNode):n.set(s,[r.currentNode])}),wn.set(e,n),n}function On(e,t){t(e);for(let n of e.namedChildren)On(n,t)}var Hs=/(?:function|method|lambda)/u,jn=new WeakMap;function zs(e){let t=jn.get(e);if(t)return t;let n=[];return bt(e,r=>{if(!r.nodeIsNamed)return;let s=r.nodeType;(s==="arrow_function"||Hs.test(s))&&n.push(r.currentNode)}),jn.set(e,n),n}function qs(e,t,n){let r=null;for(let s of zs(e))s.startPosition.row>t||s.endPosition.row<n||(!r||s.endIndex-s.startIndex<r.endIndex-r.startIndex)&&(r=s);return r}function Mn(e,t,n){if(e.startPosition.row>t||e.endPosition.row<n)return null;for(let r of e.namedChildren){let s=Mn(r,t,n);if(s)return s}return e}function Qs(e){let t=e;for(;["as_expression","satisfies_expression","type_assertion","parenthesized_expression"].includes(t.type)&&t.namedChildren.length>0;)t=t.namedChildren[0];return t}function Nt(e){if(e.type==="identifier")return e.text;let t=e.childForFieldName("name")??e.childForFieldName("pattern");return t?Nt(t):e.namedChildren.find(n=>n.type==="identifier")?.text??null}function Js(e){return(e.childForFieldName("parameters")??e.namedChildren.find(n=>/parameters/u.test(n.type)))?.namedChildren.map(Nt)??[]}var $n=new Set(["rust","typescript","tsx","javascript","python","clojure"]),Ks=new Set(["rust","typescript","tsx","javascript","python"]);function It(e,t){let n=ge(e,t);return!n||!$n.has(n.language)?null:n.callables.map(r=>({name:r.name,startLine:r.startLine,endLine:r.endLine}))}function Xs(e,t){if(!Ks.has(t))return null;let n=[];for(let r of e.descendantsOfType([..._n(t)])){let s=Ve(r,t);s&&n.push({name:s.name,startLine:s.startLine,endLine:s.endLine})}return n}function Gs(e,t){let n=ge(e,t);return!n||!$n.has(n.language)?null:n.callSites}function Bn(e,t){return e.split(t).filter(Boolean).map(n=>n.charAt(0).toUpperCase()+n.slice(1)).join("")}import{createRequire as ci}from"module";import{existsSync as ie}from"fs";import{basename as Wn,dirname as k,extname as B,join as F,relative as re,resolve as S,sep as li}from"path";import{existsSync as Ct,readdirSync as Ys,statSync as Zs}from"fs";import{join as ye,relative as ei}from"path";function Vn(e){let t=ti(e)??ii(e);if(!t||t.length===0)return[];let n=[],r=new Set;for(let s of t)for(let i of oi(e,s)){if(r.has(i))continue;r.add(i);let o=ai(e,i);o&&n.push(o)}return n}function ti(e){let t=ye(e,"pnpm-workspace.yaml");if(!Ct(t))return null;try{return ni(De(t,"pnpm workspace manifest"))}catch{return null}}function ni(e){let t=[],n=!1;for(let r of e.split(/\r?\n/)){let s=ri(r);if(!n){/^packages\s*:\s*$/.test(s.trim())&&(n=!0);continue}let i=/^\s+-\s*(.+)$/.exec(s);if(i){let o=si(i[1].trim());o&&t.push(o);continue}if(s.trim()!=="")break}return t}function ri(e){let t=e.indexOf("#");return t===-1?e:e.slice(0,t)}function si(e){return e.startsWith('"')&&e.endsWith('"')||e.startsWith("'")&&e.endsWith("'")?e.slice(1,-1):e}function ii(e){let t=ye(e,"package.json");if(!Ct(t))return null;try{let n=JSON.parse(De(t,"workspace package manifest"));return n.workspaces?Array.isArray(n.workspaces)?n.workspaces:n.workspaces.packages??[]:null}catch{return null}}function oi(e,t){if(!t||t.startsWith("!")||t.includes("node_modules"))return[];if(!t.includes("*")){let o=ye(e,t);return _t(o)?[o]:[]}let n=t.indexOf("*"),r=t.slice(0,n).replace(/\/$/,""),s=t.slice(n+1).replace(/^\//,""),i=ye(e,r||".");return _t(i)?Ys(i).map(o=>ye(i,o,s)).filter(_t):[]}function _t(e){try{return Zs(e).isDirectory()}catch{return!1}}function ai(e,t){let n=ye(t,"package.json");if(!Ct(n))return null;try{let r=JSON.parse(De(n,"workspace package manifest"));return typeof r.name!="string"||r.name.length===0?null:{name:r.name,relativeDir:ei(e,t).replace(/\\/g,"/"),exports:r.exports}}catch{return null}}var ui=pe("indexed-paths",{clearGroups:[]}),pi=pe("indexed-path-digest",{clearGroups:[]}),di=N("tsconfig-alias-config",{clearGroups:["whole-project"]}),fi=N("tsconfig-alias-config-for-dir",{clearGroups:["whole-project"]}),mi=ci(import.meta.url),Le;function gi(){if(Le!==void 0)return Le;try{Le=mi("typescript")}catch{Le=null}return Le}var yi=["tsconfig.json","tsconfig.app.json","tsconfig.node.json","tsconfig.base.json"],hi=pe("workspace-packages",{clearGroups:["whole-project"]}),se=[".ts",".tsx",".mts",".cts",".js",".jsx",".mjs",".cjs",".vue"],He=[".py",".pyi"],P=[".java",".scala",".kt",".kts"],ze=[".rs"],qe=[".rb"],Qe=[".c",".h",".cc",".cpp",".cxx",".hpp",".hh",".hxx"],Q=[".cs",".vb"],Je=[".dart"],oe=[".php"],he=[".clj",".cljs",".cljc"],Si=new Set(se),Et=new Set(He),Un=new Set(P),kt=new Set(ze),Pt=new Set(qe),Hn=new Set(Qe),zn=new Set(Q),Lt=new Set(Je),qn=new Set(oe),Qn=new Set(he),xi=[{extensions:se,lookup:Si},{extensions:He,lookup:Et},{extensions:P,lookup:Un},{extensions:ze,lookup:kt},{extensions:qe,lookup:Pt},{extensions:Qe,lookup:Hn},{extensions:Q,lookup:zn},{extensions:Je,lookup:Lt},{extensions:oe,lookup:qn},{extensions:he,lookup:Qn}];function V(e,t){return t.has(B(e).toLowerCase())}function bi(e){return V(e,Et)}function Ni(e){return V(e,Un)}function Ii(e){return V(e,kt)}function _i(e){return V(e,Pt)}function Ci(e){return V(e,Hn)}function Ei(e){return V(e,zn)}function Jn(e){return B(e).toLowerCase()===".vb"}function ki(e){return V(e,Lt)}function Pi(e){return V(e,qn)}function Li(e){return V(e,Qn)}function Tt(e){let t=B(e).toLowerCase();for(let n of xi)if(n.lookup.has(t))return n.extensions;return se}function Ti(e){return Ni(e)||Ei(e)||Pi(e)}function J(e,t,n){return bi(t)?Se(e,t,n):Ii(t)?W(e,t,n):_i(t)?Ke(e,t,n):Ci(t)?Xe(e,t,n):Ti(t)?g(e,n.replace(/\\/g,"."),Tt(t)):ki(t)?Ge(e,t,n):Li(t)?Ft(e,n):Fi(e,t,n)}function Fi(e,t,n){if(!n.startsWith(".")&&!n.startsWith("/"))return Di(e,t,n)??vi(e,n);let r=k(F(e.config.projectRoot,t)),s=S(r,n),i=U(e);for(let o of Rt(s)){let a=b(re(e.config.projectRoot,o));if(i.has(a)||ie(o))return a}return b(re(e.config.projectRoot,s))}function Di(e,t,n){let r=$i(e,t);if(!r)return null;let s=U(e);for(let i of Ri(r,n)){let o=S(r.baseUrl,i);for(let a of Rt(o)){let c=b(re(e.config.projectRoot,a));if(s.has(c)||ie(a))return c}}return null}function Ri(e,t){let n=[];for(let[r,s]of Object.entries(e.paths)){let i=r.indexOf("*");if(i===-1){if(t!==r)continue;n.push(...s);continue}let o=r.slice(0,i),a=r.slice(i+1);if(!t.startsWith(o)||!t.endsWith(a)||t.length<o.length+a.length)continue;let c=t.slice(o.length,t.length-a.length);for(let l of s)n.push(l.includes("*")?l.replace("*",c):l)}return n}function vi(e,t){let n=Ai(wi(e),t);if(!n)return null;let r=U(e);for(let s of ji(n)){let i=S(e.config.projectRoot,n.pkg.relativeDir,s);for(let o of Rt(i)){let a=b(re(e.config.projectRoot,o));if(r.has(a)||ie(o))return a}}return null}function wi(e){return hi.get(e,()=>Vn(e.config.projectRoot))}function Ai(e,t){let n=null;for(let r of e){let s=null;t===r.name?s="":t.startsWith(`${r.name}/`)&&(s=t.slice(r.name.length+1)),s!==null&&(!n||r.name.length>n.pkg.name.length)&&(n={pkg:r,subpath:s})}return n}function ji(e){let t=[],n=Oi(e.pkg.exports,e.subpath);if(n){let r=Mi(n);r&&t.push(r)}return t.push(e.subpath?`src/${e.subpath}`:"src/index"),t}function Oi(e,t){if(!e||typeof e!="object")return null;let n=t===""?".":`./${t}`;return Kn(e[n])}function Kn(e){if(typeof e=="string")return e;if(!e||typeof e!="object")return null;let t=e;for(let n of["types","import","default","require","node"]){let r=Kn(t[n]);if(r)return r}return null}function Mi(e){let t=e.replace(/^\.\//,"");return t.startsWith("dist/")?`src/${t.slice(5)}`:null}function $i(e,t){let n=b(k(t));return fi.get(e,n,()=>Bi(e,n))}function Bi(e,t){let n=gi();if(!n)return null;let r=S(e.config.projectRoot),s=S(r,t);for(;s===r||s.startsWith(r+li);){for(let o of yi){let a=F(s,o);if(!ie(a))continue;let c=di.get(e,a,()=>Vi(n,a));if(c)return c}let i=k(s);if(i===s)break;s=i}return null}function Vi(e,t){try{let n=e.readConfigFile(t,e.sys.readFile);if(n.error||!n.config)return null;let r=e.parseJsonConfigFileContent(n.config,e.sys,k(t)),s=r.options.paths;return!s||Object.keys(s).length===0?null:{baseUrl:r.options.baseUrl?S(k(t),r.options.baseUrl):k(t),paths:s}}catch{return null}}function Se(e,t,n){let r=U(e),s;if(n.startsWith(".")){let i=n.match(/^(\.+)(.*)$/);if(!i)return null;let o=i[1].length,a=i[2].replace(/^\./,""),c=k(F(e.config.projectRoot,t));for(let l=1;l<o;l++)c=k(c);s=a?S(c,a.replace(/\./g,"/")):c}else s=S(e.config.projectRoot,n.replace(/\./g,"/"));for(let i of Wi(s)){let o=b(re(e.config.projectRoot,i));if(r.has(o)||ie(i))return o}return null}function W(e,t,n){if(!n)return null;let r=n.replace(/\s+as\s+.+$/,"").trim();if(!r.startsWith("crate::")&&!r.startsWith("self::")&&!r.startsWith("super::"))return null;let s=k(F(e.config.projectRoot,t)),i;return r.startsWith("crate::")?i=S(e.config.projectRoot,"src",r.slice(7).replace(/::/g,"/")):r.startsWith("self::")?i=S(s,r.slice(6).replace(/::/g,"/")):i=S(k(s),r.slice(7).replace(/::/g,"/")),Dt(e,Ui(i))}function Ke(e,t,n){let r=k(F(e.config.projectRoot,t)),s=S(r,n);return Dt(e,Hi(s))}function Xe(e,t,n){let r=k(F(e.config.projectRoot,t)),s=[S(r,n),S(e.config.projectRoot,n),S(e.config.projectRoot,"include",n),S(e.config.projectRoot,"src",n)];return Dt(e,s)}function g(e,t,n){let r=U(e),s=t.replace(/\\/g,".").replace(/::/g,".").replace(/^global::/,""),i=s.replace(/\./g,"/"),o=s.split(".").pop()??s;for(let c of n){let l=`${i}${c}`,u=[...r].find(p=>p.endsWith(l));if(u)return u}for(let c of n){let l=[...r].find(u=>Wn(u)===`${o}${c}`);if(l)return l}let a=[...r].filter(c=>n.includes(B(c).toLowerCase())).filter(c=>c.includes(`/${i}/`)||c.includes(`/${o}/`)).sort((c,l)=>c.localeCompare(l));return a.length===1?a[0]:null}function Ge(e,t,n){let r=U(e);if(n.startsWith("package:")){let o=n.slice(8),a=o.indexOf("/");if(a<0)return null;let c=o.slice(a+1),l=b(c.startsWith("lib/")?c:`lib/${c}`);return r.has(l)?l:null}let s=k(F(e.config.projectRoot,t)),i=S(s,n);for(let o of zi(i)){let a=b(re(e.config.projectRoot,o));if(r.has(a)||ie(o))return a}return null}function Ft(e,t){let n=t.replace(/-/g,"_").replace(/\./g,"/"),r=U(e);for(let s of he){let i=`${n}${s}`,o=[...r].find(a=>a.endsWith(i));if(o)return o}for(let s of he){let i=[...r].find(o=>Wn(o)===`${n.split("/").pop()}${s}`);if(i)return i}return null}function Wi(e){let t=B(e);return Et.has(t)?[e]:[`${e}.py`,`${e}.pyi`,F(e,"__init__.py"),F(e,"__init__.pyi")]}function Dt(e,t){let n=U(e);for(let r of t){let s=b(re(e.config.projectRoot,r));if(n.has(s)||ie(r))return s}return null}function Ui(e){let t=B(e);return kt.has(t)?[e]:[`${e}.rs`,F(e,"mod.rs")]}function Hi(e){let t=B(e);return Pt.has(t)?[e]:[`${e}.rb`,F(e,"index.rb")]}function zi(e){let t=B(e);return Lt.has(t)?[e]:[`${e}.dart`,e]}function Rt(e){let t=B(e),n=new Set;if(t){n.add(e);for(let r of se)n.add(e.slice(0,-t.length)+r)}else for(let r of se)n.add(`${e}${r}`),n.add(F(e,`index${r}`));return[...n]}function U(e){return ui.get(e,()=>new Set(Ie(e,{includeIgnored:!1}).map(b)))}function vt(e){return pi.get(e,()=>Yt([...U(e)].sort().join(`
14
- `)))}function qi(e,t,n={}){let r=ge(e,t);if(!r)return[];let s=[];if(n.includeCrossLanguageDispatchNames)for(let i of r.crossLanguageDispatchNames)s.push({name:i,kind:"cross-language-dispatch",occurrences:1});if(n.includeRustAttributeNames&&r.language==="rust")for(let i of r.rustAttrReferencedNames)s.push({name:i,kind:"rust-attribute",occurrences:1});return s}import{basename as Xn}from"path";function A(e){return e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function Qi(e){return e.replace(/'''[\s\S]*?'''/g,K).replace(/"""[\s\S]*?"""/g,K).replace(/#.*$/gm,K).replace(/\/\/.*$/gm,K).replace(/\/\*[\s\S]*?\*\//g,K).replace(/`(?:\\[\s\S]|[^`])*`/g,K).replace(/'(?:\\.|[^'\\\r\n])*'/g,K).replace(/"(?:\\.|[^"\\\r\n])*"/g,K)}function K(e){return e.replace(/[^\r\n]/g," ")}var Ql=de("stripped-lines",{clearGroups:["whole-project","source-file"]});Xt({name:"stripped-source-singleton",groups:["whole-project","source-file"],clearAll:()=>{Ye=null,Te=""},clearFile:()=>{Ye=null,Te=""}});var Ye=null,Te="";function Ji(e){return Ye===e||(Ye=e,Te=Qi(e)),Te}function X(e,t,n){let r=Ji(e);return`${r.slice(0,t)}${" ".repeat(n-t)}${r.slice(n)}`}function C(e,t){return new RegExp(`\\b${A(t)}\\b`,"m").test(e)}function xe(e,t){let n=new Set,r=new RegExp(`\\b${A(t)}\\s*\\.\\s*([A-Za-z_$][\\w$]*)`,"g");for(let s of e.matchAll(r)){let i=s[1];i&&n.add(i)}return[...n]}function wt(e){let t=0;for(let n of e)n==="("&&(t+=1),n===")"&&(t-=1);return t}var Ki=new Set(["identifier","type_identifier","property_identifier","shorthand_property_identifier","field_identifier"]);function E(e){let t=[],n=0,r=0;for(let s=0;s<e.length;s++){let i=e[s];(i==="{"||i==="["||i==="(")&&n++,(i==="}"||i==="]"||i===")")&&n--,i===","&&n===0&&(t.push(e.slice(r,s)),r=s+1)}return t.push(e.slice(r)),t}function L(e,t){for(let n of e.namedChildren)if(n.type===t)return n;return null}function y(e,t){let n=new Set,r=(s,i)=>{let o=i||t.has(s.type);!o&&Ki.has(s.type)&&n.add(s.text);for(let a of s.children)r(a,o)};return r(e.rootNode,!1),n}function w(e,t,n,r,s,i,o){return{importedName:s,localName:i,sourcePath:o??g(e,r,Tt(t)),kind:"named",used:C(n,i),usedMembers:[]}}function m(e,t,n,r,s="named",i={}){return{importedName:e,localName:t,sourcePath:n,kind:s,used:r.has(t),usedMembers:[],isTypeOnly:i.isTypeOnly}}function H(e,t,n,r,s="named",i=[],o={}){return{importedName:e,localName:t,sourcePath:n,kind:s,used:r,usedMembers:i,isTypeOnly:o.isTypeOnly}}function ae(e,t){return{importedName:e,localName:null,sourcePath:t,kind:"side-effect",used:!0,usedMembers:[]}}function ce(e,t,n={}){return{importedName:e,localName:n.localName??null,sourcePath:t,kind:"namespace",used:n.used??!0,usedMembers:n.usedMembers??[],isTypeOnly:n.isTypeOnly}}function D(e,t,n){let r=[];for(let s of e.matchAll(t)){let i=s[0];if(!i||typeof s.index!="number")continue;let o=X(e,s.index,s.index+i.length);for(let a of n(s,o))r.push(a)}return r}function R(e,t,n,r,s){let i=Ce(e,t,s)?.tree??null;if(i){let o=n(i);if(o)return o}return r()}function Ze(e,t,n,r,s){let i=Ce(e,t,s)?.tree??null,o=O(t),a=o?n[o]:void 0;return i&&a?a(i):r()}function Gn(e,t,n){return R(e,t,r=>Gi(e,t,r),()=>Xi(e,t,n),n)}function Xi(e,t,n){return D(n,/^[ \t]*#include\s+[<"]([^">]+)[">]\s*$/gm,(r,s)=>{let i=r[1]?.trim();if(!i)return[];let o=Xn(i).replace(/\.[^.]+$/,"");return[H(i,o,Xe(e,t,i),C(s,o))]})}function Gi(e,t,n){let r=y(n,new Set(["preproc_include"])),s=[];for(let i of n.rootNode.descendantsOfType("preproc_include")){let o=null;for(let c of i.namedChildren){if(c.type==="system_lib_string"){o=c.text.replace(/^<|>$/g,"");break}if(c.type==="string_literal"){o=c.namedChildren.find(u=>u.type==="string_content")?.text??c.text.replace(/^"|"$/g,"");break}}if(!o)continue;let a=Xn(o).replace(/\.[^.]+$/,"");s.push(m(o,a,Xe(e,t,o),r))}return s}var Yi=new Set([":require",":require-macros",":use"]),Ot=String.raw`A-Za-z0-9_$*+!?.<>=-`;function Zn(e,t,n){let r=lo(n);if(!r)return[];let s=co(n,r.start,r.end),i=[];for(let o of r.children.slice(2)){if(o.type!=="list"||o.children.length===0)continue;let a=v(o.children[0]);if(a){if(Yi.has(a)){for(let c of to(o.children.slice(1)))i.push(...eo(e,c,s));continue}if(a===":import")for(let c of ro(o.children.slice(1)))i.push(c)}}return i}function Zi(e){return e.type==="list"&&v(e.children[0])==="ns"}function eo(e,t,n){let r=Ft(e,t.namespace),s=t.alias??t.namespace,i=io(n,s),o=[{importedName:t.namespace,localName:s,sourcePath:r,kind:"namespace",used:t.refers.length>0||t.referAll||i.length>0||oo(n,t.namespace),usedMembers:i}];t.referAll&&o.push({importedName:"*",localName:null,sourcePath:r,kind:"side-effect",used:!0,usedMembers:[]});for(let a of t.refers)o.push({importedName:a,localName:a,sourcePath:r,kind:"named",used:ao(n,a),usedMembers:[]});return o}function to(e){return e.flatMap(t=>et(t,null))}function et(e,t){if(e.type==="atom")return e.text.startsWith(":")?[]:[{namespace:jt(t,e.text),alias:null,refers:[],referAll:!1}];if(e.type==="vector")return e.children.length>0&&v(e.children[0])===null?e.children.flatMap(n=>et(n,t)):no(e,t);if(e.type==="list"&&e.children.length>0){let n=v(e.children[0]);return n?!n||n.startsWith(":")?[]:e.children.slice(1).flatMap(r=>et(r,jt(t,n))):e.children.flatMap(r=>et(r,t))}return[]}function no(e,t){let n=v(e.children[0]);if(!n||n.startsWith(":"))return[];let r={namespace:jt(t,n),alias:null,refers:[],referAll:!1};for(let s=1;s<e.children.length;s+=1){let i=v(e.children[s]);if(!i?.startsWith(":"))continue;let o=e.children[s+1];if((i===":as"||i===":as-alias")&&o){r.alias=v(o),s+=1;continue}i===":refer"&&o&&(v(o)===":all"?r.referAll=!0:(o.type==="vector"||o.type==="list")&&r.refers.push(...o.children.map(v).filter(so)),s+=1)}return[r]}function ro(e){let t=[];for(let n of e){if(n.type==="atom"){let s=n.text.split(".").pop()??n.text;t.push(H(s,s,null,!0));continue}if(n.type!=="vector")continue;let r=v(n.children[0]);if(r)for(let s of n.children.slice(1)){let i=v(s);i&&t.push(H(`${r}.${i}`,i,null,!0))}}return t}function jt(e,t){return e?`${e}.${t}`:t}function v(e){return e?.type==="atom"?e.text:null}function so(e){return!!(e&&!e.startsWith(":"))}function io(e,t){let n=new Set,r=new RegExp(`${Mt()}${A(t)}\\s*/\\s*([${Ot}]+)`,"g");for(let s of e.matchAll(r)){let i=s[1];i&&n.add(i)}return[...n]}function oo(e,t){return new RegExp(`${Mt()}${A(t)}\\s*/`,"m").test(e)}function ao(e,t){return new RegExp(`${Mt()}${A(t)}(?![${Ot}])`,"m").test(e)}function Mt(){return`(?<![${Ot}])`}function co(e,t,n){let r="",s=0;for(;s<e.length;){if(s>=t&&s<n){r+=e[s]===`
15
- `?`
16
- `:" ",s+=1;continue}let i=e[s];if(i===";"){let o=Ue(e,s);r+=Yn(e.slice(s,o)),s=o;continue}if(i==='"'){let o=Pe(e,s,0).index;r+=Yn(e.slice(s,o)),s=o;continue}r+=i,s+=1}return r}function lo(e){let t=0;for(;t<e.length&&(t=$t(e,t),!(t>=e.length));){let n=tt(e,t);if(!n){t+=1;continue}if(Zi(n.form))return n.form;t=n.index}return null}function tt(e,t){let n=$t(e,t);if(e.startsWith("#?@",n)||e.startsWith("#?",n))return uo(e,n);if(e.startsWith("#_",n)){let s=tt(e,n+2);return s?{form:{type:"atom",text:"",start:n,end:s.index},index:s.index}:null}for(;yt(e[n]);)n+=1;let r=e[n];return r?r==="("?At(e,n,"list",")"):r==="["?At(e,n,"vector","]"):r==="{"?At(e,n,"map","}"):r==='"'?{form:{type:"atom",text:"",start:n,end:Pe(e,n,0).index},index:Pe(e,n,0).index}:fo(e,n):null}function uo(e,t){let n=e.startsWith("#?@",t)?3:2,r=tt(e,t+n);return r?{form:{type:"list",children:r.form.type==="list"||r.form.type==="vector"||r.form.type==="map"?po(r.form.children):[],start:t,end:r.index},index:r.index}:null}function po(e){let t=[];for(let n=0;n<e.length;n+=2){let r=v(e[n]),s=e[n+1];r?.startsWith(":")&&s&&t.push(s)}return t}function At(e,t,n,r){let s=[],i=t+1;for(;i<e.length;){if(i=$t(e,i),e[i]===r)return{form:{type:n,children:s,start:t,end:i+1},index:i+1};let o=tt(e,i);if(!o){i+=1;continue}o.form.type==="atom"&&o.form.text===""||s.push(o.form),i=o.index}return{form:{type:n,children:s,start:t,end:e.length},index:e.length}}function fo(e,t){let n=t;for(;n<e.length&&!ht(e[n]);)n+=1;return{form:{type:"atom",text:e.slice(t,n),start:t,end:n},index:n}}function $t(e,t){let n=t;for(;n<e.length;){let r=e[n];if(/\s|,/.test(r)){n+=1;continue}if(r===";"){n=Ue(e,n);continue}break}return n}function Yn(e){return e.replace(/[^\r\n]/g," ")}function er(e,t,n){let r=[];for(let s of n.matchAll(/^[ \t]*import\s+['"]([^'"]+)['"](?:\s+as\s+([A-Za-z_]\w*))?[\s\S]*?;$/gm)){let i=s[1]?.trim(),o=s[2]?.trim()??null,a=s[0];if(!i||!a||typeof s.index!="number")continue;let c=X(n,s.index,s.index+a.length);r.push({importedName:i,localName:o,sourcePath:Ge(e,t,i),kind:o?"namespace":"side-effect",used:o?C(c,o):!0,usedMembers:o?xe(c,o):[]})}return r}function tr(e,t,n){let r=[];for(let s of n.matchAll(/^[ \t]*export\s+['"]([^'"]+)['"][\s\S]*?;$/gm)){let i=s[1]?.trim();i&&r.push({specifier:i,sourcePath:Ge(e,t,i)})}return r}function nr(e,t,n){return Ze(e,t,{csharp:r=>go(e,t,r),vb:r=>mo(e,t,r)},()=>{let r=Jn(t)?/^[ \t]*Imports\s+(.+?)\s*$/gm:/^[ \t]*using\s+(.+?)\s*;$/gm;return D(n,r,(s,i)=>{let o=s[1]?.trim();if(!o)return[];let[a,c]=o.split(/\s*=\s*/),l=!!c,u=(l?c:a)?.trim()??o,p=u.split(".").pop()??u,d=l?a?.trim()??p:p;return[w(e,t,i,u,p,d,g(e,u,Q))]})},n)}function mo(e,t,n){let r=y(n,new Set(["imports_statement"])),s=[];for(let i of n.rootNode.descendantsOfType("imports_statement")){let o=i.namedChildren.filter(d=>d.type==="namespace_name");if(o.length===0)continue;let a=o[o.length-1],c=o.length>1?o[0]:null,l=a.text,u=l.split(".").pop()??l,p=c?.text??u;s.push(m(u,p,g(e,l,Q),r,c?"namespace":"named"))}return s}function go(e,t,n){let r=y(n,new Set(["using_directive"])),s=[];for(let i of n.rootNode.descendantsOfType("using_directive")){let o=i.namedChildren;if(o.length===0)continue;let a=null,c;o.length>=2&&o[0].type==="identifier"&&(o[1].type==="qualified_name"||o[1].type==="identifier")?(a=o[0],c=o[1]):c=o[o.length-1];let l=c.text,u=l.split(".").pop()??l,p=a?.text??u;s.push(m(u,p,g(e,l,Q),r,a?"namespace":"named"))}return s}var yo=N("vue-non-script-identifiers",{clearGroups:["whole-project","source-file"]});function rr(e,t){return yo.get(e,t,()=>{let n=new Set,r=I(e,t);if(!r)return n;let i=r.replace(/<script\b[^>]*>[\s\S]*?<\/script>/g,o=>o.replace(/[^\r\n]/g," ")).replace(/<!--[\s\S]*?-->/g,o=>o.replace(/[^\r\n]/g," ")).replace(/\/\*[\s\S]*?\*\//g,o=>o.replace(/[^\r\n]/g," "));for(let o of i.matchAll(/[A-Za-z_$][\w$]*/g))n.add(o[0]);return n})}function Bt(e,t,n){return R(e,t,r=>So(e,t,r),()=>ho(e,t,n),n)}function ho(e,t,n){return To(n).flatMap(r=>Fo(e,t,r.clause,r.specifier,r.start,r.end,n))}function So(e,t,n){let r=xo(e,t,n),s=[];for(let i of n.rootNode.descendantsOfType("import_statement"))s.push(...bo(e,t,n,i,r));return s}function xo(e,t,n){let r=y(n,new Set(["import_statement"]));if(M(t))for(let s of rr(e,t))r.add(s);return r}function bo(e,t,n,r,s){let i=Eo(r);if(!i)return[];let o=J(e,t,i),a=L(r,"import_clause");return a?No(n,a,o,s,ko(r.text)):[ae("*",o)]}function No(e,t,n,r,s){let i=[];for(let o of t.namedChildren)if(o.type==="identifier")i.push(Io(o.text,n,r,s));else if(o.type==="namespace_import"){let a=_o(e,o,n,r,s);a&&i.push(a)}else o.type==="named_imports"&&i.push(...Co(o,n,r,s));return i}function Io(e,t,n,r){return m("default",e,t,n,"default",{isTypeOnly:r})}function _o(e,t,n,r,s){let o=L(t,"identifier")?.text??"";if(!o)return null;let a=Lo(e,o);return ce("*",n,{localName:o,usedMembers:a,isTypeOnly:s,used:a.length>0||r.has(o)})}function Co(e,t,n,r){let s=[];for(let i of e.namedChildren){if(i.type!=="import_specifier")continue;let o=i.namedChild(0),a=i.namedChild(1);if(!o)continue;let c=o.text,l=a?.text??c;s.push(m(c,l,t,n,"named",{isTypeOnly:r||Po(i.text)}))}return s}function Eo(e){let t=L(e,"string");if(!t)return null;let n=L(t,"string_fragment");return n?n.text:null}function ko(e){return/^\s*import\s+type\b/.test(e)}function Po(e){return/^\s*type\b/.test(e.trim())}function Lo(e,t){let n=new Set;for(let r of e.rootNode.descendantsOfType("member_expression")){let s=r.namedChild(0),i=r.namedChild(1);!s||!i||s.type!=="identifier"||s.text!==t||(i.type==="property_identifier"||i.type==="identifier")&&n.add(i.text)}return[...n]}function To(e){let t=[],n=/^[ \t]*import\s+([\s\S]*?)\s+from\s+['"]([^'"]+)['"]\s*;?/gm;for(let s of e.matchAll(n)){let i=s[0],o=s[1],a=s[2];!i||!a||typeof s.index!="number"||t.push({clause:o,specifier:a,start:s.index,end:s.index+i.length})}let r=/^[ \t]*import\s+['"]([^'"]+)['"]\s*;?/gm;for(let s of e.matchAll(r)){let i=s[0],o=s[1];!i||!o||typeof s.index!="number"||t.push({clause:null,specifier:o,start:s.index,end:s.index+i.length})}return t.sort((s,i)=>s.start-i.start)}function Fo(e,t,n,r,s,i,o){let a=J(e,t,r),c=X(o,s,i);return n?Do(n).map(u=>({...u,sourcePath:a})).map(u=>{if(u.kind==="namespace"){let p=xe(c,u.localName);return ce(u.importedName,u.sourcePath,{localName:u.localName,usedMembers:p,used:p.length>0||C(c,u.localName),isTypeOnly:u.isTypeOnly})}return u.kind==="side-effect"?ae(u.importedName,u.sourcePath):H(u.importedName,u.localName??"",u.sourcePath,u.localName?C(c,u.localName):!1,u.kind,[],{isTypeOnly:u.isTypeOnly})}):[ae("*",a)]}function Do(e){let t=e.trim(),n=/^type\b/.test(t),r=t.replace(/^type\s+/,""),[s,i]=Ro(r),o=[];return s&&o.push(...sr(s,n)),i&&o.push(...sr(i,n)),o}function sr(e,t){let n=e.trim();if(!n)return[];if(n.startsWith("{")){let r=n.slice(1,-1).trim();return r?E(r).map(s=>{let i=s.trim(),o=t||/^type\b/.test(i),a=i.replace(/^type\s+/,""),[c,l]=a.split(/\s+as\s+/);return{importedName:c.trim(),localName:(l??c).trim(),kind:"named",isTypeOnly:o}}):[]}return n.startsWith("* as ")?[{importedName:"*",localName:n.slice(5).trim(),kind:"namespace",isTypeOnly:t}]:[{importedName:"default",localName:n,kind:"default",isTypeOnly:t}]}function Ro(e){let t=0;for(let n=0;n<e.length;n++){let r=e[n];if(r==="{"&&t++,r==="}"&&t--,r===","&&t===0)return[e.slice(0,n).trim(),e.slice(n+1).trim()]}return[e.trim(),null]}function Vt(e,t,n){let r=$(e,t);return r?Mo(e,t,r):vo(e,t,n)}function vo(e,t,n){return[...wo(e,t,n),...Ao(e,t,n),...jo(e,t,n)]}function wo(e,t,n){let r=[],s=/^[ \t]*export\s+(?:type\s+)?\{([\s\S]*?)\}\s+from\s+['"]([^'"]+)['"]\s*;?/gm;for(let i of n.matchAll(s)){if(typeof i.index!="number")continue;let o=i[1]??"",a=i[2]??"",c=E(o).map(p=>Oo(p.trim())).filter(p=>!!p),l=be(n,i.index),u=be(n,i.index+i[0].length-1);r.push({kind:"named",sourcePath:J(e,t,a),names:c,startLine:l,endLine:u})}return r}function Ao(e,t,n){let r=[],s=/^[ \t]*export\s+\*\s+as\s+(\w+)\s+from\s+['"]([^'"]+)['"]\s*;?/gm;for(let i of n.matchAll(s)){if(typeof i.index!="number")continue;let o=i[2]??"",a=be(n,i.index),c=be(n,i.index+i[0].length-1);r.push({kind:"star-as",sourcePath:J(e,t,o),names:i[1]?[i[1]]:[],startLine:a,endLine:c})}return r}function jo(e,t,n){let r=[],s=/^[ \t]*export\s+\*\s+from\s+['"]([^'"]+)['"]\s*;?/gm;for(let i of n.matchAll(s)){if(typeof i.index!="number")continue;let o=i[1]??"",a=be(n,i.index),c=be(n,i.index+i[0].length-1);r.push({kind:"star",sourcePath:J(e,t,o),names:[],startLine:a,endLine:c})}return r}function Oo(e){if(!e)return null;let t=e.replace(/^type\s+/,"").trim();if(!t)return null;let n=t.match(/^(\w+)\s+as\s+(\w+)$/);if(n)return n[2]??null;let r=t.match(/^(\w+)$/);return r?r[1]??null:null}function be(e,t){let n=0;for(let r=0;r<t&&r<e.length;r++)e.charCodeAt(r)===10&&n++;return n}function Mo(e,t,n){let r=[];for(let s of n.rootNode.descendantsOfType("export_statement")){let i=$o(e,t,s);if(i===void 0)continue;let o=s.startPosition.row,a=s.endPosition.row,c=Bo(s,i,o,a);r.push(c)}return r}function $o(e,t,n){let r=L(n,"string");if(!r)return;let s=L(r,"string_fragment");if(s)return J(e,t,s.text)}function Bo(e,t,n,r){let s=L(e,"export_clause");if(s){let o=[];for(let a of s.namedChildren){if(a.type!=="export_specifier")continue;let c=a.namedChild(0),l=a.namedChild(1);c&&o.push((l??c).text)}return{kind:"named",sourcePath:t,names:o,startLine:n,endLine:r}}let i=L(e,"namespace_export");if(i){let o=i.namedChildren.find(a=>a.type==="identifier"||a.type==="type_identifier")?.text;return{kind:"star-as",sourcePath:t,names:o?[o]:[],startLine:n,endLine:r}}return{kind:"star",sourcePath:t,names:[],startLine:n,endLine:r}}function ir(e,t,n){return Ze(e,t,{java:r=>Vo(e,t,r),kotlin:r=>Wo(e,t,r),scala:r=>Uo(e,t,r)},()=>D(n,/^[ \t]*import\s+(?:static\s+)?(.+?)\s*;?$/gm,(r,s)=>{let i=r[1]?.trim();return i?Ho(e,t,i,s):[]}),n)}function Vo(e,t,n){let r=y(n,new Set(["import_declaration"])),s=[];for(let i of n.rootNode.descendantsOfType("import_declaration")){let o=i.children.some(p=>p.type==="asterisk"),c=i.namedChildren.find(p=>p.type==="scoped_identifier")??i.namedChildren.find(p=>p.type==="identifier");if(!c)continue;let l=c.text;if(o){s.push(ce("*",g(e,l,P)));continue}let u=l.split(".").pop()??l;s.push(m(u,u,g(e,l,P),r))}return s}function Wo(e,t,n){let r=y(n,new Set(["import_header","import_list"])),s=[];for(let i of n.rootNode.descendantsOfType("import_header")){let o=i.namedChildren.find(f=>f.type==="identifier");if(!o)continue;let a=i.namedChildren.some(f=>f.type==="wildcard_import"),c=i.namedChildren.find(f=>f.type==="import_alias");if(a){s.push(ce("*",g(e,o.text,P)));continue}let l=o.text,u=l.split(".").pop()??l,d=c?.namedChild(0)?.text??u;s.push(m(u,d,g(e,l,P),r))}return s}function Uo(e,t,n){let r=y(n,new Set(["import_declaration"])),s=[];for(let i of n.rootNode.descendantsOfType("import_declaration")){let o=i.namedChildren.find(p=>p.type==="namespace_selectors"||p.type==="namespace_wildcard"),a=i.namedChildren.filter(p=>p!==o&&(p.type==="identifier"||p.type==="stable_identifier")),c=a.map(p=>p.text).join(".");if(!c)continue;if(o?.type==="namespace_wildcard"){s.push(ce("*",g(e,c,P)));continue}if(o?.type==="namespace_selectors"){for(let p of o.namedChildren)if(p.type==="arrow_renamed_identifier"){let[d,f]=p.namedChildren;if(!d)continue;let x=d.text,le=f?.text??x;if(x==="_")continue;s.push(m(x,le,g(e,`${c}.${x}`,P),r))}else if(p.type==="identifier"){let d=p.text;s.push(m(d,d,g(e,`${c}.${d}`,P),r))}continue}let l=a[a.length-1]?.text??c,u=a.slice(0,-1).map(p=>p.text).join(".")||c;s.push(m(l,l,g(e,u&&a.length>1?`${u}.${l}`:c,P),r))}return s}function Ho(e,t,n,r){if(n.includes("{")&&n.includes("}")){let s=n.slice(0,n.indexOf("{")).replace(/\.$/,"").trim(),i=n.slice(n.indexOf("{")+1,n.lastIndexOf("}")).trim();return E(i).flatMap(o=>{let a=o.trim();if(!a)return[];let[c,l]=a.includes("=>")?a.split(/\s*=>\s*/):a.split(/\s+as\s+/),u=c?.trim();if(!u||u==="_")return[];let p=(l??u.split(".").pop()??u).trim(),d=u==="_"?s:`${s}.${u}`.replace(/\.\./g,".");return[w(e,t,r,d,u,p)]})}return[w(e,t,r,n,n.split(".").pop()??n,n.split(".").pop()??n)]}function ar(e,t,n){return R(e,t,r=>zo(e,t,r),()=>D(n,/^[ \t]*use\s+(.+?)\s*;$/gm,(r,s)=>{let i=r[1]?.trim();return i?E(i).flatMap(o=>{let a=o.trim();if(!a)return[];let[c,l]=a.split(/\s+as\s+/i),u=c?.trim()??a,p=u.split("\\").pop()??u,d=(l??p).trim();return[w(e,t,s,u,p,d,g(e,u.replace(/\\/g,"."),oe))]}):[]}),n)}function zo(e,t,n){let r=y(n,new Set(["namespace_use_declaration"])),s=[],i=(o,a,c)=>{s.push(m(a,c,g(e,o.replace(/\\/g,"."),oe),r))};for(let o of n.rootNode.descendantsOfType("namespace_use_declaration")){let a=o.namedChildren.find(c=>c.type==="namespace_use_group");if(a){let c=o.namedChildren.find(l=>l.type==="namespace_name")?.text??"";for(let l of a.namedChildren){if(l.type!=="namespace_use_clause")continue;let{importedName:u,localName:p,qualified:d}=or(l,c);u&&i(d,u,p)}continue}for(let c of o.namedChildren){if(c.type!=="namespace_use_clause")continue;let{importedName:l,localName:u,qualified:p}=or(c,"");l&&i(p,l,u)}}return s}function or(e,t){let n=e.namedChildren.find(l=>l.type==="qualified_name"),r=e.namedChildren.filter(l=>l.type==="name"),s="";n?s=n.text:r.length>=1&&(s=r[0].text);let i=n&&r.length>0?r[r.length-1]:null,o=s.split("\\").pop()??s,a=i?.text??o,c=t?`${t}\\${s}`:s;return{importedName:o,localName:a,qualified:c}}function lr(e,t,n){return R(e,t,r=>qo(e,t,r),()=>Jo(n).flatMap(r=>Xo(e,t,r,n)),n)}function qo(e,t,n){let r=y(n,new Set(["import_statement","import_from_statement"])),s=[];for(let i of n.rootNode.descendantsOfType("import_statement"))for(let o of i.namedChildren){let a=cr(o);if(!a)continue;let c=Se(e,t,a.qualifiedName);s.push({importedName:a.qualifiedName,localName:a.localName,sourcePath:c,kind:"namespace",used:r.has(a.localName),usedMembers:[]})}for(let i of n.rootNode.descendantsOfType("import_from_statement")){let o=i.namedChild(0);if(!o)continue;let a=Qo(o);if(a===null)continue;let c=Se(e,t,a);for(let l=1;l<i.namedChildCount;l+=1){let u=i.namedChild(l);if(u.type==="wildcard_import"){s.push({importedName:"*",localName:null,sourcePath:c,kind:"side-effect",used:!0,usedMembers:[]});continue}let p=cr(u);p&&s.push({importedName:p.qualifiedName,localName:p.localName,sourcePath:c,kind:"named",used:r.has(p.localName),usedMembers:[]})}}return s}function cr(e){if(e.type==="aliased_import"){let t=e.namedChild(0),n=e.namedChild(1);return!t||!n?null:{qualifiedName:t.text,localName:n.text}}if(e.type==="dotted_name"){let t=e.text;return{qualifiedName:t,localName:t.split(".")[0]??t}}return e.type==="identifier"?{qualifiedName:e.text,localName:e.text}:null}function Qo(e){if(e.type==="dotted_name")return e.text;if(e.type==="relative_import"){let t=L(e,"import_prefix")?.text??"",n=L(e,"dotted_name")?.text??"";return`${t}${n}`}return null}function Jo(e){let t=e.split(`
17
- `),n=[],r=0;for(let s=0;s<t.length;s++){let i=t[s],o=i.trimStart(),a=r;if(r+=i.length+1,!o.startsWith("import ")&&!o.startsWith("from "))continue;let c=i,l=a+i.length,u=wt(i);for(;s+1<t.length&&(u>0||c.trimEnd().endsWith("\\"));){s++;let d=t[s];c+=`
18
- ${d}`,l+=1+d.length,u+=wt(d),r+=d.length+1}let p=Ko(c);p&&n.push({...p,start:a,end:l})}return n}function Ko(e){let t=e.replace(/\\\s*\n/g," ").trim();if(t.startsWith("import "))return{kind:"import",module:null,clause:t.slice(7).trim()};let n=t.match(/^from\s+([.\w]+)\s+import\s+([\s\S]+)$/);if(!n)return null;let r=n[2].trim();return r.startsWith("(")&&r.endsWith(")")&&(r=r.slice(1,-1).trim()),{kind:"from",module:n[1],clause:r}}function Xo(e,t,n,r){let s=X(r,n.start,n.end),i=n.clause.replace(/\n/g," ").trim();if(n.kind==="import")return E(i).flatMap(c=>{let l=c.trim().replace(/,$/,"");if(!l)return[];let[u,p]=l.split(/\s+as\s+/),d=u.trim(),f=(p??d.split(".")[0]??d).trim(),x=Se(e,t,d),le=xe(s,f);return[{importedName:d,localName:f,sourcePath:x,kind:"namespace",used:C(s,f)||le.length>0,usedMembers:le}]});let o=n.module?Se(e,t,n.module):null,a=[];for(let c of E(i)){let l=c.trim().replace(/,$/,"");if(!l)continue;if(l==="*"){a.push({importedName:"*",localName:null,sourcePath:o,kind:"side-effect",used:!0,usedMembers:[]});continue}let[u,p]=l.split(/\s+as\s+/),d=(p??u).trim();a.push({importedName:u.trim(),localName:d,sourcePath:o,kind:"named",used:C(s,d),usedMembers:[]})}return a}import{basename as Go}from"path";function ur(e,t,n){return R(e,t,r=>Zo(e,t,r),()=>Yo(e,t,n),n)}function Yo(e,t,n){return D(n,/^[ \t]*(require_relative|require)\s+["']([^"']+)["']\s*$/gm,(r,s)=>{let i=r[1],o=r[2];if(!i||!o)return[];let a=i==="require_relative"?Ke(e,t,o):null;if(a){let c=pr(o);return[H(c,c,a,C(s,c))]}return[ae(o,a)]})}function Zo(e,t,n){let r=y(n,new Set([])),s=[],i=new Set(["require","require_relative","load"]);for(let o of n.rootNode.descendantsOfType("call")){let a=o.namedChild(0);if(!a||a.type!=="identifier"||!i.has(a.text))continue;let l=o.namedChildren.find(f=>f.type==="argument_list")?.namedChild(0);if(!l||l.type!=="string")continue;let p=l.namedChildren.find(f=>f.type==="string_content")?.text;if(!p)continue;let d=a.text==="require_relative"?Ke(e,t,p):null;if(d){let f=pr(p);s.push(m(f,f,d,r))}else s.push(ae(p,d))}return s}function pr(e){return Bn(Go(e).replace(/\.[^.]+$/,""),/_/)}function dr(e,t,n){return R(e,t,r=>ea(e,t,r),()=>D(n,/^[ \t]*use\s+(.+?)\s*;$/gm,(r,s)=>{let i=r[1]?.trim();return i?ta(e,t,i,s):[]}),n)}function ea(e,t,n){let r=y(n,new Set(["use_declaration"])),s=[];for(let i of n.rootNode.descendantsOfType("use_declaration")){let o=i.namedChild(0);if(o)for(let a of Fe(o,"")){if(!a.importedName||a.importedName==="*")continue;let c=W(e,t,a.qualifiedName)??W(e,t,a.qualifiedName.split("::").slice(0,-1).join("::"));s.push(m(a.importedName,a.localName,c,r))}}return s}function Fe(e,t){switch(e.type){case"identifier":case"super":case"crate":{let n=e.text;return[{qualifiedName:nt(t,n),importedName:n,localName:n}]}case"self":{let n=t.split("::").filter(Boolean).pop()??"self";return[{qualifiedName:t||"self",importedName:n,localName:n}]}case"scoped_identifier":{let n=e.text,r=n.split("::").pop()??n;return[{qualifiedName:nt(t,n),importedName:r,localName:r}]}case"scoped_use_list":{let n=e.namedChild(0),r=e.namedChild(1);if(!n||!r)return[];let s=nt(t,n.text),i=[];for(let o of r.namedChildren)i.push(...Fe(o,s));return i}case"use_list":{let n=[];for(let r of e.namedChildren)n.push(...Fe(r,t));return n}case"use_as_clause":{let n=e.namedChild(0),r=e.namedChild(1);if(!n||!r)return[];let s=Fe(n,t),i=r.text;return s.map(o=>({...o,localName:i}))}case"use_wildcard":{let n=e.namedChild(0),r=n?n.text:"";return[{qualifiedName:nt(t,`${r}::*`),importedName:"*",localName:"*"}]}default:return[]}}function nt(e,t){return e?t?`${e}::${t}`:e:t}function ta(e,t,n,r){let s=n.trim();if(s.includes("{")&&s.includes("}")){let u=s.slice(0,s.indexOf("{")).replace(/::$/,"").trim(),p=s.slice(s.indexOf("{")+1,s.lastIndexOf("}")).trim();return E(p).flatMap(d=>{let f=d.trim();if(!f)return[];if(f==="self"){let ot=u.split("::").filter(Boolean).pop();return ot?[w(e,t,r,u,ot,ot)]:[]}let[x,le]=f.split(/\s+as\s+/),ue=x?.trim();if(!ue)return[];let Dr=(le??ue.split("::").pop()??ue).trim(),Rr=`${u}::${ue}`.replace(/::::/g,"::");return[w(e,t,r,Rr,ue.split("::").pop()??ue,Dr,W(e,t,u))]})}let[i,o]=s.split(/\s+as\s+/),a=i?.trim()??s,c=(o??a.split("::").pop()??a).trim(),l=W(e,t,a)??W(e,t,a.split("::").slice(0,-1).join("::"));return[w(e,t,r,a,a.split("::").pop()??a,c,l)]}function fr(e,t,n){let r=$(e,t);if(r)return na(e,t,r);let s=[];for(let i of n.matchAll(/^[ \t]*pub\s+use\s+(.+?)\s*;$/gm)){let o=i[1]?.trim();o&&s.push(...sa(e,t,o))}return s}function na(e,t,n){let r=[];for(let s of n.rootNode.descendantsOfType("use_declaration")){if(!ra(s))continue;let i=s.namedChildren.find(o=>o.type!=="visibility_modifier");if(i)for(let o of Fe(i,""))o.importedName&&r.push(Wt(e,t,o.qualifiedName))}return r}function ra(e){for(let t of e.children)if(t.type==="visibility_modifier"&&t.text.startsWith("pub"))return!0;return!1}function sa(e,t,n){let r=n.trim();if(r.includes("{")&&r.includes("}")){let s=r.slice(0,r.indexOf("{")).replace(/::$/,"").trim(),i=r.slice(r.indexOf("{")+1,r.lastIndexOf("}")).trim();return E(i).flatMap(o=>{let a=o.trim();if(!a||a==="self")return[];let[c]=a.split(/\s+as\s+/),l=`${s}::${c?.trim()??a}`.replace(/::::/g,"::");return[Wt(e,t,l)]})}return[Wt(e,t,r)]}function Wt(e,t,n){return{specifier:n,sourcePath:W(e,t,n)??W(e,t,n.split("::").slice(0,-1).join("::"))}}function G({language:e,extensions:t,imports:n,parseImports:r}){return{language:e,extensions:t,capabilities:{imports:n},parseImports:r}}function mr(e,t){let n=t.toLowerCase();for(let r of e)for(let s of r.extensions)if(n.endsWith(s))return r;return null}var ia={language:"javascript",extensions:se,capabilities:{imports:"ast-with-regex-fallback",reExports:"ast-with-regex-fallback"},parseImports:Bt,parseReExports:Vt},oa=G({language:"python",extensions:He,imports:"ast-with-regex-fallback",parseImports:lr}),aa=G({language:"jvm",extensions:P,imports:"ast-dispatch-with-regex-fallback",parseImports:ir}),ca={language:"rust",extensions:ze,capabilities:{imports:"ast-with-regex-fallback",exports:"ast-with-regex-fallback"},parseImports:dr,parseExports:fr},la=G({language:"ruby",extensions:qe,imports:"ast-with-regex-fallback",parseImports:ur}),ua=G({language:"c/cpp",extensions:Qe,imports:"ast-with-regex-fallback",parseImports:Gn}),pa=G({language:"dotnet",extensions:Q,imports:"ast-dispatch-with-regex-fallback",parseImports:nr}),da={language:"dart",extensions:Je,capabilities:{imports:"regex-only",exports:"regex-only"},parseImports:er,parseExports:tr},fa=G({language:"php",extensions:oe,imports:"ast-with-regex-fallback",parseImports:ar}),ma=G({language:"clojure",extensions:he,imports:"regex-only",parseImports:Zn}),ga=[ia,oa,aa,ca,la,ua,pa,da,fa,ma];function rt(e){return mr(ga,e)}var Ut={clearGroups:["whole-project","source-file"]},ya=N("source-imports",Ut),bp=N("source-exports",Ut),ha=N("source-reexports",Ut),gr=Y({kind:"source-imports",invalidation:Z("source-imports"),serialize:Sa,deserialize:xa}),yr=Y({kind:"source-reexports",invalidation:Z("source-reexports"),serialize:ba,deserialize:Na});function hr(e,t){let n=b(t);return ha.get(e,n,()=>{let r=rt(n);if(!r?.parseReExports)return[];let s=I(e,n);if(!s)return[];let i=z(e,n,s),o=vt(e),a=yr.read(e,n,i);if(a?.resolutionFingerprint===o)return a.reExports;let c=r.parseReExports(e,n,s);return yr.write(e,n,i,{resolutionFingerprint:o,reExports:c}),c})}function Ht(e,t){let n=b(t);return ya.get(e,n,()=>{let r=rt(n);if(!r)return[];let s=I(e,n);return s?Sr(e,n,s,r):[]})}function Np(e,t){let n=b(t),r=rt(n);if(!r)return[];let s;try{s=Re(e.config.projectRoot,n,{inputKind:"indexed source file"})}catch(i){if(ve(i))return[];throw i}return Sr(e,n,s,r)}function Sr(e,t,n,r){let s=z(e,t,n),i=vt(e),o=gr.read(e,t,s);if(o?.resolutionFingerprint===i)return o.imports;let a=r.parseImports(e,t,n);return gr.write(e,t,s,{parserVersion:2,resolutionFingerprint:i,imports:a}),a}function Ip(e,t,n){let r=Ht(e,t).filter(s=>s.kind==="named"&&s.isTypeOnly!==!0&&s.localName===n&&s.sourcePath!==null);return r.length===1?r[0]:null}function Sa(e){return JSON.stringify(e)}function xa(e){try{let t=JSON.parse(e);return!fe(t)||t.parserVersion!==2||typeof t.resolutionFingerprint!="string"||!Array.isArray(t.imports)?null:{parserVersion:2,resolutionFingerprint:t.resolutionFingerprint,imports:t.imports}}catch{return null}}function ba(e){return JSON.stringify(e)}function Na(e){try{let t=JSON.parse(e);return!fe(t)||typeof t.resolutionFingerprint!="string"||!Array.isArray(t.reExports)?null:{resolutionFingerprint:t.resolutionFingerprint,reExports:t.reExports}}catch{return null}}function Cp(e,t){return e.all(`SELECT gs.id, gs.symbol, der.document_id, der.start_line, der.start_char, der.end_line, der.end_char, d.relative_path, gs.display_name, gs.documentation
19
- FROM global_symbols gs
20
- JOIN defn_enclosing_ranges der ON gs.id = der.symbol_id
21
- JOIN documents d ON der.document_id = d.id
22
- WHERE ${t.where}
23
- ${e.pathExclusionsFor("d")}
24
- ${br(t.orderBy)}
25
- ${Nr(t.limit)}`,...t.params??[])}function Ep(e,t){return e.all(`SELECT
26
- gs.id,
27
- gs.symbol,
28
- c.document_id,
29
- MIN(c.start_line) AS start_line,
30
- 0 AS start_char,
31
- MAX(c.end_line) AS end_line,
32
- 0 AS end_char,
33
- d.relative_path,
34
- gs.display_name,
35
- gs.documentation
36
- FROM global_symbols gs
37
- JOIN mentions m ON m.symbol_id = gs.id
38
- JOIN chunks c ON m.chunk_id = c.id
39
- JOIN documents d ON c.document_id = d.id
40
- WHERE m.role = 1
41
- AND ${t.where}
42
- ${e.pathExclusionsFor("d")}
43
- GROUP BY gs.id, gs.symbol, c.document_id, d.relative_path, gs.display_name, gs.documentation
44
- ${br(t.orderBy)}
45
- ${Nr(t.limit)}`,...t.params??[])}function br(e){return e?`ORDER BY ${e}`:""}function Nr(e){return typeof e=="number"?`LIMIT ${e}`:""}function Ir(e){return!e||!e.trim()?null:e.replace(/^```\w*\s*/,"").replace(/\s*```$/,"").replace(/^\(method\)\s*/,"").replace(/^\(property\)\s*/,"").replace(/^\(function\)\s*/,"").replace(/^\(class\)\s*/,"").replace(/^\(interface\)\s*/,"").replace(/^\(enum\)\s*/,"").replace(/^\(type alias\)\s*/,"").replace(/^\(const\)\s*/,"").replace(/^\(var\)\s*/,"").trim()||null}function _r(e){if(!e)return null;let t=xr(e);if(t)return t.replace(/\n/g," ");let n=e.indexOf("|");if(n===-1)return e.replace(/\n/g," ");let r=e.slice(n+1);return(xr(r)??r).replace(/\n/g," ")}function xr(e){return/^```(?:\w+)?\s*\n?([\s\S]*?)\n?```/.exec(e.trimStart())?.[1]?.trim()||null}function st(e){return{forFile(t,n){return Cr(e,t,n)},forFiles(t,n){let r=new Map;for(let s of t)r.set(s,Cr(e,s,n));return r}}}function Cr(e,t,n){let r={file:t},s=n.facts||n.identifiers;if(n.text&&(r.text=I(e,t)),n.lines&&(r.lines=pt(e,t)),n.ast&&(r.ast=$(e,t)),n.imports&&(r.imports=Ht(e,t)),n.reexports&&(r.reexports=hr(e,t)),s){let i=xt(e,t),o=i.facts;n.facts&&(r.facts=o),i.unavailable&&(r.sourceFactsUnavailable=i.unavailable),n.identifiers&&o&&(r.identifiers=o.fileIdentifiers,r.identifierLineMap=o.identifierLineMap)}return r}function Ia(e,t={}){if(q(e.symbol)!==null)return t.includeClassMemberFallbacks===!0;let s=(e.documentation??"").replace(/^```\w*\s*/,"").replace(/\s*```$/,"").trim();return/^(?:var|let|const|function|class|interface|type|enum)\b/.test(s)}function zt(e,t,n={}){let r=new Map;for(let i of t)e.length>0&&!Ia(i,{includeClassMemberFallbacks:n.includeClassMemberFallbacks})||r.set(i.id,i);for(let i of e)r.set(i.id,i);let s=[...r.values()];return n.sort?s.sort((i,o)=>i.start_line-o.start_line||i.end_line-o.end_line||i.symbol.localeCompare(o.symbol)):s}var _a=N("file-definitions",{clearGroups:["definition-catalog"]}),Ca=pe("scoped-matched-definitions",{clearGroups:["definition-catalog"]}),Ea=N("file-function-like-definitions",{clearGroups:["definition-catalog"]}),Er=new WeakMap;function Qt(e,t,n={},r){return _e(t),n.includeClassMemberFallbacks?qt(e,t,void 0,{includeClassMemberFallbacks:!0},r):_a.get(e,t,()=>{let s=j(r,"evidence-read",()=>Tr(e,t));if(s)return s;let i=qt(e,t,void 0,n,r);return j(r,"evidence-write",()=>{let o=Ne(e),a=st(e).forFile(t,{text:!0}).text;o&&a&&Lr.write(e,t,z(e,t,a),{projectFingerprint:o,definitions:i.map(c=>({...c}))})}),i})}function ka(e,t){return Ea.get(e,t,()=>{let n=Tr(e,t);return n?n.filter(r=>r.isFunctionLike):qt(e,t,r=>r.isFunctionLike)})}var Lr=Y({kind:"file-definitions",invalidation:Z("file-definitions"),serialize:Pa,deserialize:La});function Tr(e,t){let n=Ne(e);if(!n)return null;let r=st(e).forFile(t,{text:!0}).text;if(!r)return null;let s=Lr.read(e,t,z(e,t,r));return s?Ta(s,n,t):null}function Pa(e){return JSON.stringify(e)}function La(e){try{let t=JSON.parse(e);return!fe(t)||typeof t.projectFingerprint!="string"||!Array.isArray(t.definitions)?null:{projectFingerprint:t.projectFingerprint,definitions:t.definitions}}catch{return null}}function Ta(e,t,n){if(e.projectFingerprint!==t)return null;let r=[];for(let s of e.definitions){let i=Fa(s,n);if(!i)return null;r.push(i)}return r}function Fa(e,t){return!fe(e)||typeof e.symbolId!="number"||typeof e.symbol!="string"||typeof e.documentId!="number"||typeof e.startLine!="number"||typeof e.startChar!="number"&&e.startChar!==void 0||typeof e.endLine!="number"||typeof e.endChar!="number"&&e.endChar!==void 0||e.relativePath!==t||typeof e.leaf!="string"||typeof e.parentTypeName!="string"&&e.parentTypeName!==null||typeof e.isFunctionLike!="boolean"||typeof e.isTypeLike!="boolean"||typeof e.kind!="number"&&e.kind!==null||typeof e.documentation!="string"&&e.documentation!==null||typeof e.enclosingSymbol!="string"&&e.enclosingSymbol!==null?null:{symbolId:e.symbolId,symbol:e.symbol,documentId:e.documentId,startLine:e.startLine,startChar:e.startChar,endLine:e.endLine,endChar:e.endChar,relativePath:e.relativePath,leaf:e.leaf,parentTypeName:e.parentTypeName,isFunctionLike:e.isFunctionLike,isTypeLike:e.isTypeLike,kind:e.kind,documentation:e.documentation,enclosingSymbol:e.enclosingSymbol}}function qt(e,t,n,r={},s){let i=j(s,"primary-rows",()=>Da(e,t)),o=j(s,"fallback-rows",()=>Ra(e,t)),a=j(s,"merge-rows",()=>zt(i,o,{sort:!0,includeClassMemberFallbacks:r.includeClassMemberFallbacks}).map(Jt));return n&&(a=a.filter(n)),j(s,"range-correction",()=>Kt(e,t,a,s,r.rangeCorrectionEvidence))}function j(e,t,n){return e?e(t,n):n()}function Da(e,t){return e.all(`SELECT
46
- gs.id,
47
- gs.symbol,
48
- der.document_id,
49
- der.start_line,
50
- der.start_char,
51
- der.end_line,
52
- der.end_char,
53
- d.relative_path,
54
- gs.display_name,
55
- gs.kind,
56
- gs.documentation,
57
- gs.enclosing_symbol
58
- FROM global_symbols gs
59
- JOIN defn_enclosing_ranges der ON gs.id = der.symbol_id
60
- JOIN documents d ON der.document_id = d.id
61
- WHERE d.relative_path = ?
62
- ${e.symbolNoiseFor("gs")}
63
- ORDER BY der.start_line, der.end_line`,t)}function Ra(e,t){return e.all(`SELECT
64
- gs.id,
65
- gs.symbol,
66
- c.document_id,
67
- MIN(c.start_line) AS start_line,
68
- 0 AS start_char,
69
- MAX(c.end_line) AS end_line,
70
- 0 AS end_char,
71
- d.relative_path,
72
- gs.display_name,
73
- gs.kind,
74
- gs.documentation,
75
- gs.enclosing_symbol
76
- FROM global_symbols gs
77
- JOIN mentions m ON m.symbol_id = gs.id
78
- JOIN chunks c ON m.chunk_id = c.id
79
- JOIN documents d ON c.document_id = d.id
80
- WHERE d.relative_path = ?
81
- AND m.role = 1
82
- ${e.symbolNoiseFor("gs")}
83
- GROUP BY gs.id, gs.symbol, c.document_id, d.relative_path
84
- ORDER BY start_line, end_line`,t)}function Jt(e){return{symbolId:e.id,symbol:e.symbol,documentId:e.document_id,startLine:e.start_line,startChar:e.start_char??0,endLine:e.end_line,endChar:e.end_char??0,relativePath:e.relative_path,leaf:on(e.symbol),parentTypeName:q(e.symbol),isFunctionLike:ut(e.symbol),isTypeLike:we(e.symbol)==="type",kind:e.kind??null,documentation:e.documentation??null,enclosingSymbol:e.enclosing_symbol??null}}function Qp(e,t={}){return va(e,t.scope)}function va(e,t){return Ie(e,{scope:t,includeIgnored:!1}).flatMap(n=>Qt(e,n)).filter(n=>!e.isIgnored(n.relativePath))}function Jp(e,t){return Ie(e,{scope:t,includeIgnored:!1}).flatMap(n=>ka(e,n)).filter(n=>!e.isIgnored(n.relativePath))}function Kp(e,t){let n=Ca.get(e,()=>new WeakMap),r=n.get(t.symbolMatches);r||(r=new Map,n.set(t.symbolMatches,r));let s=JSON.stringify({scope:t.scope??null,sqlPrefilter:t.sqlPrefilter??null}),i=r.get(s);if(i)return[...i];let o=kr(wa(e,t.scope,t.sqlPrefilter)),a=kr(Aa(e,t.scope,t.sqlPrefilter)),c=new Set([...o.keys(),...a.keys()]),l=[];for(let u of[...c].sort()){if(e.isIgnored(u))continue;let p=zt(o.get(u)??[],a.get(u)??[],{sort:!0}).filter(d=>t.symbolMatches(d.symbol));p.length!==0&&l.push(...Kt(e,u,p.map(Jt)))}return r.set(s,l),[...l]}function wa(e,t,n){let r=t?"AND d.relative_path LIKE ?":"",s=n?`AND ${Fr("gs",n)}`:"",i=t?[`%${t}%`]:[];return e.all(`SELECT
85
- gs.id,
86
- gs.symbol,
87
- der.document_id,
88
- der.start_line,
89
- der.start_char,
90
- der.end_line,
91
- der.end_char,
92
- d.relative_path,
93
- gs.display_name,
94
- gs.kind,
95
- gs.documentation,
96
- gs.enclosing_symbol
97
- FROM global_symbols gs
98
- JOIN defn_enclosing_ranges der ON gs.id = der.symbol_id
99
- JOIN documents d ON der.document_id = d.id
100
- WHERE 1 = 1
101
- ${e.pathExclusionsFor("d")}
102
- ${r}
103
- ${s}
104
- ${e.symbolNoiseFor("gs")}
105
- ORDER BY d.relative_path, der.start_line, der.end_line`,...i)}function Aa(e,t,n){let r=t?"AND d.relative_path LIKE ?":"",s=n?`AND ${Fr("gs",n)}`:"",i=t?[`%${t}%`]:[];return e.all(`SELECT
106
- gs.id,
107
- gs.symbol,
108
- c.document_id,
109
- MIN(c.start_line) AS start_line,
110
- 0 AS start_char,
111
- MAX(c.end_line) AS end_line,
112
- 0 AS end_char,
113
- d.relative_path,
114
- gs.display_name,
115
- gs.kind,
116
- gs.documentation,
117
- gs.enclosing_symbol
118
- FROM global_symbols gs
119
- JOIN mentions m ON m.symbol_id = gs.id
120
- JOIN chunks c ON m.chunk_id = c.id
121
- JOIN documents d ON c.document_id = d.id
122
- WHERE m.role = 1
123
- AND NOT EXISTS (
124
- SELECT 1
125
- FROM defn_enclosing_ranges existing_der
126
- WHERE existing_der.symbol_id = gs.id
127
- )
128
- ${e.pathExclusionsFor("d")}
129
- ${r}
130
- ${s}
131
- ${e.symbolNoiseFor("gs")}
132
- GROUP BY gs.id, gs.symbol, c.document_id, d.relative_path
133
- ORDER BY d.relative_path, start_line, end_line`,...i)}function ja(e){return`(${e}.symbol LIKE '%().' OR ${e}.symbol LIKE '%()')`}function Fr(e,t){return t==="callable"?ja(e):Oa(e)}function Oa(e){return`(${e}.symbol LIKE '%.' OR ${e}.symbol LIKE '%()')`}function kr(e){let t=new Map;for(let n of e){let r=t.get(n.relative_path);r?r.push(n):t.set(n.relative_path,[n])}return t}function Xp(e,t,n={}){if(t.length===0)return[];let r=t.flatMap(s=>Qt(e,s)).filter(s=>!e.isIgnored(s.relativePath));return n.onlyDocumented&&(r=r.filter(s=>s.documentation!==null&&s.documentation!=="")),n.sort&&(r=r.sort((s,i)=>s.relativePath.localeCompare(i.relativePath)||s.startLine-i.startLine||s.endLine-i.endLine)),r.map(s=>({startLine:s.startLine,endLine:s.endLine,symbol:s.symbol,shortName:sn(s.symbol),signature:Ir(_r(s.documentation)),relativePath:s.relativePath,enclosingSymbol:s.enclosingSymbol}))}function Ma(e){let t=new Map,n=e.map((r,s)=>({definition:r,index:s,span:r.endLine-r.startLine})).sort((r,s)=>r.span-s.span||r.index-s.index);for(let{definition:r}of n)for(let s=r.startLine;s<=r.endLine;s+=1)t.has(s)||t.set(s,r);return t}function Gp(e,t){let n=Er.get(e);return n||(n=Ma(e),Er.set(e,n)),n.get(t)??null}function Yp(e,t){let n=Qt(e,t.relative_path).find(r=>r.symbolId===t.id)??(q(t.symbol)===null||!ut(t.symbol)?void 0:Kt(e,t.relative_path,[Jt(t)])[0]);return n?{symbolId:n.symbolId,symbol:n.symbol,documentId:n.documentId,startLine:n.startLine,startChar:n.startChar,endLine:n.endLine,endChar:n.endChar,relativePath:n.relativePath}:{symbolId:t.id,symbol:t.symbol,documentId:t.document_id,startLine:t.start_line,startChar:t.start_char??0,endLine:t.end_line,endChar:t.end_char??0,relativePath:t.relative_path}}function Kt(e,t,n,r,s){let i=j(r,"range-correction.source-text",()=>s?s.source:st(e).forFile(t,{text:!0}).text),o=j(r,"range-correction.callable-sites",()=>s?s.callables:It(e,t));return o?j(r,"range-correction.ast-correction",()=>Ha(n,o,i)):i?j(r,"range-correction.regex-fallback",()=>$a(n,i)):n}function $a(e,t){let n=t.split(/\r?\n/),r=Ba(e,n),s=Va(e,r),i=Wa(s,n);return Ua(e,i)}function Ba(e,t){let n=e.some(s=>it(s.symbol))?Ga(t):null,r=new Map;for(let s of e)r.set(s.symbolId,Xa(t,n,s));return r}function Va(e,t){return e.filter(n=>it(n.symbol)).map(n=>({definition:n,startLine:t.get(n.symbolId)??n.startLine})).sort((n,r)=>n.startLine-r.startLine||n.definition.startLine-r.definition.startLine||n.definition.symbol.localeCompare(r.definition.symbol))}function Wa(e,t){let n=new Map;for(let r=0;r<e.length;r+=1){let s=e[r],i=e[r+1],o=i?Math.max(s.startLine,i.startLine-1):t.length-1;n.set(s.definition.symbolId,{startLine:s.startLine,endLine:Ya(t,s.definition,s.startLine,o)})}return n}function Ua(e,t){return e.map(n=>{let r=t.get(n.symbolId);return r?{...n,startLine:r.startLine,endLine:r.endLine}:n})}function Ha(e,t,n=null){let r=new Map;for(let s of t){let i=r.get(s.name);i?i.push(s):r.set(s.name,[s])}return e.map(s=>{if(!Ka(s)||!s.leaf)return Pr(s,n);let i=r.get(s.leaf);if(!i||i.length===0)return Pr(s,n);let o=n?za(s,i,n):null;if(o)return{...s,startLine:o.startLine,endLine:o.endLine};let a=i[0],c=Math.abs(a.startLine-s.startLine);for(let l=1;l<i.length;l+=1){let u=i[l],p=Math.abs(u.startLine-s.startLine);p<c&&(a=u,c=p)}return{...s,startLine:a.startLine,endLine:a.endLine}})}function za(e,t,n){let r=qa(e.symbol);if(!r)return null;let s=n.split(/\r?\n/),i=new RegExp(`\\b${A(r)}\\b`);for(let o of t){let a=Qa(s,o.startLine);if(a&&i.test(a))return o}return null}function qa(e){return e.match(/\/impl#\[([^\]]+)\]/)?.[1]??null}function Qa(e,t){for(let n=t;n>=0;n-=1){let r=e[n]?.trim()??"";if(r){if(/^impl\b/.test(r))return Ja(e,n,t);if(/^(?:struct|enum|trait|mod)\b/.test(r))return null}}return null}function Ja(e,t,n){let r=[];for(let s=t;s<=n;s+=1){let i=e[s]??"";if(r.push(i),i.includes("{"))break}return r.join(" ")}function Ka(e){return it(e.symbol)?!0:we(e.symbol)==="term"&&q(e.symbol)===null}function Pr(e,t){if(!t||!e.leaf||we(e.symbol)!=="term"||q(e.symbol)!==null)return e;let n=A(e.leaf),r=new RegExp(`\\b(?:export\\s+)?(?:const|let|var)\\s+${n}\\b`),i=t.split(/\r?\n/).findIndex(o=>r.test(o));return i>=0?{...e,startLine:i,endLine:i}:e}function Xa(e,t,n){if(!it(n.symbol))return n.startLine;let r=Math.max(0,Math.min(n.startLine,e.length-1));if(!t)return r;let s=t.get(n.leaf);if(!s||s.length===0)return r;let i=null;for(let o of s){let a=Math.abs(o-n.startLine);(!i||a<i.distance)&&(i={line:o,distance:a})}return i?.line??r}function Ga(e){let t=/\b(?:function|def|fn)\s+([A-Za-z_$][\w$]*)/g,n=/\b([A-Za-z_$][\w$]*)\s*[:=]\s*(?:async\s*)?(?:function\b|\()/g,r=/^\s*(?:(?:export|public|private|protected|static|readonly|async|abstract|get|set)\s+)*([A-Za-z_$][\w$]*)\s*(?:<[^(]*>)?\s*\(/,s=/\b([A-Za-z_$][\w$]*)\s*\(/g,i=new Map,o=(a,c)=>{let l=i.get(a);if(!l){i.set(a,[c]);return}l[l.length-1]!==c&&l.push(c)};for(let a=0;a<e.length;a+=1){let c=e[a]??"";for(let u of c.matchAll(t))u[1]&&o(u[1],a);for(let u of c.matchAll(n))u[1]&&o(u[1],a);let l=c.match(r);l?.[1]&&o(l[1],a);for(let u of c.matchAll(s))u[1]&&o(u[1],a)}return i}function Ya(e,t,n,r){let s=Math.max(n,Math.min(e.length-1,r)),i=Math.max(n,Math.min(s,t.endLine)),o=0,a=0,c=!1;for(let l=n;l<=s;l+=1){let u=Za(e[l]??"");for(let p of u)p==="{"?(o+=1,c=!0):p==="}"?o=Math.max(0,o-1):p==="("?a+=1:p===")"&&(a=Math.max(0,a-1));if(c&&o===0||!c&&a===0&&l>=i)return l}return i}function Za(e){let t="",n=null,r=!1;for(let s=0;s<e.length;s+=1){let i=e[s],o=e[s+1];if(!n&&i==="/"&&o==="/"){t+=" ".repeat(e.length-s);break}if(n){if(r){r=!1,t+=" ";continue}if(i==="\\"){r=!0,t+=" ";continue}i===n&&(n=null),t+=" ";continue}if(i==='"'||i==="'"||i==="`"){n=i,t+=" ";continue}t+=i}return t}function it(e){return e.includes("().")}export{Y as a,mc as b,Z as c,Vn as d,oi as e,J as f,ec as g,I as h,Ar as i,ic as j,pt as k,oc as l,A as m,Qi as n,O as o,M as p,Ws as q,On as r,qs as s,Mn as t,Qs as u,Nt as v,Js as w,$ as x,Ac as y,ne as z,$c as A,ge as B,It as C,Xs as D,Gs as E,qi as F,nt as G,hr as H,Ht as I,Np as J,Ip as K,st as L,Cp as M,Ep as N,Ir as O,_r as P,zt as Q,Qt as R,Qp as S,va as T,Jp as U,Kp as V,Xp as W,Ma as X,Gp as Y,Yp as Z};
134
- //# sourceMappingURL=chunk-C7IJMOFP.js.map
@@ -1,2 +0,0 @@
1
- import{a as h}from"./chunk-C76O5MDS.js";import{c as y,d as x}from"./chunk-QWKHW6VZ.js";import{D as b}from"./chunk-WN3TCGJ4.js";import{a as S}from"./chunk-NRBNAECH.js";import{M as g,h as m}from"./chunk-AK3PYTIK.js";import{existsSync as E,statSync as V}from"fs";import{join as j}from"path";import{existsSync as O,readdirSync as w}from"fs";import{createHash as D}from"crypto";import{join as f}from"path";function l(t){let r=0,e=0,n=0,o=0,i=0,a=[];for(let s of t)switch(s.state){case"legacy":r+=1;break;case"current":e+=1;break;case"unsupported-older":n+=1,a.push(u(s));break;case"unsupported-future":o+=1,a.push(u(s));break;case"malformed":i+=1,a.push(u(s));break}let c=r+e,d=n+o+i;return{complete:d===0,total:t.length,accepted:c,legacy:r,current:e,unsupportedOlder:n,unsupportedFuture:o,malformed:i,omitted:d,issues:a}}function u(t){if(t.state==="legacy"||t.state==="current")throw new Error(`accepted record ${t.path} cannot become a compatibility issue`);return{path:t.path,state:t.state,reason:t.reason??t.state}}var F=f(".scipquery","suppressions"),C="scip-query-suppression",P=1,p=2;function _(t){return f(t,F)}function v(t){if(t.id&&t.id.trim()!=="")return`${t.id.trim()}.json`;let r=`${t.check??""}\0${t.file??""}`;return`CHECK-${D("sha256").update(r).digest("hex").slice(0,12).toUpperCase()}.json`}function A(t){return v(t).slice(0,-5)}function $(t,r){if(typeof t!="object"||t===null||Array.isArray(t))return{state:"malformed",error:"not a suppression object"};let e=t;if(e.schemaVersion===void 0&&(e.kind!==void 0||e.suppressionIdentity!==void 0||e.writer!==void 0))return{state:"malformed",error:"suppression envelope metadata requires schemaVersion"};if(e.schemaVersion!==void 0){if(!Number.isSafeInteger(e.schemaVersion))return{state:"malformed",error:"schemaVersion must be a positive safe integer"};if(e.schemaVersion!==P&&e.schemaVersion!==p)return{state:e.schemaVersion>p?"unsupported-future":"unsupported-older",error:`unsupported schemaVersion ${String(e.schemaVersion)}`};if(e.kind!==void 0&&e.kind!==C)return{state:"malformed",error:`kind must be ${C}`}}if(e.schemaVersion===P&&e.decision!==void 0)return{state:"malformed",error:"schemaVersion 1 cannot carry automated adjudication metadata"};if(e.schemaVersion===p&&!y(e.decision))return{state:"malformed",error:"schemaVersion 2 requires a valid automated adjudication decision"};if(typeof e.reason!="string"||e.reason.trim()==="")return{state:"malformed",error:"missing reason"};if(!e.id&&!e.check)return{state:"malformed",error:"needs an id or a check"};let n=N(e);if(e.schemaVersion===void 0)return{state:"legacy",suppression:n,record:e,schemaVersion:0};let o=A(n);return e.suppressionIdentity!==o||r!==void 0&&e.suppressionIdentity!==r?{state:"malformed",error:"suppressionIdentity does not match the suppression target or filename"}:!e.writer||e.writer.tool!=="scip-query"||typeof e.writer.version!="string"||e.writer.version.trim()===""?{state:"malformed",error:"missing valid writer metadata"}:typeof e.createdAt!="string"||!Number.isFinite(Date.parse(e.createdAt))?{state:"malformed",error:"missing valid createdAt timestamp"}:e.updatedAt!==void 0&&(typeof e.updatedAt!="string"||!Number.isFinite(Date.parse(e.updatedAt)))?{state:"malformed",error:"invalid updatedAt timestamp"}:{state:e.schemaVersion===p?"current":"legacy",suppression:n,record:e,schemaVersion:e.schemaVersion}}function R(t){let r=_(t);if(!O(r))return{suppressions:[],compatibility:l([]),warnings:[]};let e=[],n=[];for(let i of w(r).sort()){if(!i.endsWith(".json"))continue;let a=f(r,i),c=`${F}/${i}`,d;try{d=JSON.parse(m(a,"suppression record"))}catch{n.push({path:c,state:"malformed",reason:"malformed JSON"});continue}let s=$(d,i.slice(0,-5));if("error"in s){n.push({path:c,state:s.state,reason:s.error});continue}n.push({path:c,state:s.state}),e.push(s.suppression)}let o=l(n);return{suppressions:e,compatibility:o,warnings:o.issues.map(i=>`${i.path}: ${i.reason} \u2014 ignored`)}}function N(t){return{...typeof t.id=="string"?{id:t.id}:{},...typeof t.check=="string"?{check:t.check}:{},...typeof t.file=="string"?{file:t.file}:{},reason:t.reason,...typeof t.expiresAt=="string"?{expiresAt:t.expiresAt}:{},...typeof t.createdAt=="string"?{createdAt:t.createdAt}:{},...t.decision?{decision:t.decision}:{}}}function W(){return process.env.SCIP_QUERY_PROJECT_ROOT??process.cwd()}var I;function G(t=W(),r=void 0){if(r===void 0&&I?.projectRoot===t)return I;let e=x(t),n=g(t,e),o=process.env.SCIP_QUERY_INDEX_DB;if(o)return{projectRoot:t,config:e,paths:n,dbPath:o,dbPathSource:"env",gitContext:r};if(E(n.dbPath))return{projectRoot:t,config:e,paths:n,dbPath:n.dbPath,dbPathSource:"configured",gitContext:r};let i=j(t,"index.db");return{projectRoot:t,config:e,paths:n,dbPath:i,dbPathSource:"root-fallback",rootFallbackWarning:U(i,n.dbPath),gitContext:r}}function oe(t,r={}){let{config:e,paths:n,dbPath:o,dbPathSource:i,rootFallbackWarning:a,gitContext:c}=G(t);if(!E(o))throw new Error("No index.db found. Run: scip-query reindex");r.warnOnRootFallback&&i==="root-fallback"&&a&&console.error(a);let d=R(t).suppressions,s={dbPath:o,indexPath:process.env.SCIP_QUERY_INDEX_SCIP??n.indexPath,projectRoot:t,collaborationDomainId:e.collaborationDomainId,sharedEvidenceDbPath:b(t,e,c),entryRoots:e.entryRoots,semantic:e.semantic,suppressions:[...e.suppressions??[],...d],declaredCouplings:e.declaredCouplings,locality:e.locality,architecture:e.architecture,coverageContracts:e.coverageContracts,docs:e.docs},k=S(t);return new h(s,k)}function U(t,r){let e="unknown time";try{e=V(t).mtime.toISOString()}catch{}return`warning: using legacy project-root index.db (${t}, modified ${e}) because the configured index was not found at ${r}. This fallback may be stale; run 'scip-query reindex' to refresh the configured index.`}export{oe as a};
2
- //# sourceMappingURL=chunk-CBBHFNLX.js.map