@colbymchenry/codegraph-darwin-arm64 0.9.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 (569) hide show
  1. package/bin/codegraph +3 -0
  2. package/lib/dist/bin/codegraph.d.ts +21 -0
  3. package/lib/dist/bin/codegraph.d.ts.map +1 -0
  4. package/lib/dist/bin/codegraph.js +1273 -0
  5. package/lib/dist/bin/codegraph.js.map +1 -0
  6. package/lib/dist/bin/node-version-check.d.ts +37 -0
  7. package/lib/dist/bin/node-version-check.d.ts.map +1 -0
  8. package/lib/dist/bin/node-version-check.js +79 -0
  9. package/lib/dist/bin/node-version-check.js.map +1 -0
  10. package/lib/dist/bin/uninstall.d.ts +14 -0
  11. package/lib/dist/bin/uninstall.d.ts.map +1 -0
  12. package/lib/dist/bin/uninstall.js +36 -0
  13. package/lib/dist/bin/uninstall.js.map +1 -0
  14. package/lib/dist/config.d.ts +51 -0
  15. package/lib/dist/config.d.ts.map +1 -0
  16. package/lib/dist/config.js +321 -0
  17. package/lib/dist/config.js.map +1 -0
  18. package/lib/dist/context/formatter.d.ts +30 -0
  19. package/lib/dist/context/formatter.d.ts.map +1 -0
  20. package/lib/dist/context/formatter.js +244 -0
  21. package/lib/dist/context/formatter.js.map +1 -0
  22. package/lib/dist/context/index.d.ts +97 -0
  23. package/lib/dist/context/index.d.ts.map +1 -0
  24. package/lib/dist/context/index.js +1050 -0
  25. package/lib/dist/context/index.js.map +1 -0
  26. package/lib/dist/db/index.d.ts +83 -0
  27. package/lib/dist/db/index.d.ts.map +1 -0
  28. package/lib/dist/db/index.js +219 -0
  29. package/lib/dist/db/index.js.map +1 -0
  30. package/lib/dist/db/migrations.d.ts +44 -0
  31. package/lib/dist/db/migrations.d.ts.map +1 -0
  32. package/lib/dist/db/migrations.js +131 -0
  33. package/lib/dist/db/migrations.js.map +1 -0
  34. package/lib/dist/db/queries.d.ts +253 -0
  35. package/lib/dist/db/queries.d.ts.map +1 -0
  36. package/lib/dist/db/queries.js +1207 -0
  37. package/lib/dist/db/queries.js.map +1 -0
  38. package/lib/dist/db/schema.sql +151 -0
  39. package/lib/dist/db/sqlite-adapter.d.ts +46 -0
  40. package/lib/dist/db/sqlite-adapter.d.ts.map +1 -0
  41. package/lib/dist/db/sqlite-adapter.js +114 -0
  42. package/lib/dist/db/sqlite-adapter.js.map +1 -0
  43. package/lib/dist/directory.d.ts +57 -0
  44. package/lib/dist/directory.d.ts.map +1 -0
  45. package/lib/dist/directory.js +264 -0
  46. package/lib/dist/directory.js.map +1 -0
  47. package/lib/dist/errors.d.ts +136 -0
  48. package/lib/dist/errors.d.ts.map +1 -0
  49. package/lib/dist/errors.js +219 -0
  50. package/lib/dist/errors.js.map +1 -0
  51. package/lib/dist/extraction/dfm-extractor.d.ts +31 -0
  52. package/lib/dist/extraction/dfm-extractor.d.ts.map +1 -0
  53. package/lib/dist/extraction/dfm-extractor.js +151 -0
  54. package/lib/dist/extraction/dfm-extractor.js.map +1 -0
  55. package/lib/dist/extraction/grammars.d.ts +78 -0
  56. package/lib/dist/extraction/grammars.d.ts.map +1 -0
  57. package/lib/dist/extraction/grammars.js +332 -0
  58. package/lib/dist/extraction/grammars.js.map +1 -0
  59. package/lib/dist/extraction/index.d.ts +130 -0
  60. package/lib/dist/extraction/index.d.ts.map +1 -0
  61. package/lib/dist/extraction/index.js +1305 -0
  62. package/lib/dist/extraction/index.js.map +1 -0
  63. package/lib/dist/extraction/languages/c-cpp.d.ts +4 -0
  64. package/lib/dist/extraction/languages/c-cpp.d.ts.map +1 -0
  65. package/lib/dist/extraction/languages/c-cpp.js +126 -0
  66. package/lib/dist/extraction/languages/c-cpp.js.map +1 -0
  67. package/lib/dist/extraction/languages/csharp.d.ts +3 -0
  68. package/lib/dist/extraction/languages/csharp.d.ts.map +1 -0
  69. package/lib/dist/extraction/languages/csharp.js +72 -0
  70. package/lib/dist/extraction/languages/csharp.js.map +1 -0
  71. package/lib/dist/extraction/languages/dart.d.ts +3 -0
  72. package/lib/dist/extraction/languages/dart.d.ts.map +1 -0
  73. package/lib/dist/extraction/languages/dart.js +192 -0
  74. package/lib/dist/extraction/languages/dart.js.map +1 -0
  75. package/lib/dist/extraction/languages/go.d.ts +3 -0
  76. package/lib/dist/extraction/languages/go.d.ts.map +1 -0
  77. package/lib/dist/extraction/languages/go.js +58 -0
  78. package/lib/dist/extraction/languages/go.js.map +1 -0
  79. package/lib/dist/extraction/languages/index.d.ts +10 -0
  80. package/lib/dist/extraction/languages/index.d.ts.map +1 -0
  81. package/lib/dist/extraction/languages/index.js +49 -0
  82. package/lib/dist/extraction/languages/index.js.map +1 -0
  83. package/lib/dist/extraction/languages/java.d.ts +3 -0
  84. package/lib/dist/extraction/languages/java.d.ts.map +1 -0
  85. package/lib/dist/extraction/languages/java.js +64 -0
  86. package/lib/dist/extraction/languages/java.js.map +1 -0
  87. package/lib/dist/extraction/languages/javascript.d.ts +3 -0
  88. package/lib/dist/extraction/languages/javascript.d.ts.map +1 -0
  89. package/lib/dist/extraction/languages/javascript.js +90 -0
  90. package/lib/dist/extraction/languages/javascript.js.map +1 -0
  91. package/lib/dist/extraction/languages/kotlin.d.ts +3 -0
  92. package/lib/dist/extraction/languages/kotlin.d.ts.map +1 -0
  93. package/lib/dist/extraction/languages/kotlin.js +253 -0
  94. package/lib/dist/extraction/languages/kotlin.js.map +1 -0
  95. package/lib/dist/extraction/languages/lua.d.ts +3 -0
  96. package/lib/dist/extraction/languages/lua.d.ts.map +1 -0
  97. package/lib/dist/extraction/languages/lua.js +150 -0
  98. package/lib/dist/extraction/languages/lua.js.map +1 -0
  99. package/lib/dist/extraction/languages/luau.d.ts +3 -0
  100. package/lib/dist/extraction/languages/luau.d.ts.map +1 -0
  101. package/lib/dist/extraction/languages/luau.js +37 -0
  102. package/lib/dist/extraction/languages/luau.js.map +1 -0
  103. package/lib/dist/extraction/languages/pascal.d.ts +3 -0
  104. package/lib/dist/extraction/languages/pascal.d.ts.map +1 -0
  105. package/lib/dist/extraction/languages/pascal.js +66 -0
  106. package/lib/dist/extraction/languages/pascal.js.map +1 -0
  107. package/lib/dist/extraction/languages/php.d.ts +3 -0
  108. package/lib/dist/extraction/languages/php.d.ts.map +1 -0
  109. package/lib/dist/extraction/languages/php.js +107 -0
  110. package/lib/dist/extraction/languages/php.js.map +1 -0
  111. package/lib/dist/extraction/languages/python.d.ts +3 -0
  112. package/lib/dist/extraction/languages/python.d.ts.map +1 -0
  113. package/lib/dist/extraction/languages/python.js +56 -0
  114. package/lib/dist/extraction/languages/python.js.map +1 -0
  115. package/lib/dist/extraction/languages/ruby.d.ts +3 -0
  116. package/lib/dist/extraction/languages/ruby.d.ts.map +1 -0
  117. package/lib/dist/extraction/languages/ruby.js +114 -0
  118. package/lib/dist/extraction/languages/ruby.js.map +1 -0
  119. package/lib/dist/extraction/languages/rust.d.ts +3 -0
  120. package/lib/dist/extraction/languages/rust.d.ts.map +1 -0
  121. package/lib/dist/extraction/languages/rust.js +109 -0
  122. package/lib/dist/extraction/languages/rust.js.map +1 -0
  123. package/lib/dist/extraction/languages/scala.d.ts +3 -0
  124. package/lib/dist/extraction/languages/scala.d.ts.map +1 -0
  125. package/lib/dist/extraction/languages/scala.js +139 -0
  126. package/lib/dist/extraction/languages/scala.js.map +1 -0
  127. package/lib/dist/extraction/languages/swift.d.ts +3 -0
  128. package/lib/dist/extraction/languages/swift.d.ts.map +1 -0
  129. package/lib/dist/extraction/languages/swift.js +91 -0
  130. package/lib/dist/extraction/languages/swift.js.map +1 -0
  131. package/lib/dist/extraction/languages/typescript.d.ts +3 -0
  132. package/lib/dist/extraction/languages/typescript.d.ts.map +1 -0
  133. package/lib/dist/extraction/languages/typescript.js +129 -0
  134. package/lib/dist/extraction/languages/typescript.js.map +1 -0
  135. package/lib/dist/extraction/liquid-extractor.d.ts +52 -0
  136. package/lib/dist/extraction/liquid-extractor.d.ts.map +1 -0
  137. package/lib/dist/extraction/liquid-extractor.js +313 -0
  138. package/lib/dist/extraction/liquid-extractor.js.map +1 -0
  139. package/lib/dist/extraction/parse-worker.d.ts +8 -0
  140. package/lib/dist/extraction/parse-worker.d.ts.map +1 -0
  141. package/lib/dist/extraction/parse-worker.js +94 -0
  142. package/lib/dist/extraction/parse-worker.js.map +1 -0
  143. package/lib/dist/extraction/svelte-extractor.d.ts +56 -0
  144. package/lib/dist/extraction/svelte-extractor.d.ts.map +1 -0
  145. package/lib/dist/extraction/svelte-extractor.js +272 -0
  146. package/lib/dist/extraction/svelte-extractor.js.map +1 -0
  147. package/lib/dist/extraction/tree-sitter-helpers.d.ts +28 -0
  148. package/lib/dist/extraction/tree-sitter-helpers.d.ts.map +1 -0
  149. package/lib/dist/extraction/tree-sitter-helpers.js +103 -0
  150. package/lib/dist/extraction/tree-sitter-helpers.js.map +1 -0
  151. package/lib/dist/extraction/tree-sitter-types.d.ts +179 -0
  152. package/lib/dist/extraction/tree-sitter-types.d.ts.map +1 -0
  153. package/lib/dist/extraction/tree-sitter-types.js +10 -0
  154. package/lib/dist/extraction/tree-sitter-types.js.map +1 -0
  155. package/lib/dist/extraction/tree-sitter.d.ts +233 -0
  156. package/lib/dist/extraction/tree-sitter.d.ts.map +1 -0
  157. package/lib/dist/extraction/tree-sitter.js +2425 -0
  158. package/lib/dist/extraction/tree-sitter.js.map +1 -0
  159. package/lib/dist/extraction/vue-extractor.d.ts +36 -0
  160. package/lib/dist/extraction/vue-extractor.d.ts.map +1 -0
  161. package/lib/dist/extraction/vue-extractor.js +163 -0
  162. package/lib/dist/extraction/vue-extractor.js.map +1 -0
  163. package/lib/dist/extraction/wasm/tree-sitter-lua.wasm +0 -0
  164. package/lib/dist/extraction/wasm/tree-sitter-luau.wasm +0 -0
  165. package/lib/dist/extraction/wasm/tree-sitter-pascal.wasm +0 -0
  166. package/lib/dist/extraction/wasm/tree-sitter-scala.wasm +0 -0
  167. package/lib/dist/graph/index.d.ts +8 -0
  168. package/lib/dist/graph/index.d.ts.map +1 -0
  169. package/lib/dist/graph/index.js +13 -0
  170. package/lib/dist/graph/index.js.map +1 -0
  171. package/lib/dist/graph/queries.d.ts +106 -0
  172. package/lib/dist/graph/queries.d.ts.map +1 -0
  173. package/lib/dist/graph/queries.js +366 -0
  174. package/lib/dist/graph/queries.js.map +1 -0
  175. package/lib/dist/graph/traversal.d.ts +127 -0
  176. package/lib/dist/graph/traversal.d.ts.map +1 -0
  177. package/lib/dist/graph/traversal.js +493 -0
  178. package/lib/dist/graph/traversal.js.map +1 -0
  179. package/lib/dist/index.d.ts +453 -0
  180. package/lib/dist/index.d.ts.map +1 -0
  181. package/lib/dist/index.js +833 -0
  182. package/lib/dist/index.js.map +1 -0
  183. package/lib/dist/installer/claude-md-template.d.ts +14 -0
  184. package/lib/dist/installer/claude-md-template.d.ts.map +1 -0
  185. package/lib/dist/installer/claude-md-template.js +21 -0
  186. package/lib/dist/installer/claude-md-template.js.map +1 -0
  187. package/lib/dist/installer/config-writer.d.ts +29 -0
  188. package/lib/dist/installer/config-writer.d.ts.map +1 -0
  189. package/lib/dist/installer/config-writer.js +111 -0
  190. package/lib/dist/installer/config-writer.js.map +1 -0
  191. package/lib/dist/installer/index.d.ts +65 -0
  192. package/lib/dist/installer/index.d.ts.map +1 -0
  193. package/lib/dist/installer/index.js +406 -0
  194. package/lib/dist/installer/index.js.map +1 -0
  195. package/lib/dist/installer/instructions-template.d.ts +28 -0
  196. package/lib/dist/installer/instructions-template.d.ts.map +1 -0
  197. package/lib/dist/installer/instructions-template.js +64 -0
  198. package/lib/dist/installer/instructions-template.js.map +1 -0
  199. package/lib/dist/installer/targets/claude.d.ts +47 -0
  200. package/lib/dist/installer/targets/claude.d.ts.map +1 -0
  201. package/lib/dist/installer/targets/claude.js +401 -0
  202. package/lib/dist/installer/targets/claude.js.map +1 -0
  203. package/lib/dist/installer/targets/codex.d.ts +18 -0
  204. package/lib/dist/installer/targets/codex.d.ts.map +1 -0
  205. package/lib/dist/installer/targets/codex.js +185 -0
  206. package/lib/dist/installer/targets/codex.js.map +1 -0
  207. package/lib/dist/installer/targets/cursor.d.ts +35 -0
  208. package/lib/dist/installer/targets/cursor.d.ts.map +1 -0
  209. package/lib/dist/installer/targets/cursor.js +229 -0
  210. package/lib/dist/installer/targets/cursor.js.map +1 -0
  211. package/lib/dist/installer/targets/opencode.d.ts +30 -0
  212. package/lib/dist/installer/targets/opencode.d.ts.map +1 -0
  213. package/lib/dist/installer/targets/opencode.js +235 -0
  214. package/lib/dist/installer/targets/opencode.js.map +1 -0
  215. package/lib/dist/installer/targets/registry.d.ts +35 -0
  216. package/lib/dist/installer/targets/registry.d.ts.map +1 -0
  217. package/lib/dist/installer/targets/registry.js +83 -0
  218. package/lib/dist/installer/targets/registry.js.map +1 -0
  219. package/lib/dist/installer/targets/shared.d.ts +77 -0
  220. package/lib/dist/installer/targets/shared.d.ts.map +1 -0
  221. package/lib/dist/installer/targets/shared.js +246 -0
  222. package/lib/dist/installer/targets/shared.js.map +1 -0
  223. package/lib/dist/installer/targets/toml.d.ts +52 -0
  224. package/lib/dist/installer/targets/toml.d.ts.map +1 -0
  225. package/lib/dist/installer/targets/toml.js +147 -0
  226. package/lib/dist/installer/targets/toml.js.map +1 -0
  227. package/lib/dist/installer/targets/types.d.ts +116 -0
  228. package/lib/dist/installer/targets/types.d.ts.map +1 -0
  229. package/lib/dist/installer/targets/types.js +16 -0
  230. package/lib/dist/installer/targets/types.js.map +1 -0
  231. package/lib/dist/mcp/index.d.ts +94 -0
  232. package/lib/dist/mcp/index.d.ts.map +1 -0
  233. package/lib/dist/mcp/index.js +453 -0
  234. package/lib/dist/mcp/index.js.map +1 -0
  235. package/lib/dist/mcp/server-instructions.d.ts +19 -0
  236. package/lib/dist/mcp/server-instructions.d.ts.map +1 -0
  237. package/lib/dist/mcp/server-instructions.js +71 -0
  238. package/lib/dist/mcp/server-instructions.js.map +1 -0
  239. package/lib/dist/mcp/tools.d.ts +257 -0
  240. package/lib/dist/mcp/tools.d.ts.map +1 -0
  241. package/lib/dist/mcp/tools.js +1646 -0
  242. package/lib/dist/mcp/tools.js.map +1 -0
  243. package/lib/dist/mcp/transport.d.ts +106 -0
  244. package/lib/dist/mcp/transport.d.ts.map +1 -0
  245. package/lib/dist/mcp/transport.js +233 -0
  246. package/lib/dist/mcp/transport.js.map +1 -0
  247. package/lib/dist/resolution/frameworks/cargo-workspace.d.ts +18 -0
  248. package/lib/dist/resolution/frameworks/cargo-workspace.d.ts.map +1 -0
  249. package/lib/dist/resolution/frameworks/cargo-workspace.js +225 -0
  250. package/lib/dist/resolution/frameworks/cargo-workspace.js.map +1 -0
  251. package/lib/dist/resolution/frameworks/csharp.d.ts +8 -0
  252. package/lib/dist/resolution/frameworks/csharp.d.ts.map +1 -0
  253. package/lib/dist/resolution/frameworks/csharp.js +213 -0
  254. package/lib/dist/resolution/frameworks/csharp.js.map +1 -0
  255. package/lib/dist/resolution/frameworks/express.d.ts +8 -0
  256. package/lib/dist/resolution/frameworks/express.d.ts.map +1 -0
  257. package/lib/dist/resolution/frameworks/express.js +225 -0
  258. package/lib/dist/resolution/frameworks/express.js.map +1 -0
  259. package/lib/dist/resolution/frameworks/go.d.ts +8 -0
  260. package/lib/dist/resolution/frameworks/go.d.ts.map +1 -0
  261. package/lib/dist/resolution/frameworks/go.js +158 -0
  262. package/lib/dist/resolution/frameworks/go.js.map +1 -0
  263. package/lib/dist/resolution/frameworks/index.d.ts +42 -0
  264. package/lib/dist/resolution/frameworks/index.d.ts.map +1 -0
  265. package/lib/dist/resolution/frameworks/index.js +133 -0
  266. package/lib/dist/resolution/frameworks/index.js.map +1 -0
  267. package/lib/dist/resolution/frameworks/java.d.ts +8 -0
  268. package/lib/dist/resolution/frameworks/java.d.ts.map +1 -0
  269. package/lib/dist/resolution/frameworks/java.js +177 -0
  270. package/lib/dist/resolution/frameworks/java.js.map +1 -0
  271. package/lib/dist/resolution/frameworks/laravel.d.ts +13 -0
  272. package/lib/dist/resolution/frameworks/laravel.d.ts.map +1 -0
  273. package/lib/dist/resolution/frameworks/laravel.js +248 -0
  274. package/lib/dist/resolution/frameworks/laravel.js.map +1 -0
  275. package/lib/dist/resolution/frameworks/nestjs.d.ts +26 -0
  276. package/lib/dist/resolution/frameworks/nestjs.d.ts.map +1 -0
  277. package/lib/dist/resolution/frameworks/nestjs.js +374 -0
  278. package/lib/dist/resolution/frameworks/nestjs.js.map +1 -0
  279. package/lib/dist/resolution/frameworks/python.d.ts +10 -0
  280. package/lib/dist/resolution/frameworks/python.d.ts.map +1 -0
  281. package/lib/dist/resolution/frameworks/python.js +278 -0
  282. package/lib/dist/resolution/frameworks/python.js.map +1 -0
  283. package/lib/dist/resolution/frameworks/react.d.ts +8 -0
  284. package/lib/dist/resolution/frameworks/react.d.ts.map +1 -0
  285. package/lib/dist/resolution/frameworks/react.js +272 -0
  286. package/lib/dist/resolution/frameworks/react.js.map +1 -0
  287. package/lib/dist/resolution/frameworks/ruby.d.ts +8 -0
  288. package/lib/dist/resolution/frameworks/ruby.d.ts.map +1 -0
  289. package/lib/dist/resolution/frameworks/ruby.js +198 -0
  290. package/lib/dist/resolution/frameworks/ruby.js.map +1 -0
  291. package/lib/dist/resolution/frameworks/rust.d.ts +8 -0
  292. package/lib/dist/resolution/frameworks/rust.d.ts.map +1 -0
  293. package/lib/dist/resolution/frameworks/rust.js +207 -0
  294. package/lib/dist/resolution/frameworks/rust.js.map +1 -0
  295. package/lib/dist/resolution/frameworks/svelte.d.ts +9 -0
  296. package/lib/dist/resolution/frameworks/svelte.d.ts.map +1 -0
  297. package/lib/dist/resolution/frameworks/svelte.js +249 -0
  298. package/lib/dist/resolution/frameworks/svelte.js.map +1 -0
  299. package/lib/dist/resolution/frameworks/swift.d.ts +10 -0
  300. package/lib/dist/resolution/frameworks/swift.d.ts.map +1 -0
  301. package/lib/dist/resolution/frameworks/swift.js +376 -0
  302. package/lib/dist/resolution/frameworks/swift.js.map +1 -0
  303. package/lib/dist/resolution/frameworks/vue.d.ts +9 -0
  304. package/lib/dist/resolution/frameworks/vue.d.ts.map +1 -0
  305. package/lib/dist/resolution/frameworks/vue.js +306 -0
  306. package/lib/dist/resolution/frameworks/vue.js.map +1 -0
  307. package/lib/dist/resolution/import-resolver.d.ts +40 -0
  308. package/lib/dist/resolution/import-resolver.d.ts.map +1 -0
  309. package/lib/dist/resolution/import-resolver.js +663 -0
  310. package/lib/dist/resolution/import-resolver.js.map +1 -0
  311. package/lib/dist/resolution/index.d.ts +106 -0
  312. package/lib/dist/resolution/index.d.ts.map +1 -0
  313. package/lib/dist/resolution/index.js +709 -0
  314. package/lib/dist/resolution/index.js.map +1 -0
  315. package/lib/dist/resolution/name-matcher.d.ts +32 -0
  316. package/lib/dist/resolution/name-matcher.d.ts.map +1 -0
  317. package/lib/dist/resolution/name-matcher.js +384 -0
  318. package/lib/dist/resolution/name-matcher.js.map +1 -0
  319. package/lib/dist/resolution/path-aliases.d.ts +68 -0
  320. package/lib/dist/resolution/path-aliases.d.ts.map +1 -0
  321. package/lib/dist/resolution/path-aliases.js +238 -0
  322. package/lib/dist/resolution/path-aliases.js.map +1 -0
  323. package/lib/dist/resolution/strip-comments.d.ts +27 -0
  324. package/lib/dist/resolution/strip-comments.d.ts.map +1 -0
  325. package/lib/dist/resolution/strip-comments.js +441 -0
  326. package/lib/dist/resolution/strip-comments.js.map +1 -0
  327. package/lib/dist/resolution/types.d.ts +172 -0
  328. package/lib/dist/resolution/types.d.ts.map +1 -0
  329. package/lib/dist/resolution/types.js +8 -0
  330. package/lib/dist/resolution/types.js.map +1 -0
  331. package/lib/dist/search/query-parser.d.ts +57 -0
  332. package/lib/dist/search/query-parser.d.ts.map +1 -0
  333. package/lib/dist/search/query-parser.js +177 -0
  334. package/lib/dist/search/query-parser.js.map +1 -0
  335. package/lib/dist/search/query-utils.d.ts +53 -0
  336. package/lib/dist/search/query-utils.d.ts.map +1 -0
  337. package/lib/dist/search/query-utils.js +350 -0
  338. package/lib/dist/search/query-utils.js.map +1 -0
  339. package/lib/dist/sync/git-hooks.d.ts +45 -0
  340. package/lib/dist/sync/git-hooks.d.ts.map +1 -0
  341. package/lib/dist/sync/git-hooks.js +223 -0
  342. package/lib/dist/sync/git-hooks.js.map +1 -0
  343. package/lib/dist/sync/index.d.ts +17 -0
  344. package/lib/dist/sync/index.d.ts.map +1 -0
  345. package/lib/dist/sync/index.js +28 -0
  346. package/lib/dist/sync/index.js.map +1 -0
  347. package/lib/dist/sync/watch-policy.d.ts +48 -0
  348. package/lib/dist/sync/watch-policy.d.ts.map +1 -0
  349. package/lib/dist/sync/watch-policy.js +124 -0
  350. package/lib/dist/sync/watch-policy.js.map +1 -0
  351. package/lib/dist/sync/watcher.d.ts +81 -0
  352. package/lib/dist/sync/watcher.d.ts.map +1 -0
  353. package/lib/dist/sync/watcher.js +194 -0
  354. package/lib/dist/sync/watcher.js.map +1 -0
  355. package/lib/dist/types.d.ts +423 -0
  356. package/lib/dist/types.d.ts.map +1 -0
  357. package/lib/dist/types.js +262 -0
  358. package/lib/dist/types.js.map +1 -0
  359. package/lib/dist/ui/glyphs.d.ts +42 -0
  360. package/lib/dist/ui/glyphs.d.ts.map +1 -0
  361. package/lib/dist/ui/glyphs.js +78 -0
  362. package/lib/dist/ui/glyphs.js.map +1 -0
  363. package/lib/dist/ui/shimmer-progress.d.ts +11 -0
  364. package/lib/dist/ui/shimmer-progress.d.ts.map +1 -0
  365. package/lib/dist/ui/shimmer-progress.js +90 -0
  366. package/lib/dist/ui/shimmer-progress.js.map +1 -0
  367. package/lib/dist/ui/shimmer-worker.d.ts +2 -0
  368. package/lib/dist/ui/shimmer-worker.d.ts.map +1 -0
  369. package/lib/dist/ui/shimmer-worker.js +118 -0
  370. package/lib/dist/ui/shimmer-worker.js.map +1 -0
  371. package/lib/dist/ui/types.d.ts +17 -0
  372. package/lib/dist/ui/types.d.ts.map +1 -0
  373. package/lib/dist/ui/types.js +3 -0
  374. package/lib/dist/ui/types.js.map +1 -0
  375. package/lib/dist/utils.d.ts +205 -0
  376. package/lib/dist/utils.d.ts.map +1 -0
  377. package/lib/dist/utils.js +549 -0
  378. package/lib/dist/utils.js.map +1 -0
  379. package/lib/node_modules/.package-lock.json +116 -0
  380. package/lib/node_modules/@clack/core/CHANGELOG.md +348 -0
  381. package/lib/node_modules/@clack/core/LICENSE +9 -0
  382. package/lib/node_modules/@clack/core/README.md +22 -0
  383. package/lib/node_modules/@clack/core/dist/index.d.mts +363 -0
  384. package/lib/node_modules/@clack/core/dist/index.mjs +17 -0
  385. package/lib/node_modules/@clack/core/dist/index.mjs.map +1 -0
  386. package/lib/node_modules/@clack/core/package.json +63 -0
  387. package/lib/node_modules/@clack/prompts/CHANGELOG.md +591 -0
  388. package/lib/node_modules/@clack/prompts/LICENSE +9 -0
  389. package/lib/node_modules/@clack/prompts/README.md +375 -0
  390. package/lib/node_modules/@clack/prompts/dist/index.d.mts +396 -0
  391. package/lib/node_modules/@clack/prompts/dist/index.mjs +144 -0
  392. package/lib/node_modules/@clack/prompts/dist/index.mjs.map +1 -0
  393. package/lib/node_modules/@clack/prompts/package.json +68 -0
  394. package/lib/node_modules/commander/LICENSE +22 -0
  395. package/lib/node_modules/commander/Readme.md +1176 -0
  396. package/lib/node_modules/commander/esm.mjs +16 -0
  397. package/lib/node_modules/commander/index.js +24 -0
  398. package/lib/node_modules/commander/lib/argument.js +150 -0
  399. package/lib/node_modules/commander/lib/command.js +2777 -0
  400. package/lib/node_modules/commander/lib/error.js +39 -0
  401. package/lib/node_modules/commander/lib/help.js +747 -0
  402. package/lib/node_modules/commander/lib/option.js +380 -0
  403. package/lib/node_modules/commander/lib/suggestSimilar.js +101 -0
  404. package/lib/node_modules/commander/package-support.json +19 -0
  405. package/lib/node_modules/commander/package.json +82 -0
  406. package/lib/node_modules/commander/typings/esm.d.mts +3 -0
  407. package/lib/node_modules/commander/typings/index.d.ts +1113 -0
  408. package/lib/node_modules/fast-string-truncated-width/dist/index.d.ts +4 -0
  409. package/lib/node_modules/fast-string-truncated-width/dist/index.js +111 -0
  410. package/lib/node_modules/fast-string-truncated-width/dist/types.d.ts +19 -0
  411. package/lib/node_modules/fast-string-truncated-width/dist/types.js +2 -0
  412. package/lib/node_modules/fast-string-truncated-width/dist/utils.d.ts +4 -0
  413. package/lib/node_modules/fast-string-truncated-width/dist/utils.js +20 -0
  414. package/lib/node_modules/fast-string-truncated-width/license +21 -0
  415. package/lib/node_modules/fast-string-truncated-width/package.json +35 -0
  416. package/lib/node_modules/fast-string-truncated-width/readme.md +59 -0
  417. package/lib/node_modules/fast-string-width/dist/index.d.ts +4 -0
  418. package/lib/node_modules/fast-string-width/dist/index.js +14 -0
  419. package/lib/node_modules/fast-string-width/license +21 -0
  420. package/lib/node_modules/fast-string-width/package.json +34 -0
  421. package/lib/node_modules/fast-string-width/readme.md +42 -0
  422. package/lib/node_modules/fast-wrap-ansi/LICENSE +23 -0
  423. package/lib/node_modules/fast-wrap-ansi/README.md +26 -0
  424. package/lib/node_modules/fast-wrap-ansi/lib/main.d.ts +6 -0
  425. package/lib/node_modules/fast-wrap-ansi/lib/main.js +219 -0
  426. package/lib/node_modules/fast-wrap-ansi/lib/main.js.map +1 -0
  427. package/lib/node_modules/fast-wrap-ansi/package.json +51 -0
  428. package/lib/node_modules/jsonc-parser/CHANGELOG.md +76 -0
  429. package/lib/node_modules/jsonc-parser/LICENSE.md +21 -0
  430. package/lib/node_modules/jsonc-parser/README.md +364 -0
  431. package/lib/node_modules/jsonc-parser/SECURITY.md +41 -0
  432. package/lib/node_modules/jsonc-parser/lib/esm/impl/edit.js +185 -0
  433. package/lib/node_modules/jsonc-parser/lib/esm/impl/format.js +261 -0
  434. package/lib/node_modules/jsonc-parser/lib/esm/impl/parser.js +659 -0
  435. package/lib/node_modules/jsonc-parser/lib/esm/impl/scanner.js +443 -0
  436. package/lib/node_modules/jsonc-parser/lib/esm/impl/string-intern.js +29 -0
  437. package/lib/node_modules/jsonc-parser/lib/esm/main.d.ts +351 -0
  438. package/lib/node_modules/jsonc-parser/lib/esm/main.js +178 -0
  439. package/lib/node_modules/jsonc-parser/lib/umd/impl/edit.js +201 -0
  440. package/lib/node_modules/jsonc-parser/lib/umd/impl/format.js +275 -0
  441. package/lib/node_modules/jsonc-parser/lib/umd/impl/parser.js +682 -0
  442. package/lib/node_modules/jsonc-parser/lib/umd/impl/scanner.js +456 -0
  443. package/lib/node_modules/jsonc-parser/lib/umd/impl/string-intern.js +42 -0
  444. package/lib/node_modules/jsonc-parser/lib/umd/main.d.ts +351 -0
  445. package/lib/node_modules/jsonc-parser/lib/umd/main.js +194 -0
  446. package/lib/node_modules/jsonc-parser/package.json +37 -0
  447. package/lib/node_modules/picomatch/LICENSE +21 -0
  448. package/lib/node_modules/picomatch/README.md +738 -0
  449. package/lib/node_modules/picomatch/index.js +17 -0
  450. package/lib/node_modules/picomatch/lib/constants.js +180 -0
  451. package/lib/node_modules/picomatch/lib/parse.js +1085 -0
  452. package/lib/node_modules/picomatch/lib/picomatch.js +341 -0
  453. package/lib/node_modules/picomatch/lib/scan.js +391 -0
  454. package/lib/node_modules/picomatch/lib/utils.js +72 -0
  455. package/lib/node_modules/picomatch/package.json +83 -0
  456. package/lib/node_modules/picomatch/posix.js +3 -0
  457. package/lib/node_modules/sisteransi/license +21 -0
  458. package/lib/node_modules/sisteransi/package.json +34 -0
  459. package/lib/node_modules/sisteransi/readme.md +113 -0
  460. package/lib/node_modules/sisteransi/src/index.js +58 -0
  461. package/lib/node_modules/sisteransi/src/sisteransi.d.ts +35 -0
  462. package/lib/node_modules/tree-sitter-wasms/LICENSE +24 -0
  463. package/lib/node_modules/tree-sitter-wasms/README.md +23 -0
  464. package/lib/node_modules/tree-sitter-wasms/out/tree-sitter-bash.wasm +0 -0
  465. package/lib/node_modules/tree-sitter-wasms/out/tree-sitter-c.wasm +0 -0
  466. package/lib/node_modules/tree-sitter-wasms/out/tree-sitter-c_sharp.wasm +0 -0
  467. package/lib/node_modules/tree-sitter-wasms/out/tree-sitter-cpp.wasm +0 -0
  468. package/lib/node_modules/tree-sitter-wasms/out/tree-sitter-css.wasm +0 -0
  469. package/lib/node_modules/tree-sitter-wasms/out/tree-sitter-dart.wasm +0 -0
  470. package/lib/node_modules/tree-sitter-wasms/out/tree-sitter-elisp.wasm +0 -0
  471. package/lib/node_modules/tree-sitter-wasms/out/tree-sitter-elixir.wasm +0 -0
  472. package/lib/node_modules/tree-sitter-wasms/out/tree-sitter-elm.wasm +0 -0
  473. package/lib/node_modules/tree-sitter-wasms/out/tree-sitter-embedded_template.wasm +0 -0
  474. package/lib/node_modules/tree-sitter-wasms/out/tree-sitter-go.wasm +0 -0
  475. package/lib/node_modules/tree-sitter-wasms/out/tree-sitter-html.wasm +0 -0
  476. package/lib/node_modules/tree-sitter-wasms/out/tree-sitter-java.wasm +0 -0
  477. package/lib/node_modules/tree-sitter-wasms/out/tree-sitter-javascript.wasm +0 -0
  478. package/lib/node_modules/tree-sitter-wasms/out/tree-sitter-json.wasm +0 -0
  479. package/lib/node_modules/tree-sitter-wasms/out/tree-sitter-kotlin.wasm +0 -0
  480. package/lib/node_modules/tree-sitter-wasms/out/tree-sitter-lua.wasm +0 -0
  481. package/lib/node_modules/tree-sitter-wasms/out/tree-sitter-objc.wasm +0 -0
  482. package/lib/node_modules/tree-sitter-wasms/out/tree-sitter-ocaml.wasm +0 -0
  483. package/lib/node_modules/tree-sitter-wasms/out/tree-sitter-php.wasm +0 -0
  484. package/lib/node_modules/tree-sitter-wasms/out/tree-sitter-python.wasm +0 -0
  485. package/lib/node_modules/tree-sitter-wasms/out/tree-sitter-ql.wasm +0 -0
  486. package/lib/node_modules/tree-sitter-wasms/out/tree-sitter-rescript.wasm +0 -0
  487. package/lib/node_modules/tree-sitter-wasms/out/tree-sitter-ruby.wasm +0 -0
  488. package/lib/node_modules/tree-sitter-wasms/out/tree-sitter-rust.wasm +0 -0
  489. package/lib/node_modules/tree-sitter-wasms/out/tree-sitter-scala.wasm +0 -0
  490. package/lib/node_modules/tree-sitter-wasms/out/tree-sitter-solidity.wasm +0 -0
  491. package/lib/node_modules/tree-sitter-wasms/out/tree-sitter-swift.wasm +0 -0
  492. package/lib/node_modules/tree-sitter-wasms/out/tree-sitter-systemrdl.wasm +0 -0
  493. package/lib/node_modules/tree-sitter-wasms/out/tree-sitter-tlaplus.wasm +0 -0
  494. package/lib/node_modules/tree-sitter-wasms/out/tree-sitter-toml.wasm +0 -0
  495. package/lib/node_modules/tree-sitter-wasms/out/tree-sitter-tsx.wasm +0 -0
  496. package/lib/node_modules/tree-sitter-wasms/out/tree-sitter-typescript.wasm +0 -0
  497. package/lib/node_modules/tree-sitter-wasms/out/tree-sitter-vue.wasm +0 -0
  498. package/lib/node_modules/tree-sitter-wasms/out/tree-sitter-yaml.wasm +0 -0
  499. package/lib/node_modules/tree-sitter-wasms/out/tree-sitter-zig.wasm +0 -0
  500. package/lib/node_modules/tree-sitter-wasms/package.json +64 -0
  501. package/lib/node_modules/web-tree-sitter/LICENSE +21 -0
  502. package/lib/node_modules/web-tree-sitter/README.md +269 -0
  503. package/lib/node_modules/web-tree-sitter/debug/tree-sitter.cjs +4558 -0
  504. package/lib/node_modules/web-tree-sitter/debug/tree-sitter.cjs.map +7 -0
  505. package/lib/node_modules/web-tree-sitter/debug/tree-sitter.js +4516 -0
  506. package/lib/node_modules/web-tree-sitter/debug/tree-sitter.js.map +7 -0
  507. package/lib/node_modules/web-tree-sitter/debug/tree-sitter.wasm +0 -0
  508. package/lib/node_modules/web-tree-sitter/debug/tree-sitter.wasm.map +31 -0
  509. package/lib/node_modules/web-tree-sitter/lib/alloc.c +48 -0
  510. package/lib/node_modules/web-tree-sitter/lib/alloc.h +41 -0
  511. package/lib/node_modules/web-tree-sitter/lib/array.h +291 -0
  512. package/lib/node_modules/web-tree-sitter/lib/atomic.h +68 -0
  513. package/lib/node_modules/web-tree-sitter/lib/clock.h +146 -0
  514. package/lib/node_modules/web-tree-sitter/lib/error_costs.h +11 -0
  515. package/lib/node_modules/web-tree-sitter/lib/get_changed_ranges.c +523 -0
  516. package/lib/node_modules/web-tree-sitter/lib/get_changed_ranges.h +36 -0
  517. package/lib/node_modules/web-tree-sitter/lib/host.h +21 -0
  518. package/lib/node_modules/web-tree-sitter/lib/language.c +293 -0
  519. package/lib/node_modules/web-tree-sitter/lib/language.h +293 -0
  520. package/lib/node_modules/web-tree-sitter/lib/length.h +52 -0
  521. package/lib/node_modules/web-tree-sitter/lib/lexer.c +483 -0
  522. package/lib/node_modules/web-tree-sitter/lib/lexer.h +54 -0
  523. package/lib/node_modules/web-tree-sitter/lib/lib.c +12 -0
  524. package/lib/node_modules/web-tree-sitter/lib/node.c +875 -0
  525. package/lib/node_modules/web-tree-sitter/lib/parser.c +2297 -0
  526. package/lib/node_modules/web-tree-sitter/lib/parser.h +286 -0
  527. package/lib/node_modules/web-tree-sitter/lib/point.h +48 -0
  528. package/lib/node_modules/web-tree-sitter/lib/query.c +4347 -0
  529. package/lib/node_modules/web-tree-sitter/lib/reduce_action.h +34 -0
  530. package/lib/node_modules/web-tree-sitter/lib/reusable_node.h +95 -0
  531. package/lib/node_modules/web-tree-sitter/lib/stack.c +912 -0
  532. package/lib/node_modules/web-tree-sitter/lib/stack.h +133 -0
  533. package/lib/node_modules/web-tree-sitter/lib/subtree.c +1034 -0
  534. package/lib/node_modules/web-tree-sitter/lib/subtree.h +399 -0
  535. package/lib/node_modules/web-tree-sitter/lib/tree-sitter.c +987 -0
  536. package/lib/node_modules/web-tree-sitter/lib/tree-sitter.cjs +2988 -0
  537. package/lib/node_modules/web-tree-sitter/lib/tree-sitter.wasm +0 -0
  538. package/lib/node_modules/web-tree-sitter/lib/tree-sitter.wasm.map +1 -0
  539. package/lib/node_modules/web-tree-sitter/lib/tree.c +170 -0
  540. package/lib/node_modules/web-tree-sitter/lib/tree.h +31 -0
  541. package/lib/node_modules/web-tree-sitter/lib/tree_cursor.c +716 -0
  542. package/lib/node_modules/web-tree-sitter/lib/tree_cursor.h +48 -0
  543. package/lib/node_modules/web-tree-sitter/lib/ts_assert.h +11 -0
  544. package/lib/node_modules/web-tree-sitter/lib/unicode.h +75 -0
  545. package/lib/node_modules/web-tree-sitter/lib/wasm_store.c +1937 -0
  546. package/lib/node_modules/web-tree-sitter/lib/wasm_store.h +31 -0
  547. package/lib/node_modules/web-tree-sitter/package.json +98 -0
  548. package/lib/node_modules/web-tree-sitter/src/bindings.ts +26 -0
  549. package/lib/node_modules/web-tree-sitter/src/constants.ts +133 -0
  550. package/lib/node_modules/web-tree-sitter/src/index.ts +31 -0
  551. package/lib/node_modules/web-tree-sitter/src/language.ts +291 -0
  552. package/lib/node_modules/web-tree-sitter/src/lookahead_iterator.ts +75 -0
  553. package/lib/node_modules/web-tree-sitter/src/marshal.ts +176 -0
  554. package/lib/node_modules/web-tree-sitter/src/node.ts +646 -0
  555. package/lib/node_modules/web-tree-sitter/src/parser.ts +325 -0
  556. package/lib/node_modules/web-tree-sitter/src/query.ts +973 -0
  557. package/lib/node_modules/web-tree-sitter/src/tree.ts +145 -0
  558. package/lib/node_modules/web-tree-sitter/src/tree_cursor.ts +318 -0
  559. package/lib/node_modules/web-tree-sitter/tree-sitter.cjs +4031 -0
  560. package/lib/node_modules/web-tree-sitter/tree-sitter.cjs.map +7 -0
  561. package/lib/node_modules/web-tree-sitter/tree-sitter.js +3980 -0
  562. package/lib/node_modules/web-tree-sitter/tree-sitter.js.map +7 -0
  563. package/lib/node_modules/web-tree-sitter/tree-sitter.wasm +0 -0
  564. package/lib/node_modules/web-tree-sitter/tree-sitter.wasm.map +30 -0
  565. package/lib/node_modules/web-tree-sitter/web-tree-sitter.d.ts +1030 -0
  566. package/lib/node_modules/web-tree-sitter/web-tree-sitter.d.ts.map +56 -0
  567. package/lib/package.json +55 -0
  568. package/node +0 -0
  569. package/package.json +17 -0
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../lib/tree-sitter.cjs", "../src/index.ts", "../src/constants.ts", "../src/lookahead_iterator.ts", "../src/tree.ts", "../src/tree_cursor.ts", "../src/node.ts", "../src/marshal.ts", "../src/query.ts", "../src/language.ts", "../src/bindings.ts", "../src/parser.ts"],
4
+ "sourcesContent": ["var Module = (() => {\n var _scriptName = typeof document != 'undefined' ? document.currentScript?.src : undefined;\n if (typeof __filename != 'undefined') _scriptName = _scriptName || __filename;\n return (\nasync function(moduleArg = {}) {\n var moduleRtn;\n\n// include: shell.js\n// The Module object: Our interface to the outside world. We import\n// and export values on it. There are various ways Module can be used:\n// 1. Not defined. We create it here\n// 2. A function parameter, function(moduleArg) => Promise<Module>\n// 3. pre-run appended it, var Module = {}; ..generated code..\n// 4. External script tag defines var Module.\n// We need to check if Module already exists (e.g. case 3 above).\n// Substitution will be replaced with actual code on later stage of the build,\n// this way Closure Compiler will not mangle it (e.g. case 4. above).\n// Note that if you want to run closure, and also to use Module\n// after the generated code, you will need to define var Module = {};\n// before the code. Then that object will be used in the code, and you\n// can continue to use Module afterwards as well.\nvar Module = moduleArg;\n\n// Set up the promise that indicates the Module is initialized\nvar readyPromiseResolve, readyPromiseReject;\n\nvar readyPromise = new Promise((resolve, reject) => {\n readyPromiseResolve = resolve;\n readyPromiseReject = reject;\n});\n\n// Determine the runtime environment we are in. You can customize this by\n// setting the ENVIRONMENT setting at compile time (see settings.js).\n// Attempt to auto-detect the environment\nvar ENVIRONMENT_IS_WEB = typeof window == \"object\";\n\nvar ENVIRONMENT_IS_WORKER = typeof WorkerGlobalScope != \"undefined\";\n\n// N.b. Electron.js environment is simultaneously a NODE-environment, but\n// also a web environment.\nvar ENVIRONMENT_IS_NODE = typeof process == \"object\" && typeof process.versions == \"object\" && typeof process.versions.node == \"string\" && process.type != \"renderer\";\n\nvar ENVIRONMENT_IS_SHELL = !ENVIRONMENT_IS_WEB && !ENVIRONMENT_IS_NODE && !ENVIRONMENT_IS_WORKER;\n\nif (ENVIRONMENT_IS_NODE) {}\n\n// --pre-jses are emitted after the Module integration code, so that they can\n// refer to Module (if they choose; they can also define Module)\n// include: lib/binding_web/lib/prefix.js\nModule.currentQueryProgressCallback = null;\n\nModule.currentProgressCallback = null;\n\nModule.currentLogCallback = null;\n\nModule.currentParseCallback = null;\n\n// end include: lib/binding_web/lib/prefix.js\n// Sometimes an existing Module object exists with properties\n// meant to overwrite the default module functionality. Here\n// we collect those properties and reapply _after_ we configure\n// the current environment's defaults to avoid having to be so\n// defensive during initialization.\nvar moduleOverrides = Object.assign({}, Module);\n\nvar arguments_ = [];\n\nvar thisProgram = \"./this.program\";\n\nvar quit_ = (status, toThrow) => {\n throw toThrow;\n};\n\n// `/` should be present at the end if `scriptDirectory` is not empty\nvar scriptDirectory = \"\";\n\nfunction locateFile(path) {\n if (Module[\"locateFile\"]) {\n return Module[\"locateFile\"](path, scriptDirectory);\n }\n return scriptDirectory + path;\n}\n\n// Hooks that are implemented differently in different runtime environments.\nvar readAsync, readBinary;\n\nif (ENVIRONMENT_IS_NODE) {\n if (typeof process == \"undefined\" || !process.release || process.release.name !== \"node\") throw new Error(\"not compiled for this environment (did you build to HTML and try to run it not on the web, or set ENVIRONMENT to something - like node - and run it someplace else - like on the web?)\");\n var nodeVersion = process.versions.node;\n var numericVersion = nodeVersion.split(\".\").slice(0, 3);\n numericVersion = (numericVersion[0] * 1e4) + (numericVersion[1] * 100) + (numericVersion[2].split(\"-\")[0] * 1);\n var minVersion = 16e4;\n if (numericVersion < 16e4) {\n throw new Error(\"This emscripten-generated code requires node v16.0.0 (detected v\" + nodeVersion + \")\");\n }\n // These modules will usually be used on Node.js. Load them eagerly to avoid\n // the complexity of lazy-loading.\n var fs = require(\"fs\");\n var nodePath = require(\"path\");\n scriptDirectory = __dirname + \"/\";\n // include: node_shell_read.js\n readBinary = filename => {\n // We need to re-wrap `file://` strings to URLs.\n filename = isFileURI(filename) ? new URL(filename) : filename;\n var ret = fs.readFileSync(filename);\n assert(Buffer.isBuffer(ret));\n return ret;\n };\n readAsync = async (filename, binary = true) => {\n // See the comment in the `readBinary` function.\n filename = isFileURI(filename) ? new URL(filename) : filename;\n var ret = fs.readFileSync(filename, binary ? undefined : \"utf8\");\n assert(binary ? Buffer.isBuffer(ret) : typeof ret == \"string\");\n return ret;\n };\n // end include: node_shell_read.js\n if (!Module[\"thisProgram\"] && process.argv.length > 1) {\n thisProgram = process.argv[1].replace(/\\\\/g, \"/\");\n }\n arguments_ = process.argv.slice(2);\n // MODULARIZE will export the module in the proper place outside, we don't need to export here\n quit_ = (status, toThrow) => {\n process.exitCode = status;\n throw toThrow;\n };\n} else if (ENVIRONMENT_IS_SHELL) {\n if ((typeof process == \"object\" && typeof require === \"function\") || typeof window == \"object\" || typeof WorkerGlobalScope != \"undefined\") throw new Error(\"not compiled for this environment (did you build to HTML and try to run it not on the web, or set ENVIRONMENT to something - like node - and run it someplace else - like on the web?)\");\n} else // Note that this includes Node.js workers when relevant (pthreads is enabled).\n// Node.js workers are detected as a combination of ENVIRONMENT_IS_WORKER and\n// ENVIRONMENT_IS_NODE.\nif (ENVIRONMENT_IS_WEB || ENVIRONMENT_IS_WORKER) {\n if (ENVIRONMENT_IS_WORKER) {\n // Check worker, not web, since window could be polyfilled\n scriptDirectory = self.location.href;\n } else if (typeof document != \"undefined\" && document.currentScript) {\n // web\n scriptDirectory = document.currentScript.src;\n }\n // When MODULARIZE, this JS may be executed later, after document.currentScript\n // is gone, so we saved it, and we use it here instead of any other info.\n if (_scriptName) {\n scriptDirectory = _scriptName;\n }\n // blob urls look like blob:http://site.com/etc/etc and we cannot infer anything from them.\n // otherwise, slice off the final part of the url to find the script directory.\n // if scriptDirectory does not contain a slash, lastIndexOf will return -1,\n // and scriptDirectory will correctly be replaced with an empty string.\n // If scriptDirectory contains a query (starting with ?) or a fragment (starting with #),\n // they are removed because they could contain a slash.\n if (scriptDirectory.startsWith(\"blob:\")) {\n scriptDirectory = \"\";\n } else {\n scriptDirectory = scriptDirectory.slice(0, scriptDirectory.replace(/[?#].*/, \"\").lastIndexOf(\"/\") + 1);\n }\n if (!(typeof window == \"object\" || typeof WorkerGlobalScope != \"undefined\")) throw new Error(\"not compiled for this environment (did you build to HTML and try to run it not on the web, or set ENVIRONMENT to something - like node - and run it someplace else - like on the web?)\");\n {\n // include: web_or_worker_shell_read.js\n if (ENVIRONMENT_IS_WORKER) {\n readBinary = url => {\n var xhr = new XMLHttpRequest;\n xhr.open(\"GET\", url, false);\n xhr.responseType = \"arraybuffer\";\n xhr.send(null);\n return new Uint8Array(/** @type{!ArrayBuffer} */ (xhr.response));\n };\n }\n readAsync = async url => {\n // Fetch has some additional restrictions over XHR, like it can't be used on a file:// url.\n // See https://github.com/github/fetch/pull/92#issuecomment-140665932\n // Cordova or Electron apps are typically loaded from a file:// url.\n // So use XHR on webview if URL is a file URL.\n if (isFileURI(url)) {\n return new Promise((resolve, reject) => {\n var xhr = new XMLHttpRequest;\n xhr.open(\"GET\", url, true);\n xhr.responseType = \"arraybuffer\";\n xhr.onload = () => {\n if (xhr.status == 200 || (xhr.status == 0 && xhr.response)) {\n // file URLs can return 0\n resolve(xhr.response);\n return;\n }\n reject(xhr.status);\n };\n xhr.onerror = reject;\n xhr.send(null);\n });\n }\n var response = await fetch(url, {\n credentials: \"same-origin\"\n });\n if (response.ok) {\n return response.arrayBuffer();\n }\n throw new Error(response.status + \" : \" + response.url);\n };\n }\n} else {\n throw new Error(\"environment detection error\");\n}\n\nvar out = Module[\"print\"] || console.log.bind(console);\n\nvar err = Module[\"printErr\"] || console.error.bind(console);\n\n// Merge back in the overrides\nObject.assign(Module, moduleOverrides);\n\n// Free the object hierarchy contained in the overrides, this lets the GC\n// reclaim data used.\nmoduleOverrides = null;\n\ncheckIncomingModuleAPI();\n\n// Emit code to handle expected values on the Module object. This applies Module.x\n// to the proper local x. This has two benefits: first, we only emit it if it is\n// expected to arrive, and second, by using a local everywhere else that can be\n// minified.\nif (Module[\"arguments\"]) arguments_ = Module[\"arguments\"];\n\nlegacyModuleProp(\"arguments\", \"arguments_\");\n\nif (Module[\"thisProgram\"]) thisProgram = Module[\"thisProgram\"];\n\nlegacyModuleProp(\"thisProgram\", \"thisProgram\");\n\n// perform assertions in shell.js after we set up out() and err(), as otherwise if an assertion fails it cannot print the message\n// Assertions on removed incoming Module JS APIs.\nassert(typeof Module[\"memoryInitializerPrefixURL\"] == \"undefined\", \"Module.memoryInitializerPrefixURL option was removed, use Module.locateFile instead\");\n\nassert(typeof Module[\"pthreadMainPrefixURL\"] == \"undefined\", \"Module.pthreadMainPrefixURL option was removed, use Module.locateFile instead\");\n\nassert(typeof Module[\"cdInitializerPrefixURL\"] == \"undefined\", \"Module.cdInitializerPrefixURL option was removed, use Module.locateFile instead\");\n\nassert(typeof Module[\"filePackagePrefixURL\"] == \"undefined\", \"Module.filePackagePrefixURL option was removed, use Module.locateFile instead\");\n\nassert(typeof Module[\"read\"] == \"undefined\", \"Module.read option was removed\");\n\nassert(typeof Module[\"readAsync\"] == \"undefined\", \"Module.readAsync option was removed (modify readAsync in JS)\");\n\nassert(typeof Module[\"readBinary\"] == \"undefined\", \"Module.readBinary option was removed (modify readBinary in JS)\");\n\nassert(typeof Module[\"setWindowTitle\"] == \"undefined\", \"Module.setWindowTitle option was removed (modify emscripten_set_window_title in JS)\");\n\nassert(typeof Module[\"TOTAL_MEMORY\"] == \"undefined\", \"Module.TOTAL_MEMORY has been renamed Module.INITIAL_MEMORY\");\n\nlegacyModuleProp(\"asm\", \"wasmExports\");\n\nlegacyModuleProp(\"readAsync\", \"readAsync\");\n\nlegacyModuleProp(\"readBinary\", \"readBinary\");\n\nlegacyModuleProp(\"setWindowTitle\", \"setWindowTitle\");\n\nvar IDBFS = \"IDBFS is no longer included by default; build with -lidbfs.js\";\n\nvar PROXYFS = \"PROXYFS is no longer included by default; build with -lproxyfs.js\";\n\nvar WORKERFS = \"WORKERFS is no longer included by default; build with -lworkerfs.js\";\n\nvar FETCHFS = \"FETCHFS is no longer included by default; build with -lfetchfs.js\";\n\nvar ICASEFS = \"ICASEFS is no longer included by default; build with -licasefs.js\";\n\nvar JSFILEFS = \"JSFILEFS is no longer included by default; build with -ljsfilefs.js\";\n\nvar OPFS = \"OPFS is no longer included by default; build with -lopfs.js\";\n\nvar NODEFS = \"NODEFS is no longer included by default; build with -lnodefs.js\";\n\nassert(!ENVIRONMENT_IS_SHELL, \"shell environment detected but not enabled at build time. Add `shell` to `-sENVIRONMENT` to enable.\");\n\n// end include: shell.js\n// include: preamble.js\n// === Preamble library stuff ===\n// Documentation for the public APIs defined in this file must be updated in:\n// site/source/docs/api_reference/preamble.js.rst\n// A prebuilt local version of the documentation is available at:\n// site/build/text/docs/api_reference/preamble.js.txt\n// You can also build docs locally as HTML or other formats in site/\n// An online HTML version (which may be of a different version of Emscripten)\n// is up at http://kripken.github.io/emscripten-site/docs/api_reference/preamble.js.html\nvar dynamicLibraries = Module[\"dynamicLibraries\"] || [];\n\nvar wasmBinary = Module[\"wasmBinary\"];\n\nlegacyModuleProp(\"wasmBinary\", \"wasmBinary\");\n\nif (typeof WebAssembly != \"object\") {\n err(\"no native wasm support detected\");\n}\n\n// Wasm globals\nvar wasmMemory;\n\n//========================================\n// Runtime essentials\n//========================================\n// whether we are quitting the application. no code should run after this.\n// set in exit() and abort()\nvar ABORT = false;\n\n// set by exit() and abort(). Passed to 'onExit' handler.\n// NOTE: This is also used as the process return code code in shell environments\n// but only when noExitRuntime is false.\nvar EXITSTATUS;\n\n// In STRICT mode, we only define assert() when ASSERTIONS is set. i.e. we\n// don't define it at all in release modes. This matches the behaviour of\n// MINIMAL_RUNTIME.\n// TODO(sbc): Make this the default even without STRICT enabled.\n/** @type {function(*, string=)} */ function assert(condition, text) {\n if (!condition) {\n abort(\"Assertion failed\" + (text ? \": \" + text : \"\"));\n }\n}\n\n// We used to include malloc/free by default in the past. Show a helpful error in\n// builds with assertions.\n// Memory management\nvar HEAP, /** @type {!Int8Array} */ HEAP8, /** @type {!Uint8Array} */ HEAPU8, /** @type {!Int16Array} */ HEAP16, /** @type {!Uint16Array} */ HEAPU16, /** @type {!Int32Array} */ HEAP32, /** @type {!Uint32Array} */ HEAPU32, /** @type {!Float32Array} */ HEAPF32, /* BigInt64Array type is not correctly defined in closure\n/** not-@type {!BigInt64Array} */ HEAP64, /* BigUint64Array type is not correctly defined in closure\n/** not-t@type {!BigUint64Array} */ HEAPU64, /** @type {!Float64Array} */ HEAPF64;\n\nvar HEAP_DATA_VIEW;\n\nvar runtimeInitialized = false;\n\n/**\n * Indicates whether filename is delivered via file protocol (as opposed to http/https)\n * @noinline\n */ var isFileURI = filename => filename.startsWith(\"file://\");\n\n// include: runtime_shared.js\n// include: runtime_stack_check.js\n// Initializes the stack cookie. Called at the startup of main and at the startup of each thread in pthreads mode.\nfunction writeStackCookie() {\n var max = _emscripten_stack_get_end();\n assert((max & 3) == 0);\n // If the stack ends at address zero we write our cookies 4 bytes into the\n // stack. This prevents interference with SAFE_HEAP and ASAN which also\n // monitor writes to address zero.\n if (max == 0) {\n max += 4;\n }\n // The stack grow downwards towards _emscripten_stack_get_end.\n // We write cookies to the final two words in the stack and detect if they are\n // ever overwritten.\n LE_HEAP_STORE_U32(((max) >> 2) * 4, 34821223);\n LE_HEAP_STORE_U32((((max) + (4)) >> 2) * 4, 2310721022);\n}\n\nfunction checkStackCookie() {\n if (ABORT) return;\n var max = _emscripten_stack_get_end();\n // See writeStackCookie().\n if (max == 0) {\n max += 4;\n }\n var cookie1 = LE_HEAP_LOAD_U32(((max) >> 2) * 4);\n var cookie2 = LE_HEAP_LOAD_U32((((max) + (4)) >> 2) * 4);\n if (cookie1 != 34821223 || cookie2 != 2310721022) {\n abort(`Stack overflow! Stack cookie has been overwritten at ${ptrToString(max)}, expected hex dwords 0x89BACDFE and 0x2135467, but received ${ptrToString(cookie2)} ${ptrToString(cookie1)}`);\n }\n}\n\n// end include: runtime_stack_check.js\n// include: runtime_exceptions.js\n// end include: runtime_exceptions.js\n// include: runtime_debug.js\n// Endianness check\nif (Module[\"ENVIRONMENT\"]) {\n throw new Error(\"Module.ENVIRONMENT has been deprecated. To force the environment, use the ENVIRONMENT compile-time option (for example, -sENVIRONMENT=web or -sENVIRONMENT=node)\");\n}\n\nfunction legacyModuleProp(prop, newName, incoming = true) {\n if (!Object.getOwnPropertyDescriptor(Module, prop)) {\n Object.defineProperty(Module, prop, {\n configurable: true,\n get() {\n let extra = incoming ? \" (the initial value can be provided on Module, but after startup the value is only looked for on a local variable of that name)\" : \"\";\n abort(`\\`Module.${prop}\\` has been replaced by \\`${newName}\\`` + extra);\n }\n });\n }\n}\n\nfunction consumedModuleProp(prop) {\n if (!Object.getOwnPropertyDescriptor(Module, prop)) {\n Object.defineProperty(Module, prop, {\n configurable: true,\n set() {\n abort(`Attempt to set \\`Module.${prop}\\` after it has already been processed. This can happen, for example, when code is injected via '--post-js' rather than '--pre-js'`);\n }\n });\n }\n}\n\nfunction ignoredModuleProp(prop) {\n if (Object.getOwnPropertyDescriptor(Module, prop)) {\n abort(`\\`Module.${prop}\\` was supplied but \\`${prop}\\` not included in INCOMING_MODULE_JS_API`);\n }\n}\n\n// forcing the filesystem exports a few things by default\nfunction isExportedByForceFilesystem(name) {\n return name === \"FS_createPath\" || name === \"FS_createDataFile\" || name === \"FS_createPreloadedFile\" || name === \"FS_unlink\" || name === \"addRunDependency\" || // The old FS has some functionality that WasmFS lacks.\n name === \"FS_createLazyFile\" || name === \"FS_createDevice\" || name === \"removeRunDependency\";\n}\n\n/**\n * Intercept access to a global symbol. This enables us to give informative\n * warnings/errors when folks attempt to use symbols they did not include in\n * their build, or no symbols that no longer exist.\n */ function hookGlobalSymbolAccess(sym, func) {}\n\nfunction missingGlobal(sym, msg) {\n hookGlobalSymbolAccess(sym, () => {\n warnOnce(`\\`${sym}\\` is not longer defined by emscripten. ${msg}`);\n });\n}\n\nmissingGlobal(\"buffer\", \"Please use HEAP8.buffer or wasmMemory.buffer\");\n\nmissingGlobal(\"asm\", \"Please use wasmExports instead\");\n\nfunction missingLibrarySymbol(sym) {\n hookGlobalSymbolAccess(sym, () => {\n // Can't `abort()` here because it would break code that does runtime\n // checks. e.g. `if (typeof SDL === 'undefined')`.\n var msg = `\\`${sym}\\` is a library symbol and not included by default; add it to your library.js __deps or to DEFAULT_LIBRARY_FUNCS_TO_INCLUDE on the command line`;\n // DEFAULT_LIBRARY_FUNCS_TO_INCLUDE requires the name as it appears in\n // library.js, which means $name for a JS name with no prefix, or name\n // for a JS name like _name.\n var librarySymbol = sym;\n if (!librarySymbol.startsWith(\"_\")) {\n librarySymbol = \"$\" + sym;\n }\n msg += ` (e.g. -sDEFAULT_LIBRARY_FUNCS_TO_INCLUDE='${librarySymbol}')`;\n if (isExportedByForceFilesystem(sym)) {\n msg += \". Alternatively, forcing filesystem support (-sFORCE_FILESYSTEM) can export this for you\";\n }\n warnOnce(msg);\n });\n // Any symbol that is not included from the JS library is also (by definition)\n // not exported on the Module object.\n unexportedRuntimeSymbol(sym);\n}\n\nfunction unexportedRuntimeSymbol(sym) {\n if (!Object.getOwnPropertyDescriptor(Module, sym)) {\n Object.defineProperty(Module, sym, {\n configurable: true,\n get() {\n var msg = `'${sym}' was not exported. add it to EXPORTED_RUNTIME_METHODS (see the Emscripten FAQ)`;\n if (isExportedByForceFilesystem(sym)) {\n msg += \". Alternatively, forcing filesystem support (-sFORCE_FILESYSTEM) can export this for you\";\n }\n abort(msg);\n }\n });\n }\n}\n\n// Used by XXXXX_DEBUG settings to output debug messages.\nfunction dbg(...args) {\n // TODO(sbc): Make this configurable somehow. Its not always convenient for\n // logging to show up as warnings.\n console.warn(...args);\n}\n\n// end include: runtime_debug.js\n// include: memoryprofiler.js\n// end include: memoryprofiler.js\n// include: runtime_safe_heap.js\n/** @param {number|boolean=} isFloat */ function getSafeHeapType(bytes, isFloat) {\n switch (bytes) {\n case 1:\n return \"i8\";\n\n case 2:\n return \"i16\";\n\n case 4:\n return isFloat ? \"float\" : \"i32\";\n\n case 8:\n return isFloat ? \"double\" : \"i64\";\n\n default:\n abort(`getSafeHeapType() invalid bytes=${bytes}`);\n }\n}\n\n/** @param {number|boolean=} isFloat */ function SAFE_HEAP_STORE(dest, value, bytes, isFloat) {\n if (dest <= 0) abort(`segmentation fault storing ${bytes} bytes to address ${dest}`);\n if (dest % bytes !== 0) abort(`alignment error storing to address ${dest}, which was expected to be aligned to a multiple of ${bytes}`);\n if (runtimeInitialized) {\n var brk = _sbrk(0);\n if (dest + bytes > brk) abort(`segmentation fault, exceeded the top of the available dynamic heap when storing ${bytes} bytes to address ${dest}. DYNAMICTOP=${brk}`);\n if (brk < _emscripten_stack_get_base()) abort(`brk >= _emscripten_stack_get_base() (brk=${brk}, _emscripten_stack_get_base()=${_emscripten_stack_get_base()})`);\n // sbrk-managed memory must be above the stack\n if (brk > wasmMemory.buffer.byteLength) abort(`brk <= wasmMemory.buffer.byteLength (brk=${brk}, wasmMemory.buffer.byteLength=${wasmMemory.buffer.byteLength})`);\n }\n setValue_safe(dest, value, getSafeHeapType(bytes, isFloat));\n return value;\n}\n\nfunction SAFE_HEAP_STORE_D(dest, value, bytes) {\n return SAFE_HEAP_STORE(dest, value, bytes, true);\n}\n\n/** @param {number|boolean=} isFloat */ function SAFE_HEAP_LOAD(dest, bytes, unsigned, isFloat) {\n if (dest <= 0) abort(`segmentation fault loading ${bytes} bytes from address ${dest}`);\n if (dest % bytes !== 0) abort(`alignment error loading from address ${dest}, which was expected to be aligned to a multiple of ${bytes}`);\n if (runtimeInitialized) {\n var brk = _sbrk(0);\n if (dest + bytes > brk) abort(`segmentation fault, exceeded the top of the available dynamic heap when loading ${bytes} bytes from address ${dest}. DYNAMICTOP=${brk}`);\n if (brk < _emscripten_stack_get_base()) abort(`brk >= _emscripten_stack_get_base() (brk=${brk}, _emscripten_stack_get_base()=${_emscripten_stack_get_base()})`);\n // sbrk-managed memory must be above the stack\n if (brk > wasmMemory.buffer.byteLength) abort(`brk <= wasmMemory.buffer.byteLength (brk=${brk}, wasmMemory.buffer.byteLength=${wasmMemory.buffer.byteLength})`);\n }\n var type = getSafeHeapType(bytes, isFloat);\n var ret = getValue_safe(dest, type);\n if (unsigned) ret = unSign(ret, parseInt(type.slice(1), 10));\n return ret;\n}\n\nfunction SAFE_HEAP_LOAD_D(dest, bytes, unsigned) {\n return SAFE_HEAP_LOAD(dest, bytes, unsigned, true);\n}\n\nfunction SAFE_FT_MASK(value, mask) {\n var ret = value & mask;\n if (ret !== value) {\n abort(`Function table mask error: function pointer is ${value} which is masked by ${mask}, the likely cause of this is that the function pointer is being called by the wrong type.`);\n }\n return ret;\n}\n\nfunction segfault() {\n abort(\"segmentation fault\");\n}\n\nfunction alignfault() {\n abort(\"alignment fault\");\n}\n\n// end include: runtime_safe_heap.js\nfunction updateMemoryViews() {\n var b = wasmMemory.buffer;\n Module[\"HEAP_DATA_VIEW\"] = HEAP_DATA_VIEW = new DataView(b);\n Module[\"HEAP8\"] = HEAP8 = new Int8Array(b);\n Module[\"HEAP16\"] = HEAP16 = new Int16Array(b);\n Module[\"HEAPU8\"] = HEAPU8 = new Uint8Array(b);\n Module[\"HEAPU16\"] = HEAPU16 = new Uint16Array(b);\n Module[\"HEAP32\"] = HEAP32 = new Int32Array(b);\n Module[\"HEAPU32\"] = HEAPU32 = new Uint32Array(b);\n Module[\"HEAPF32\"] = HEAPF32 = new Float32Array(b);\n Module[\"HEAPF64\"] = HEAPF64 = new Float64Array(b);\n Module[\"HEAP64\"] = HEAP64 = new BigInt64Array(b);\n Module[\"HEAPU64\"] = HEAPU64 = new BigUint64Array(b);\n}\n\n// end include: runtime_shared.js\nassert(!Module[\"STACK_SIZE\"], \"STACK_SIZE can no longer be set at runtime. Use -sSTACK_SIZE at link time\");\n\nassert(typeof Int32Array != \"undefined\" && typeof Float64Array !== \"undefined\" && Int32Array.prototype.subarray != undefined && Int32Array.prototype.set != undefined, \"JS engine does not provide full typed array support\");\n\n// In non-standalone/normal mode, we create the memory here.\n// include: runtime_init_memory.js\n// Create the wasm memory. (Note: this only applies if IMPORTED_MEMORY is defined)\n// check for full engine support (use string 'subarray' to avoid closure compiler confusion)\nif (Module[\"wasmMemory\"]) {\n wasmMemory = Module[\"wasmMemory\"];\n} else {\n var INITIAL_MEMORY = Module[\"INITIAL_MEMORY\"] || 33554432;\n legacyModuleProp(\"INITIAL_MEMORY\", \"INITIAL_MEMORY\");\n assert(INITIAL_MEMORY >= 65536, \"INITIAL_MEMORY should be larger than STACK_SIZE, was \" + INITIAL_MEMORY + \"! (STACK_SIZE=\" + 65536 + \")\");\n /** @suppress {checkTypes} */ wasmMemory = new WebAssembly.Memory({\n \"initial\": INITIAL_MEMORY / 65536,\n // In theory we should not need to emit the maximum if we want \"unlimited\"\n // or 4GB of memory, but VMs error on that atm, see\n // https://github.com/emscripten-core/emscripten/issues/14130\n // And in the pthreads case we definitely need to emit a maximum. So\n // always emit one.\n \"maximum\": 32768\n });\n}\n\nupdateMemoryViews();\n\n// end include: runtime_init_memory.js\nvar __RELOC_FUNCS__ = [];\n\nfunction preRun() {\n if (Module[\"preRun\"]) {\n if (typeof Module[\"preRun\"] == \"function\") Module[\"preRun\"] = [ Module[\"preRun\"] ];\n while (Module[\"preRun\"].length) {\n addOnPreRun(Module[\"preRun\"].shift());\n }\n }\n consumedModuleProp(\"preRun\");\n callRuntimeCallbacks(onPreRuns);\n}\n\nfunction initRuntime() {\n assert(!runtimeInitialized);\n runtimeInitialized = true;\n checkStackCookie();\n callRuntimeCallbacks(__RELOC_FUNCS__);\n wasmExports[\"__wasm_call_ctors\"]();\n callRuntimeCallbacks(onPostCtors);\n}\n\nfunction preMain() {\n checkStackCookie();\n}\n\nfunction postRun() {\n checkStackCookie();\n if (Module[\"postRun\"]) {\n if (typeof Module[\"postRun\"] == \"function\") Module[\"postRun\"] = [ Module[\"postRun\"] ];\n while (Module[\"postRun\"].length) {\n addOnPostRun(Module[\"postRun\"].shift());\n }\n }\n consumedModuleProp(\"postRun\");\n callRuntimeCallbacks(onPostRuns);\n}\n\n// A counter of dependencies for calling run(). If we need to\n// do asynchronous work before running, increment this and\n// decrement it. Incrementing must happen in a place like\n// Module.preRun (used by emcc to add file preloading).\n// Note that you can add dependencies in preRun, even though\n// it happens right before run - run will be postponed until\n// the dependencies are met.\nvar runDependencies = 0;\n\nvar dependenciesFulfilled = null;\n\n// overridden to take different actions when all run dependencies are fulfilled\nvar runDependencyTracking = {};\n\nvar runDependencyWatcher = null;\n\nfunction getUniqueRunDependency(id) {\n var orig = id;\n while (1) {\n if (!runDependencyTracking[id]) return id;\n id = orig + Math.random();\n }\n}\n\nfunction addRunDependency(id) {\n runDependencies++;\n Module[\"monitorRunDependencies\"]?.(runDependencies);\n if (id) {\n assert(!runDependencyTracking[id]);\n runDependencyTracking[id] = 1;\n if (runDependencyWatcher === null && typeof setInterval != \"undefined\") {\n // Check for missing dependencies every few seconds\n runDependencyWatcher = setInterval(() => {\n if (ABORT) {\n clearInterval(runDependencyWatcher);\n runDependencyWatcher = null;\n return;\n }\n var shown = false;\n for (var dep in runDependencyTracking) {\n if (!shown) {\n shown = true;\n err(\"still waiting on run dependencies:\");\n }\n err(`dependency: ${dep}`);\n }\n if (shown) {\n err(\"(end of list)\");\n }\n }, 1e4);\n }\n } else {\n err(\"warning: run dependency added without ID\");\n }\n}\n\nfunction removeRunDependency(id) {\n runDependencies--;\n Module[\"monitorRunDependencies\"]?.(runDependencies);\n if (id) {\n assert(runDependencyTracking[id]);\n delete runDependencyTracking[id];\n } else {\n err(\"warning: run dependency removed without ID\");\n }\n if (runDependencies == 0) {\n if (runDependencyWatcher !== null) {\n clearInterval(runDependencyWatcher);\n runDependencyWatcher = null;\n }\n if (dependenciesFulfilled) {\n var callback = dependenciesFulfilled;\n dependenciesFulfilled = null;\n callback();\n }\n }\n}\n\n/** @param {string|number=} what */ function abort(what) {\n Module[\"onAbort\"]?.(what);\n what = \"Aborted(\" + what + \")\";\n // TODO(sbc): Should we remove printing and leave it up to whoever\n // catches the exception?\n err(what);\n ABORT = true;\n // Use a wasm runtime error, because a JS error might be seen as a foreign\n // exception, which means we'd run destructors on it. We need the error to\n // simply make the program stop.\n // FIXME This approach does not work in Wasm EH because it currently does not assume\n // all RuntimeErrors are from traps; it decides whether a RuntimeError is from\n // a trap or not based on a hidden field within the object. So at the moment\n // we don't have a way of throwing a wasm trap from JS. TODO Make a JS API that\n // allows this in the wasm spec.\n // Suppress closure compiler warning here. Closure compiler's builtin extern\n // definition for WebAssembly.RuntimeError claims it takes no arguments even\n // though it can.\n // TODO(https://github.com/google/closure-compiler/pull/3913): Remove if/when upstream closure gets fixed.\n /** @suppress {checkTypes} */ var e = new WebAssembly.RuntimeError(what);\n readyPromiseReject(e);\n // Throw the error whether or not MODULARIZE is set because abort is used\n // in code paths apart from instantiation where an exception is expected\n // to be thrown when abort is called.\n throw e;\n}\n\n// show errors on likely calls to FS when it was not included\nvar FS = {\n error() {\n abort(\"Filesystem support (FS) was not included. The problem is that you are using files from JS, but files were not used from C/C++, so filesystem support was not auto-included. You can force-include filesystem support with -sFORCE_FILESYSTEM\");\n },\n init() {\n FS.error();\n },\n createDataFile() {\n FS.error();\n },\n createPreloadedFile() {\n FS.error();\n },\n createLazyFile() {\n FS.error();\n },\n open() {\n FS.error();\n },\n mkdev() {\n FS.error();\n },\n registerDevice() {\n FS.error();\n },\n analyzePath() {\n FS.error();\n },\n ErrnoError() {\n FS.error();\n }\n};\n\nModule[\"FS_createDataFile\"] = FS.createDataFile;\n\nModule[\"FS_createPreloadedFile\"] = FS.createPreloadedFile;\n\nfunction createExportWrapper(name, nargs) {\n return (...args) => {\n assert(runtimeInitialized, `native function \\`${name}\\` called before runtime initialization`);\n var f = wasmExports[name];\n assert(f, `exported native function \\`${name}\\` not found`);\n // Only assert for too many arguments. Too few can be valid since the missing arguments will be zero filled.\n assert(args.length <= nargs, `native function \\`${name}\\` called with ${args.length} args but expects ${nargs}`);\n return f(...args);\n };\n}\n\nvar wasmBinaryFile;\n\nfunction findWasmBinary() {\n return locateFile(\"tree-sitter.wasm\");\n}\n\nfunction getBinarySync(file) {\n if (file == wasmBinaryFile && wasmBinary) {\n return new Uint8Array(wasmBinary);\n }\n if (readBinary) {\n return readBinary(file);\n }\n throw \"both async and sync fetching of the wasm failed\";\n}\n\nasync function getWasmBinary(binaryFile) {\n // If we don't have the binary yet, load it asynchronously using readAsync.\n if (!wasmBinary) {\n // Fetch the binary using readAsync\n try {\n var response = await readAsync(binaryFile);\n return new Uint8Array(response);\n } catch {}\n }\n // Otherwise, getBinarySync should be able to get it synchronously\n return getBinarySync(binaryFile);\n}\n\nasync function instantiateArrayBuffer(binaryFile, imports) {\n try {\n var binary = await getWasmBinary(binaryFile);\n var instance = await WebAssembly.instantiate(binary, imports);\n return instance;\n } catch (reason) {\n err(`failed to asynchronously prepare wasm: ${reason}`);\n // Warn on some common problems.\n if (isFileURI(wasmBinaryFile)) {\n err(`warning: Loading from a file URI (${wasmBinaryFile}) is not supported in most browsers. See https://emscripten.org/docs/getting_started/FAQ.html#how-do-i-run-a-local-webserver-for-testing-why-does-my-program-stall-in-downloading-or-preparing`);\n }\n abort(reason);\n }\n}\n\nasync function instantiateAsync(binary, binaryFile, imports) {\n if (!binary && typeof WebAssembly.instantiateStreaming == \"function\" && !isFileURI(binaryFile) && !ENVIRONMENT_IS_NODE) {\n try {\n var response = fetch(binaryFile, {\n credentials: \"same-origin\"\n });\n var instantiationResult = await WebAssembly.instantiateStreaming(response, imports);\n return instantiationResult;\n } catch (reason) {\n // We expect the most common failure cause to be a bad MIME type for the binary,\n // in which case falling back to ArrayBuffer instantiation should work.\n err(`wasm streaming compile failed: ${reason}`);\n err(\"falling back to ArrayBuffer instantiation\");\n }\n }\n return instantiateArrayBuffer(binaryFile, imports);\n}\n\nfunction getWasmImports() {\n // prepare imports\n return {\n \"env\": wasmImports,\n \"wasi_snapshot_preview1\": wasmImports,\n \"GOT.mem\": new Proxy(wasmImports, GOTHandler),\n \"GOT.func\": new Proxy(wasmImports, GOTHandler)\n };\n}\n\n// Create the wasm instance.\n// Receives the wasm imports, returns the exports.\nasync function createWasm() {\n // Load the wasm module and create an instance of using native support in the JS engine.\n // handle a generated wasm instance, receiving its exports and\n // performing other necessary setup\n /** @param {WebAssembly.Module=} module*/ function receiveInstance(instance, module) {\n wasmExports = instance.exports;\n wasmExports = relocateExports(wasmExports, 1024);\n var metadata = getDylinkMetadata(module);\n if (metadata.neededDynlibs) {\n dynamicLibraries = metadata.neededDynlibs.concat(dynamicLibraries);\n }\n mergeLibSymbols(wasmExports, \"main\");\n LDSO.init();\n loadDylibs();\n __RELOC_FUNCS__.push(wasmExports[\"__wasm_apply_data_relocs\"]);\n removeRunDependency(\"wasm-instantiate\");\n return wasmExports;\n }\n // wait for the pthread pool (if any)\n addRunDependency(\"wasm-instantiate\");\n // Prefer streaming instantiation if available.\n // Async compilation can be confusing when an error on the page overwrites Module\n // (for example, if the order of elements is wrong, and the one defining Module is\n // later), so we save Module and check it later.\n var trueModule = Module;\n function receiveInstantiationResult(result) {\n // 'result' is a ResultObject object which has both the module and instance.\n // receiveInstance() will swap in the exports (to Module.asm) so they can be called\n assert(Module === trueModule, \"the Module object should not be replaced during async compilation - perhaps the order of HTML elements is wrong?\");\n trueModule = null;\n return receiveInstance(result[\"instance\"], result[\"module\"]);\n }\n var info = getWasmImports();\n // User shell pages can write their own Module.instantiateWasm = function(imports, successCallback) callback\n // to manually instantiate the Wasm module themselves. This allows pages to\n // run the instantiation parallel to any other async startup actions they are\n // performing.\n // Also pthreads and wasm workers initialize the wasm instance through this\n // path.\n if (Module[\"instantiateWasm\"]) {\n return new Promise((resolve, reject) => {\n try {\n Module[\"instantiateWasm\"](info, (mod, inst) => {\n receiveInstance(mod, inst);\n resolve(mod.exports);\n });\n } catch (e) {\n err(`Module.instantiateWasm callback failed with error: ${e}`);\n reject(e);\n }\n });\n }\n wasmBinaryFile ??= findWasmBinary();\n try {\n var result = await instantiateAsync(wasmBinary, wasmBinaryFile, info);\n var exports = receiveInstantiationResult(result);\n return exports;\n } catch (e) {\n // If instantiation fails, reject the module ready promise.\n readyPromiseReject(e);\n return Promise.reject(e);\n }\n}\n\n// === Body ===\nvar ASM_CONSTS = {};\n\n// end include: preamble.js\nclass ExitStatus {\n name=\"ExitStatus\";\n constructor(status) {\n this.message = `Program terminated with exit(${status})`;\n this.status = status;\n }\n}\n\nvar GOT = {};\n\nvar currentModuleWeakSymbols = new Set([]);\n\nvar GOTHandler = {\n get(obj, symName) {\n var rtn = GOT[symName];\n if (!rtn) {\n rtn = GOT[symName] = new WebAssembly.Global({\n \"value\": \"i32\",\n \"mutable\": true\n });\n }\n if (!currentModuleWeakSymbols.has(symName)) {\n // Any non-weak reference to a symbol marks it as `required`, which\n // enabled `reportUndefinedSymbols` to report undefined symbol errors\n // correctly.\n rtn.required = true;\n }\n return rtn;\n }\n};\n\nvar LE_HEAP_LOAD_F32 = byteOffset => HEAP_DATA_VIEW.getFloat32(byteOffset, true);\n\nvar LE_HEAP_LOAD_F64 = byteOffset => HEAP_DATA_VIEW.getFloat64(byteOffset, true);\n\nvar LE_HEAP_LOAD_I16 = byteOffset => HEAP_DATA_VIEW.getInt16(byteOffset, true);\n\nvar LE_HEAP_LOAD_I32 = byteOffset => HEAP_DATA_VIEW.getInt32(byteOffset, true);\n\nvar LE_HEAP_LOAD_U16 = byteOffset => HEAP_DATA_VIEW.getUint16(byteOffset, true);\n\nvar LE_HEAP_LOAD_U32 = byteOffset => HEAP_DATA_VIEW.getUint32(byteOffset, true);\n\nvar LE_HEAP_STORE_F32 = (byteOffset, value) => HEAP_DATA_VIEW.setFloat32(byteOffset, value, true);\n\nvar LE_HEAP_STORE_F64 = (byteOffset, value) => HEAP_DATA_VIEW.setFloat64(byteOffset, value, true);\n\nvar LE_HEAP_STORE_I16 = (byteOffset, value) => HEAP_DATA_VIEW.setInt16(byteOffset, value, true);\n\nvar LE_HEAP_STORE_I32 = (byteOffset, value) => HEAP_DATA_VIEW.setInt32(byteOffset, value, true);\n\nvar LE_HEAP_STORE_U16 = (byteOffset, value) => HEAP_DATA_VIEW.setUint16(byteOffset, value, true);\n\nvar LE_HEAP_STORE_U32 = (byteOffset, value) => HEAP_DATA_VIEW.setUint32(byteOffset, value, true);\n\nvar callRuntimeCallbacks = callbacks => {\n while (callbacks.length > 0) {\n // Pass the module as the first argument.\n callbacks.shift()(Module);\n }\n};\n\nvar onPostRuns = [];\n\nvar addOnPostRun = cb => onPostRuns.unshift(cb);\n\nvar onPreRuns = [];\n\nvar addOnPreRun = cb => onPreRuns.unshift(cb);\n\nvar UTF8Decoder = typeof TextDecoder != \"undefined\" ? new TextDecoder : undefined;\n\n/**\n * Given a pointer 'idx' to a null-terminated UTF8-encoded string in the given\n * array that contains uint8 values, returns a copy of that string as a\n * Javascript String object.\n * heapOrArray is either a regular array, or a JavaScript typed array view.\n * @param {number=} idx\n * @param {number=} maxBytesToRead\n * @return {string}\n */ var UTF8ArrayToString = (heapOrArray, idx = 0, maxBytesToRead = NaN) => {\n var endIdx = idx + maxBytesToRead;\n var endPtr = idx;\n // TextDecoder needs to know the byte length in advance, it doesn't stop on\n // null terminator by itself. Also, use the length info to avoid running tiny\n // strings through TextDecoder, since .subarray() allocates garbage.\n // (As a tiny code save trick, compare endPtr against endIdx using a negation,\n // so that undefined/NaN means Infinity)\n while (heapOrArray[endPtr] && !(endPtr >= endIdx)) ++endPtr;\n if (endPtr - idx > 16 && heapOrArray.buffer && UTF8Decoder) {\n return UTF8Decoder.decode(heapOrArray.subarray(idx, endPtr));\n }\n var str = \"\";\n // If building with TextDecoder, we have already computed the string length\n // above, so test loop end condition against that\n while (idx < endPtr) {\n // For UTF8 byte structure, see:\n // http://en.wikipedia.org/wiki/UTF-8#Description\n // https://www.ietf.org/rfc/rfc2279.txt\n // https://tools.ietf.org/html/rfc3629\n var u0 = heapOrArray[idx++];\n if (!(u0 & 128)) {\n str += String.fromCharCode(u0);\n continue;\n }\n var u1 = heapOrArray[idx++] & 63;\n if ((u0 & 224) == 192) {\n str += String.fromCharCode(((u0 & 31) << 6) | u1);\n continue;\n }\n var u2 = heapOrArray[idx++] & 63;\n if ((u0 & 240) == 224) {\n u0 = ((u0 & 15) << 12) | (u1 << 6) | u2;\n } else {\n if ((u0 & 248) != 240) warnOnce(\"Invalid UTF-8 leading byte \" + ptrToString(u0) + \" encountered when deserializing a UTF-8 string in wasm memory to a JS string!\");\n u0 = ((u0 & 7) << 18) | (u1 << 12) | (u2 << 6) | (heapOrArray[idx++] & 63);\n }\n if (u0 < 65536) {\n str += String.fromCharCode(u0);\n } else {\n var ch = u0 - 65536;\n str += String.fromCharCode(55296 | (ch >> 10), 56320 | (ch & 1023));\n }\n }\n return str;\n};\n\nvar getDylinkMetadata = binary => {\n var offset = 0;\n var end = 0;\n function getU8() {\n return binary[offset++];\n }\n function getLEB() {\n var ret = 0;\n var mul = 1;\n while (1) {\n var byte = binary[offset++];\n ret += ((byte & 127) * mul);\n mul *= 128;\n if (!(byte & 128)) break;\n }\n return ret;\n }\n function getString() {\n var len = getLEB();\n offset += len;\n return UTF8ArrayToString(binary, offset - len, len);\n }\n /** @param {string=} message */ function failIf(condition, message) {\n if (condition) throw new Error(message);\n }\n var name = \"dylink.0\";\n if (binary instanceof WebAssembly.Module) {\n var dylinkSection = WebAssembly.Module.customSections(binary, name);\n if (dylinkSection.length === 0) {\n name = \"dylink\";\n dylinkSection = WebAssembly.Module.customSections(binary, name);\n }\n failIf(dylinkSection.length === 0, \"need dylink section\");\n binary = new Uint8Array(dylinkSection[0]);\n end = binary.length;\n } else {\n var int32View = new Uint32Array(new Uint8Array(binary.subarray(0, 24)).buffer);\n var magicNumberFound = int32View[0] == 1836278016 || int32View[0] == 6386541;\n failIf(!magicNumberFound, \"need to see wasm magic number\");\n // \\0asm\n // we should see the dylink custom section right after the magic number and wasm version\n failIf(binary[8] !== 0, \"need the dylink section to be first\");\n offset = 9;\n var section_size = getLEB();\n //section size\n end = offset + section_size;\n name = getString();\n }\n var customSection = {\n neededDynlibs: [],\n tlsExports: new Set,\n weakImports: new Set\n };\n if (name == \"dylink\") {\n customSection.memorySize = getLEB();\n customSection.memoryAlign = getLEB();\n customSection.tableSize = getLEB();\n customSection.tableAlign = getLEB();\n // shared libraries this module needs. We need to load them first, so that\n // current module could resolve its imports. (see tools/shared.py\n // WebAssembly.make_shared_library() for \"dylink\" section extension format)\n var neededDynlibsCount = getLEB();\n for (var i = 0; i < neededDynlibsCount; ++i) {\n var libname = getString();\n customSection.neededDynlibs.push(libname);\n }\n } else {\n failIf(name !== \"dylink.0\");\n var WASM_DYLINK_MEM_INFO = 1;\n var WASM_DYLINK_NEEDED = 2;\n var WASM_DYLINK_EXPORT_INFO = 3;\n var WASM_DYLINK_IMPORT_INFO = 4;\n var WASM_SYMBOL_TLS = 256;\n var WASM_SYMBOL_BINDING_MASK = 3;\n var WASM_SYMBOL_BINDING_WEAK = 1;\n while (offset < end) {\n var subsectionType = getU8();\n var subsectionSize = getLEB();\n if (subsectionType === WASM_DYLINK_MEM_INFO) {\n customSection.memorySize = getLEB();\n customSection.memoryAlign = getLEB();\n customSection.tableSize = getLEB();\n customSection.tableAlign = getLEB();\n } else if (subsectionType === WASM_DYLINK_NEEDED) {\n var neededDynlibsCount = getLEB();\n for (var i = 0; i < neededDynlibsCount; ++i) {\n libname = getString();\n customSection.neededDynlibs.push(libname);\n }\n } else if (subsectionType === WASM_DYLINK_EXPORT_INFO) {\n var count = getLEB();\n while (count--) {\n var symname = getString();\n var flags = getLEB();\n if (flags & WASM_SYMBOL_TLS) {\n customSection.tlsExports.add(symname);\n }\n }\n } else if (subsectionType === WASM_DYLINK_IMPORT_INFO) {\n var count = getLEB();\n while (count--) {\n var modname = getString();\n var symname = getString();\n var flags = getLEB();\n if ((flags & WASM_SYMBOL_BINDING_MASK) == WASM_SYMBOL_BINDING_WEAK) {\n customSection.weakImports.add(symname);\n }\n }\n } else {\n err(`unknown dylink.0 subsection: ${subsectionType}`);\n // unknown subsection\n offset += subsectionSize;\n }\n }\n }\n var tableAlign = Math.pow(2, customSection.tableAlign);\n assert(tableAlign === 1, `invalid tableAlign ${tableAlign}`);\n assert(offset == end);\n return customSection;\n};\n\n/**\n * @param {number} ptr\n * @param {string} type\n */ function getValue(ptr, type = \"i8\") {\n if (type.endsWith(\"*\")) type = \"*\";\n switch (type) {\n case \"i1\":\n return SAFE_HEAP_LOAD(ptr, 1, 0);\n\n case \"i8\":\n return SAFE_HEAP_LOAD(ptr, 1, 0);\n\n case \"i16\":\n return LE_HEAP_LOAD_I16(((ptr) >> 1) * 2);\n\n case \"i32\":\n return LE_HEAP_LOAD_I32(((ptr) >> 2) * 4);\n\n case \"i64\":\n return HEAP64[((ptr) >> 3)];\n\n case \"float\":\n return LE_HEAP_LOAD_F32(((ptr) >> 2) * 4);\n\n case \"double\":\n return LE_HEAP_LOAD_F64(((ptr) >> 3) * 8);\n\n case \"*\":\n return LE_HEAP_LOAD_U32(((ptr) >> 2) * 4);\n\n default:\n abort(`invalid type for getValue: ${type}`);\n }\n}\n\nfunction getValue_safe(ptr, type = \"i8\") {\n if (type.endsWith(\"*\")) type = \"*\";\n switch (type) {\n case \"i1\":\n return HEAP8[ptr];\n\n case \"i8\":\n return HEAP8[ptr];\n\n case \"i16\":\n return LE_HEAP_LOAD_I16(((ptr) >> 1) * 2);\n\n case \"i32\":\n return LE_HEAP_LOAD_I32(((ptr) >> 2) * 4);\n\n case \"i64\":\n return HEAP64[((ptr) >> 3)];\n\n case \"float\":\n return LE_HEAP_LOAD_F32(((ptr) >> 2) * 4);\n\n case \"double\":\n return LE_HEAP_LOAD_F64(((ptr) >> 3) * 8);\n\n case \"*\":\n return LE_HEAP_LOAD_U32(((ptr) >> 2) * 4);\n\n default:\n abort(`invalid type for getValue: ${type}`);\n }\n}\n\nvar newDSO = (name, handle, syms) => {\n var dso = {\n refcount: Infinity,\n name,\n exports: syms,\n global: true\n };\n LDSO.loadedLibsByName[name] = dso;\n if (handle != undefined) {\n LDSO.loadedLibsByHandle[handle] = dso;\n }\n return dso;\n};\n\nvar LDSO = {\n loadedLibsByName: {},\n loadedLibsByHandle: {},\n init() {\n // This function needs to run after the initial wasmImports object\n // as been created.\n assert(wasmImports);\n newDSO(\"__main__\", 0, wasmImports);\n }\n};\n\nvar ___heap_base = 78208;\n\nvar alignMemory = (size, alignment) => {\n assert(alignment, \"alignment argument is required\");\n return Math.ceil(size / alignment) * alignment;\n};\n\nvar getMemory = size => {\n // After the runtime is initialized, we must only use sbrk() normally.\n if (runtimeInitialized) {\n // Currently we don't support freeing of static data when modules are\n // unloaded via dlclose. This function is tagged as `noleakcheck` to\n // avoid having this reported as leak.\n return _calloc(size, 1);\n }\n var ret = ___heap_base;\n // Keep __heap_base stack aligned.\n var end = ret + alignMemory(size, 16);\n assert(end <= HEAP8.length, \"failure to getMemory - memory growth etc. is not supported there, call malloc/sbrk directly or increase INITIAL_MEMORY\");\n ___heap_base = end;\n GOT[\"__heap_base\"].value = end;\n return ret;\n};\n\nvar isInternalSym = symName => [ \"__cpp_exception\", \"__c_longjmp\", \"__wasm_apply_data_relocs\", \"__dso_handle\", \"__tls_size\", \"__tls_align\", \"__set_stack_limits\", \"_emscripten_tls_init\", \"__wasm_init_tls\", \"__wasm_call_ctors\", \"__start_em_asm\", \"__stop_em_asm\", \"__start_em_js\", \"__stop_em_js\" ].includes(symName) || symName.startsWith(\"__em_js__\");\n\nvar uleb128Encode = (n, target) => {\n assert(n < 16384);\n if (n < 128) {\n target.push(n);\n } else {\n target.push((n % 128) | 128, n >> 7);\n }\n};\n\nvar sigToWasmTypes = sig => {\n var typeNames = {\n \"i\": \"i32\",\n \"j\": \"i64\",\n \"f\": \"f32\",\n \"d\": \"f64\",\n \"e\": \"externref\",\n \"p\": \"i32\"\n };\n var type = {\n parameters: [],\n results: sig[0] == \"v\" ? [] : [ typeNames[sig[0]] ]\n };\n for (var i = 1; i < sig.length; ++i) {\n assert(sig[i] in typeNames, \"invalid signature char: \" + sig[i]);\n type.parameters.push(typeNames[sig[i]]);\n }\n return type;\n};\n\nvar generateFuncType = (sig, target) => {\n var sigRet = sig.slice(0, 1);\n var sigParam = sig.slice(1);\n var typeCodes = {\n \"i\": 127,\n // i32\n \"p\": 127,\n // i32\n \"j\": 126,\n // i64\n \"f\": 125,\n // f32\n \"d\": 124,\n // f64\n \"e\": 111\n };\n // Parameters, length + signatures\n target.push(96);\n uleb128Encode(sigParam.length, target);\n for (var i = 0; i < sigParam.length; ++i) {\n assert(sigParam[i] in typeCodes, \"invalid signature char: \" + sigParam[i]);\n target.push(typeCodes[sigParam[i]]);\n }\n // Return values, length + signatures\n // With no multi-return in MVP, either 0 (void) or 1 (anything else)\n if (sigRet == \"v\") {\n target.push(0);\n } else {\n target.push(1, typeCodes[sigRet]);\n }\n};\n\nvar convertJsFunctionToWasm = (func, sig) => {\n // If the type reflection proposal is available, use the new\n // \"WebAssembly.Function\" constructor.\n // Otherwise, construct a minimal wasm module importing the JS function and\n // re-exporting it.\n if (typeof WebAssembly.Function == \"function\") {\n return new WebAssembly.Function(sigToWasmTypes(sig), func);\n }\n // The module is static, with the exception of the type section, which is\n // generated based on the signature passed in.\n var typeSectionBody = [ 1 ];\n generateFuncType(sig, typeSectionBody);\n // Rest of the module is static\n var bytes = [ 0, 97, 115, 109, // magic (\"\\0asm\")\n 1, 0, 0, 0, // version: 1\n 1 ];\n // Write the overall length of the type section followed by the body\n uleb128Encode(typeSectionBody.length, bytes);\n bytes.push(...typeSectionBody);\n // The rest of the module is static\n bytes.push(2, 7, // import section\n // (import \"e\" \"f\" (func 0 (type 0)))\n 1, 1, 101, 1, 102, 0, 0, 7, 5, // export section\n // (export \"f\" (func 0 (type 0)))\n 1, 1, 102, 0, 0);\n // We can compile this wasm module synchronously because it is very small.\n // This accepts an import (at \"e.f\"), that it reroutes to an export (at \"f\")\n var module = new WebAssembly.Module(new Uint8Array(bytes));\n var instance = new WebAssembly.Instance(module, {\n \"e\": {\n \"f\": func\n }\n });\n var wrappedFunc = instance.exports[\"f\"];\n return wrappedFunc;\n};\n\nvar wasmTableMirror = [];\n\n/** @type {WebAssembly.Table} */ var wasmTable = new WebAssembly.Table({\n \"initial\": 31,\n \"element\": \"anyfunc\"\n});\n\nvar getWasmTableEntry = funcPtr => {\n var func = wasmTableMirror[funcPtr];\n if (!func) {\n if (funcPtr >= wasmTableMirror.length) wasmTableMirror.length = funcPtr + 1;\n /** @suppress {checkTypes} */ wasmTableMirror[funcPtr] = func = wasmTable.get(funcPtr);\n }\n /** @suppress {checkTypes} */ assert(wasmTable.get(funcPtr) == func, \"JavaScript-side Wasm function table mirror is out of date!\");\n return func;\n};\n\nvar updateTableMap = (offset, count) => {\n if (functionsInTableMap) {\n for (var i = offset; i < offset + count; i++) {\n var item = getWasmTableEntry(i);\n // Ignore null values.\n if (item) {\n functionsInTableMap.set(item, i);\n }\n }\n }\n};\n\nvar functionsInTableMap;\n\nvar getFunctionAddress = func => {\n // First, create the map if this is the first use.\n if (!functionsInTableMap) {\n functionsInTableMap = new WeakMap;\n updateTableMap(0, wasmTable.length);\n }\n return functionsInTableMap.get(func) || 0;\n};\n\nvar freeTableIndexes = [];\n\nvar getEmptyTableSlot = () => {\n // Reuse a free index if there is one, otherwise grow.\n if (freeTableIndexes.length) {\n return freeTableIndexes.pop();\n }\n // Grow the table\n try {\n /** @suppress {checkTypes} */ wasmTable.grow(1);\n } catch (err) {\n if (!(err instanceof RangeError)) {\n throw err;\n }\n throw \"Unable to grow wasm table. Set ALLOW_TABLE_GROWTH.\";\n }\n return wasmTable.length - 1;\n};\n\nvar setWasmTableEntry = (idx, func) => {\n /** @suppress {checkTypes} */ wasmTable.set(idx, func);\n // With ABORT_ON_WASM_EXCEPTIONS wasmTable.get is overridden to return wrapped\n // functions so we need to call it here to retrieve the potential wrapper correctly\n // instead of just storing 'func' directly into wasmTableMirror\n /** @suppress {checkTypes} */ wasmTableMirror[idx] = wasmTable.get(idx);\n};\n\n/** @param {string=} sig */ var addFunction = (func, sig) => {\n assert(typeof func != \"undefined\");\n // Check if the function is already in the table, to ensure each function\n // gets a unique index.\n var rtn = getFunctionAddress(func);\n if (rtn) {\n return rtn;\n }\n // It's not in the table, add it now.\n var ret = getEmptyTableSlot();\n // Set the new value.\n try {\n // Attempting to call this with JS function will cause of table.set() to fail\n setWasmTableEntry(ret, func);\n } catch (err) {\n if (!(err instanceof TypeError)) {\n throw err;\n }\n assert(typeof sig != \"undefined\", \"Missing signature argument to addFunction: \" + func);\n var wrapped = convertJsFunctionToWasm(func, sig);\n setWasmTableEntry(ret, wrapped);\n }\n functionsInTableMap.set(func, ret);\n return ret;\n};\n\nvar updateGOT = (exports, replace) => {\n for (var symName in exports) {\n if (isInternalSym(symName)) {\n continue;\n }\n var value = exports[symName];\n GOT[symName] ||= new WebAssembly.Global({\n \"value\": \"i32\",\n \"mutable\": true\n });\n if (replace || GOT[symName].value == 0) {\n if (typeof value == \"function\") {\n GOT[symName].value = addFunction(value);\n } else if (typeof value == \"number\") {\n GOT[symName].value = value;\n } else {\n err(`unhandled export type for '${symName}': ${typeof value}`);\n }\n }\n }\n};\n\n/** @param {boolean=} replace */ var relocateExports = (exports, memoryBase, replace) => {\n var relocated = {};\n for (var e in exports) {\n var value = exports[e];\n if (typeof value == \"object\") {\n // a breaking change in the wasm spec, globals are now objects\n // https://github.com/WebAssembly/mutable-global/issues/1\n value = value.value;\n }\n if (typeof value == \"number\") {\n value += memoryBase;\n }\n relocated[e] = value;\n }\n updateGOT(relocated, replace);\n return relocated;\n};\n\nvar isSymbolDefined = symName => {\n // Ignore 'stub' symbols that are auto-generated as part of the original\n // `wasmImports` used to instantiate the main module.\n var existing = wasmImports[symName];\n if (!existing || existing.stub) {\n return false;\n }\n return true;\n};\n\nvar dynCall = (sig, ptr, args = []) => {\n assert(getWasmTableEntry(ptr), `missing table entry in dynCall: ${ptr}`);\n var rtn = getWasmTableEntry(ptr)(...args);\n return rtn;\n};\n\nvar stackSave = () => _emscripten_stack_get_current();\n\nvar stackRestore = val => __emscripten_stack_restore(val);\n\nvar createInvokeFunction = sig => (ptr, ...args) => {\n var sp = stackSave();\n try {\n return dynCall(sig, ptr, args);\n } catch (e) {\n stackRestore(sp);\n // Create a try-catch guard that rethrows the Emscripten EH exception.\n // Exceptions thrown from C++ will be a pointer (number) and longjmp\n // will throw the number Infinity. Use the compact and fast \"e !== e+0\"\n // test to check if e was not a Number.\n if (e !== e + 0) throw e;\n _setThrew(1, 0);\n // In theory this if statement could be done on\n // creating the function, but I just added this to\n // save wasting code space as it only happens on exception.\n if (sig[0] == \"j\") return 0n;\n }\n};\n\nvar resolveGlobalSymbol = (symName, direct = false) => {\n var sym;\n if (isSymbolDefined(symName)) {\n sym = wasmImports[symName];\n } else if (symName.startsWith(\"invoke_\")) {\n // Create (and cache) new invoke_ functions on demand.\n sym = wasmImports[symName] = createInvokeFunction(symName.split(\"_\")[1]);\n }\n return {\n sym,\n name: symName\n };\n};\n\nvar onPostCtors = [];\n\nvar addOnPostCtor = cb => onPostCtors.unshift(cb);\n\n/**\n * Given a pointer 'ptr' to a null-terminated UTF8-encoded string in the\n * emscripten HEAP, returns a copy of that string as a Javascript String object.\n *\n * @param {number} ptr\n * @param {number=} maxBytesToRead - An optional length that specifies the\n * maximum number of bytes to read. You can omit this parameter to scan the\n * string until the first 0 byte. If maxBytesToRead is passed, and the string\n * at [ptr, ptr+maxBytesToReadr[ contains a null byte in the middle, then the\n * string will cut short at that byte index (i.e. maxBytesToRead will not\n * produce a string of exact length [ptr, ptr+maxBytesToRead[) N.B. mixing\n * frequent uses of UTF8ToString() with and without maxBytesToRead may throw\n * JS JIT optimizations off, so it is worth to consider consistently using one\n * @return {string}\n */ var UTF8ToString = (ptr, maxBytesToRead) => {\n assert(typeof ptr == \"number\", `UTF8ToString expects a number (got ${typeof ptr})`);\n return ptr ? UTF8ArrayToString(HEAPU8, ptr, maxBytesToRead) : \"\";\n};\n\n/**\n * @param {string=} libName\n * @param {Object=} localScope\n * @param {number=} handle\n */ var loadWebAssemblyModule = (binary, flags, libName, localScope, handle) => {\n var metadata = getDylinkMetadata(binary);\n currentModuleWeakSymbols = metadata.weakImports;\n var originalTable = wasmTable;\n // loadModule loads the wasm module after all its dependencies have been loaded.\n // can be called both sync/async.\n function loadModule() {\n // alignments are powers of 2\n var memAlign = Math.pow(2, metadata.memoryAlign);\n // prepare memory\n var memoryBase = metadata.memorySize ? alignMemory(getMemory(metadata.memorySize + memAlign), memAlign) : 0;\n // TODO: add to cleanups\n var tableBase = metadata.tableSize ? wasmTable.length : 0;\n if (handle) {\n SAFE_HEAP_STORE((handle) + (8), 1, 1);\n LE_HEAP_STORE_U32((((handle) + (12)) >> 2) * 4, memoryBase);\n LE_HEAP_STORE_I32((((handle) + (16)) >> 2) * 4, metadata.memorySize);\n LE_HEAP_STORE_U32((((handle) + (20)) >> 2) * 4, tableBase);\n LE_HEAP_STORE_I32((((handle) + (24)) >> 2) * 4, metadata.tableSize);\n }\n if (metadata.tableSize) {\n assert(wasmTable.length == tableBase, `unexpected table size while loading ${libName}: ${wasmTable.length}`);\n wasmTable.grow(metadata.tableSize);\n }\n // This is the export map that we ultimately return. We declare it here\n // so it can be used within resolveSymbol. We resolve symbols against\n // this local symbol map in the case there they are not present on the\n // global Module object. We need this fallback because Modules sometime\n // need to import their own symbols\n var moduleExports;\n function resolveSymbol(sym) {\n var resolved = resolveGlobalSymbol(sym).sym;\n if (!resolved && localScope) {\n resolved = localScope[sym];\n }\n if (!resolved) {\n resolved = moduleExports[sym];\n }\n assert(resolved, `undefined symbol '${sym}'. perhaps a side module was not linked in? if this global was expected to arrive from a system library, try to build the MAIN_MODULE with EMCC_FORCE_STDLIBS=1 in the environment`);\n return resolved;\n }\n // TODO kill \u2193\u2193\u2193 (except \"symbols local to this module\", it will likely be\n // not needed if we require that if A wants symbols from B it has to link\n // to B explicitly: similarly to -Wl,--no-undefined)\n // wasm dynamic libraries are pure wasm, so they cannot assist in\n // their own loading. When side module A wants to import something\n // provided by a side module B that is loaded later, we need to\n // add a layer of indirection, but worse, we can't even tell what\n // to add the indirection for, without inspecting what A's imports\n // are. To do that here, we use a JS proxy (another option would\n // be to inspect the binary directly).\n var proxyHandler = {\n get(stubs, prop) {\n // symbols that should be local to this module\n switch (prop) {\n case \"__memory_base\":\n return memoryBase;\n\n case \"__table_base\":\n return tableBase;\n }\n if (prop in wasmImports && !wasmImports[prop].stub) {\n // No stub needed, symbol already exists in symbol table\n var res = wasmImports[prop];\n return res;\n }\n // Return a stub function that will resolve the symbol\n // when first called.\n if (!(prop in stubs)) {\n var resolved;\n stubs[prop] = (...args) => {\n resolved ||= resolveSymbol(prop);\n return resolved(...args);\n };\n }\n return stubs[prop];\n }\n };\n var proxy = new Proxy({}, proxyHandler);\n var info = {\n \"GOT.mem\": new Proxy({}, GOTHandler),\n \"GOT.func\": new Proxy({}, GOTHandler),\n \"env\": proxy,\n \"wasi_snapshot_preview1\": proxy\n };\n function postInstantiation(module, instance) {\n // the table should be unchanged\n assert(wasmTable === originalTable);\n // add new entries to functionsInTableMap\n updateTableMap(tableBase, metadata.tableSize);\n moduleExports = relocateExports(instance.exports, memoryBase);\n if (!flags.allowUndefined) {\n reportUndefinedSymbols();\n }\n function addEmAsm(addr, body) {\n var args = [];\n var arity = 0;\n for (;arity < 16; arity++) {\n if (body.indexOf(\"$\" + arity) != -1) {\n args.push(\"$\" + arity);\n } else {\n break;\n }\n }\n args = args.join(\",\");\n var func = `(${args}) => { ${body} };`;\n ASM_CONSTS[start] = eval(func);\n }\n // Add any EM_ASM function that exist in the side module\n if (\"__start_em_asm\" in moduleExports) {\n var start = moduleExports[\"__start_em_asm\"];\n var stop = moduleExports[\"__stop_em_asm\"];\n while (start < stop) {\n var jsString = UTF8ToString(start);\n addEmAsm(start, jsString);\n start = HEAPU8.indexOf(0, start) + 1;\n }\n }\n function addEmJs(name, cSig, body) {\n // The signature here is a C signature (e.g. \"(int foo, char* bar)\").\n // See `create_em_js` in emcc.py` for the build-time version of this\n // code.\n var jsArgs = [];\n cSig = cSig.slice(1, -1);\n if (cSig != \"void\") {\n cSig = cSig.split(\",\");\n for (var i in cSig) {\n var jsArg = cSig[i].split(\" \").pop();\n jsArgs.push(jsArg.replace(\"*\", \"\"));\n }\n }\n var func = `(${jsArgs}) => ${body};`;\n moduleExports[name] = eval(func);\n }\n for (var name in moduleExports) {\n if (name.startsWith(\"__em_js__\")) {\n var start = moduleExports[name];\n var jsString = UTF8ToString(start);\n // EM_JS strings are stored in the data section in the form\n // SIG<::>BODY.\n var parts = jsString.split(\"<::>\");\n addEmJs(name.replace(\"__em_js__\", \"\"), parts[0], parts[1]);\n delete moduleExports[name];\n }\n }\n // initialize the module\n var applyRelocs = moduleExports[\"__wasm_apply_data_relocs\"];\n if (applyRelocs) {\n if (runtimeInitialized) {\n applyRelocs();\n } else {\n __RELOC_FUNCS__.push(applyRelocs);\n }\n }\n var init = moduleExports[\"__wasm_call_ctors\"];\n if (init) {\n if (runtimeInitialized) {\n init();\n } else {\n // we aren't ready to run compiled code yet\n addOnPostCtor(init);\n }\n }\n return moduleExports;\n }\n if (flags.loadAsync) {\n if (binary instanceof WebAssembly.Module) {\n var instance = new WebAssembly.Instance(binary, info);\n return Promise.resolve(postInstantiation(binary, instance));\n }\n return WebAssembly.instantiate(binary, info).then(result => postInstantiation(result.module, result.instance));\n }\n var module = binary instanceof WebAssembly.Module ? binary : new WebAssembly.Module(binary);\n var instance = new WebAssembly.Instance(module, info);\n return postInstantiation(module, instance);\n }\n // now load needed libraries and the module itself.\n if (flags.loadAsync) {\n return metadata.neededDynlibs.reduce((chain, dynNeeded) => chain.then(() => loadDynamicLibrary(dynNeeded, flags, localScope)), Promise.resolve()).then(loadModule);\n }\n metadata.neededDynlibs.forEach(needed => loadDynamicLibrary(needed, flags, localScope));\n return loadModule();\n};\n\nvar mergeLibSymbols = (exports, libName) => {\n // add symbols into global namespace TODO: weak linking etc.\n for (var [sym, exp] of Object.entries(exports)) {\n // When RTLD_GLOBAL is enabled, the symbols defined by this shared object\n // will be made available for symbol resolution of subsequently loaded\n // shared objects.\n // We should copy the symbols (which include methods and variables) from\n // SIDE_MODULE to MAIN_MODULE.\n const setImport = target => {\n if (!isSymbolDefined(target)) {\n wasmImports[target] = exp;\n }\n };\n setImport(sym);\n // Special case for handling of main symbol: If a side module exports\n // `main` that also acts a definition for `__main_argc_argv` and vice\n // versa.\n const main_alias = \"__main_argc_argv\";\n if (sym == \"main\") {\n setImport(main_alias);\n }\n if (sym == main_alias) {\n setImport(\"main\");\n }\n }\n};\n\nvar asyncLoad = async url => {\n var arrayBuffer = await readAsync(url);\n assert(arrayBuffer, `Loading data file \"${url}\" failed (no arrayBuffer).`);\n return new Uint8Array(arrayBuffer);\n};\n\n/**\n * @param {number=} handle\n * @param {Object=} localScope\n */ function loadDynamicLibrary(libName, flags = {\n global: true,\n nodelete: true\n}, localScope, handle) {\n // when loadDynamicLibrary did not have flags, libraries were loaded\n // globally & permanently\n var dso = LDSO.loadedLibsByName[libName];\n if (dso) {\n // the library is being loaded or has been loaded already.\n assert(dso.exports !== \"loading\", `Attempt to load '${libName}' twice before the first load completed`);\n if (!flags.global) {\n if (localScope) {\n Object.assign(localScope, dso.exports);\n }\n } else if (!dso.global) {\n // The library was previously loaded only locally but not\n // we have a request with global=true.\n dso.global = true;\n mergeLibSymbols(dso.exports, libName);\n }\n // same for \"nodelete\"\n if (flags.nodelete && dso.refcount !== Infinity) {\n dso.refcount = Infinity;\n }\n dso.refcount++;\n if (handle) {\n LDSO.loadedLibsByHandle[handle] = dso;\n }\n return flags.loadAsync ? Promise.resolve(true) : true;\n }\n // allocate new DSO\n dso = newDSO(libName, handle, \"loading\");\n dso.refcount = flags.nodelete ? Infinity : 1;\n dso.global = flags.global;\n // libName -> libData\n function loadLibData() {\n // for wasm, we can use fetch for async, but for fs mode we can only imitate it\n if (handle) {\n var data = LE_HEAP_LOAD_U32((((handle) + (28)) >> 2) * 4);\n var dataSize = LE_HEAP_LOAD_U32((((handle) + (32)) >> 2) * 4);\n if (data && dataSize) {\n var libData = HEAP8.slice(data, data + dataSize);\n return flags.loadAsync ? Promise.resolve(libData) : libData;\n }\n }\n var libFile = locateFile(libName);\n if (flags.loadAsync) {\n return asyncLoad(libFile);\n }\n // load the binary synchronously\n if (!readBinary) {\n throw new Error(`${libFile}: file not found, and synchronous loading of external files is not available`);\n }\n return readBinary(libFile);\n }\n // libName -> exports\n function getExports() {\n // module not preloaded - load lib data and create new module from it\n if (flags.loadAsync) {\n return loadLibData().then(libData => loadWebAssemblyModule(libData, flags, libName, localScope, handle));\n }\n return loadWebAssemblyModule(loadLibData(), flags, libName, localScope, handle);\n }\n // module for lib is loaded - update the dso & global namespace\n function moduleLoaded(exports) {\n if (dso.global) {\n mergeLibSymbols(exports, libName);\n } else if (localScope) {\n Object.assign(localScope, exports);\n }\n dso.exports = exports;\n }\n if (flags.loadAsync) {\n return getExports().then(exports => {\n moduleLoaded(exports);\n return true;\n });\n }\n moduleLoaded(getExports());\n return true;\n}\n\nvar reportUndefinedSymbols = () => {\n for (var [symName, entry] of Object.entries(GOT)) {\n if (entry.value == 0) {\n var value = resolveGlobalSymbol(symName, true).sym;\n if (!value && !entry.required) {\n // Ignore undefined symbols that are imported as weak.\n continue;\n }\n assert(value, `undefined symbol '${symName}'. perhaps a side module was not linked in? if this global was expected to arrive from a system library, try to build the MAIN_MODULE with EMCC_FORCE_STDLIBS=1 in the environment`);\n if (typeof value == \"function\") {\n /** @suppress {checkTypes} */ entry.value = addFunction(value, value.sig);\n } else if (typeof value == \"number\") {\n entry.value = value;\n } else {\n throw new Error(`bad export type for '${symName}': ${typeof value}`);\n }\n }\n }\n};\n\nvar loadDylibs = () => {\n if (!dynamicLibraries.length) {\n reportUndefinedSymbols();\n return;\n }\n // Load binaries asynchronously\n addRunDependency(\"loadDylibs\");\n dynamicLibraries.reduce((chain, lib) => chain.then(() => loadDynamicLibrary(lib, {\n loadAsync: true,\n global: true,\n nodelete: true,\n allowUndefined: true\n })), Promise.resolve()).then(() => {\n // we got them all, wonderful\n reportUndefinedSymbols();\n removeRunDependency(\"loadDylibs\");\n });\n};\n\nvar noExitRuntime = Module[\"noExitRuntime\"] || true;\n\nvar ptrToString = ptr => {\n assert(typeof ptr === \"number\");\n // With CAN_ADDRESS_2GB or MEMORY64, pointers are already unsigned.\n ptr >>>= 0;\n return \"0x\" + ptr.toString(16).padStart(8, \"0\");\n};\n\n/**\n * @param {number} ptr\n * @param {number} value\n * @param {string} type\n */ function setValue(ptr, value, type = \"i8\") {\n if (type.endsWith(\"*\")) type = \"*\";\n switch (type) {\n case \"i1\":\n SAFE_HEAP_STORE(ptr, value, 1);\n break;\n\n case \"i8\":\n SAFE_HEAP_STORE(ptr, value, 1);\n break;\n\n case \"i16\":\n LE_HEAP_STORE_I16(((ptr) >> 1) * 2, value);\n break;\n\n case \"i32\":\n LE_HEAP_STORE_I32(((ptr) >> 2) * 4, value);\n break;\n\n case \"i64\":\n HEAP64[((ptr) >> 3)] = BigInt(value);\n break;\n\n case \"float\":\n LE_HEAP_STORE_F32(((ptr) >> 2) * 4, value);\n break;\n\n case \"double\":\n LE_HEAP_STORE_F64(((ptr) >> 3) * 8, value);\n break;\n\n case \"*\":\n LE_HEAP_STORE_U32(((ptr) >> 2) * 4, value);\n break;\n\n default:\n abort(`invalid type for setValue: ${type}`);\n }\n}\n\nfunction setValue_safe(ptr, value, type = \"i8\") {\n if (type.endsWith(\"*\")) type = \"*\";\n switch (type) {\n case \"i1\":\n HEAP8[ptr] = value;\n break;\n\n case \"i8\":\n HEAP8[ptr] = value;\n break;\n\n case \"i16\":\n LE_HEAP_STORE_I16(((ptr) >> 1) * 2, value);\n break;\n\n case \"i32\":\n LE_HEAP_STORE_I32(((ptr) >> 2) * 4, value);\n break;\n\n case \"i64\":\n HEAP64[((ptr) >> 3)] = BigInt(value);\n break;\n\n case \"float\":\n LE_HEAP_STORE_F32(((ptr) >> 2) * 4, value);\n break;\n\n case \"double\":\n LE_HEAP_STORE_F64(((ptr) >> 3) * 8, value);\n break;\n\n case \"*\":\n LE_HEAP_STORE_U32(((ptr) >> 2) * 4, value);\n break;\n\n default:\n abort(`invalid type for setValue: ${type}`);\n }\n}\n\nvar unSign = (value, bits) => {\n if (value >= 0) {\n return value;\n }\n // Need some trickery, since if bits == 32, we are right at the limit of the\n // bits JS uses in bitshifts\n return bits <= 32 ? 2 * Math.abs(1 << (bits - 1)) + value : Math.pow(2, bits) + value;\n};\n\nvar warnOnce = text => {\n warnOnce.shown ||= {};\n if (!warnOnce.shown[text]) {\n warnOnce.shown[text] = 1;\n if (ENVIRONMENT_IS_NODE) text = \"warning: \" + text;\n err(text);\n }\n};\n\nvar ___memory_base = new WebAssembly.Global({\n \"value\": \"i32\",\n \"mutable\": false\n}, 1024);\n\nvar ___stack_high = 78208;\n\nvar ___stack_low = 12672;\n\nvar ___stack_pointer = new WebAssembly.Global({\n \"value\": \"i32\",\n \"mutable\": true\n}, 78208);\n\nvar ___table_base = new WebAssembly.Global({\n \"value\": \"i32\",\n \"mutable\": false\n}, 1);\n\nvar __abort_js = () => abort(\"native code called abort()\");\n\n__abort_js.sig = \"v\";\n\nvar _emscripten_get_now = () => performance.now();\n\n_emscripten_get_now.sig = \"d\";\n\nvar _emscripten_date_now = () => Date.now();\n\n_emscripten_date_now.sig = \"d\";\n\nvar nowIsMonotonic = 1;\n\nvar checkWasiClock = clock_id => clock_id >= 0 && clock_id <= 3;\n\nvar INT53_MAX = 9007199254740992;\n\nvar INT53_MIN = -9007199254740992;\n\nvar bigintToI53Checked = num => (num < INT53_MIN || num > INT53_MAX) ? NaN : Number(num);\n\nfunction _clock_time_get(clk_id, ignored_precision, ptime) {\n ignored_precision = bigintToI53Checked(ignored_precision);\n if (!checkWasiClock(clk_id)) {\n return 28;\n }\n var now;\n // all wasi clocks but realtime are monotonic\n if (clk_id === 0) {\n now = _emscripten_date_now();\n } else if (nowIsMonotonic) {\n now = _emscripten_get_now();\n } else {\n return 52;\n }\n // \"now\" is in ms, and wasi times are in ns.\n var nsec = Math.round(now * 1e3 * 1e3);\n HEAP64[((ptime) >> 3)] = BigInt(nsec);\n return 0;\n}\n\n_clock_time_get.sig = \"iijp\";\n\nvar getHeapMax = () => // Stay one Wasm page short of 4GB: while e.g. Chrome is able to allocate\n// full 4GB Wasm memories, the size will wrap back to 0 bytes in Wasm side\n// for any code that deals with heap sizes, which would require special\n// casing all heap size related code to treat 0 specially.\n2147483648;\n\nvar growMemory = size => {\n var b = wasmMemory.buffer;\n var pages = ((size - b.byteLength + 65535) / 65536) | 0;\n try {\n // round size grow request up to wasm page size (fixed 64KB per spec)\n wasmMemory.grow(pages);\n // .grow() takes a delta compared to the previous size\n updateMemoryViews();\n return 1;\n } catch (e) {\n err(`growMemory: Attempted to grow heap from ${b.byteLength} bytes to ${size} bytes, but got error: ${e}`);\n }\n};\n\nvar _emscripten_resize_heap = requestedSize => {\n var oldSize = HEAPU8.length;\n // With CAN_ADDRESS_2GB or MEMORY64, pointers are already unsigned.\n requestedSize >>>= 0;\n // With multithreaded builds, races can happen (another thread might increase the size\n // in between), so return a failure, and let the caller retry.\n assert(requestedSize > oldSize);\n // Memory resize rules:\n // 1. Always increase heap size to at least the requested size, rounded up\n // to next page multiple.\n // 2a. If MEMORY_GROWTH_LINEAR_STEP == -1, excessively resize the heap\n // geometrically: increase the heap size according to\n // MEMORY_GROWTH_GEOMETRIC_STEP factor (default +20%), At most\n // overreserve by MEMORY_GROWTH_GEOMETRIC_CAP bytes (default 96MB).\n // 2b. If MEMORY_GROWTH_LINEAR_STEP != -1, excessively resize the heap\n // linearly: increase the heap size by at least\n // MEMORY_GROWTH_LINEAR_STEP bytes.\n // 3. Max size for the heap is capped at 2048MB-WASM_PAGE_SIZE, or by\n // MAXIMUM_MEMORY, or by ASAN limit, depending on which is smallest\n // 4. If we were unable to allocate as much memory, it may be due to\n // over-eager decision to excessively reserve due to (3) above.\n // Hence if an allocation fails, cut down on the amount of excess\n // growth, in an attempt to succeed to perform a smaller allocation.\n // A limit is set for how much we can grow. We should not exceed that\n // (the wasm binary specifies it, so if we tried, we'd fail anyhow).\n var maxHeapSize = getHeapMax();\n if (requestedSize > maxHeapSize) {\n err(`Cannot enlarge memory, requested ${requestedSize} bytes, but the limit is ${maxHeapSize} bytes!`);\n return false;\n }\n // Loop through potential heap size increases. If we attempt a too eager\n // reservation that fails, cut down on the attempted size and reserve a\n // smaller bump instead. (max 3 times, chosen somewhat arbitrarily)\n for (var cutDown = 1; cutDown <= 4; cutDown *= 2) {\n var overGrownHeapSize = oldSize * (1 + .2 / cutDown);\n // ensure geometric growth\n // but limit overreserving (default to capping at +96MB overgrowth at most)\n overGrownHeapSize = Math.min(overGrownHeapSize, requestedSize + 100663296);\n var newSize = Math.min(maxHeapSize, alignMemory(Math.max(requestedSize, overGrownHeapSize), 65536));\n var replacement = growMemory(newSize);\n if (replacement) {\n return true;\n }\n }\n err(`Failed to grow the heap from ${oldSize} bytes to ${newSize} bytes, not enough memory!`);\n return false;\n};\n\n_emscripten_resize_heap.sig = \"ip\";\n\nvar SYSCALLS = {\n varargs: undefined,\n getStr(ptr) {\n var ret = UTF8ToString(ptr);\n return ret;\n }\n};\n\nvar _fd_close = fd => {\n abort(\"fd_close called without SYSCALLS_REQUIRE_FILESYSTEM\");\n};\n\n_fd_close.sig = \"ii\";\n\nfunction _fd_seek(fd, offset, whence, newOffset) {\n offset = bigintToI53Checked(offset);\n return 70;\n}\n\n_fd_seek.sig = \"iijip\";\n\nvar printCharBuffers = [ null, [], [] ];\n\nvar printChar = (stream, curr) => {\n var buffer = printCharBuffers[stream];\n assert(buffer);\n if (curr === 0 || curr === 10) {\n (stream === 1 ? out : err)(UTF8ArrayToString(buffer));\n buffer.length = 0;\n } else {\n buffer.push(curr);\n }\n};\n\nvar flush_NO_FILESYSTEM = () => {\n // flush anything remaining in the buffers during shutdown\n _fflush(0);\n if (printCharBuffers[1].length) printChar(1, 10);\n if (printCharBuffers[2].length) printChar(2, 10);\n};\n\nvar _fd_write = (fd, iov, iovcnt, pnum) => {\n // hack to support printf in SYSCALLS_REQUIRE_FILESYSTEM=0\n var num = 0;\n for (var i = 0; i < iovcnt; i++) {\n var ptr = LE_HEAP_LOAD_U32(((iov) >> 2) * 4);\n var len = LE_HEAP_LOAD_U32((((iov) + (4)) >> 2) * 4);\n iov += 8;\n for (var j = 0; j < len; j++) {\n printChar(fd, SAFE_HEAP_LOAD(ptr + j, 1, 1));\n }\n num += len;\n }\n LE_HEAP_STORE_U32(((pnum) >> 2) * 4, num);\n return 0;\n};\n\n_fd_write.sig = \"iippp\";\n\nfunction _tree_sitter_log_callback(isLexMessage, messageAddress) {\n if (Module.currentLogCallback) {\n const message = UTF8ToString(messageAddress);\n Module.currentLogCallback(message, isLexMessage !== 0);\n }\n}\n\nfunction _tree_sitter_parse_callback(inputBufferAddress, index, row, column, lengthAddress) {\n const INPUT_BUFFER_SIZE = 10 * 1024;\n const string = Module.currentParseCallback(index, {\n row,\n column\n });\n if (typeof string === \"string\") {\n setValue(lengthAddress, string.length, \"i32\");\n stringToUTF16(string, inputBufferAddress, INPUT_BUFFER_SIZE);\n } else {\n setValue(lengthAddress, 0, \"i32\");\n }\n}\n\nfunction _tree_sitter_progress_callback(currentOffset, hasError) {\n if (Module.currentProgressCallback) {\n return Module.currentProgressCallback({\n currentOffset,\n hasError\n });\n }\n return false;\n}\n\nfunction _tree_sitter_query_progress_callback(currentOffset) {\n if (Module.currentQueryProgressCallback) {\n return Module.currentQueryProgressCallback({\n currentOffset\n });\n }\n return false;\n}\n\nvar runtimeKeepaliveCounter = 0;\n\nvar keepRuntimeAlive = () => noExitRuntime || runtimeKeepaliveCounter > 0;\n\nvar _proc_exit = code => {\n EXITSTATUS = code;\n if (!keepRuntimeAlive()) {\n Module[\"onExit\"]?.(code);\n ABORT = true;\n }\n quit_(code, new ExitStatus(code));\n};\n\n_proc_exit.sig = \"vi\";\n\n/** @param {boolean|number=} implicit */ var exitJS = (status, implicit) => {\n EXITSTATUS = status;\n checkUnflushedContent();\n // if exit() was called explicitly, warn the user if the runtime isn't actually being shut down\n if (keepRuntimeAlive() && !implicit) {\n var msg = `program exited (with status: ${status}), but keepRuntimeAlive() is set (counter=${runtimeKeepaliveCounter}) due to an async operation, so halting execution but not exiting the runtime or preventing further async execution (you can use emscripten_force_exit, if you want to force a true shutdown)`;\n readyPromiseReject(msg);\n err(msg);\n }\n _proc_exit(status);\n};\n\nvar handleException = e => {\n // Certain exception types we do not treat as errors since they are used for\n // internal control flow.\n // 1. ExitStatus, which is thrown by exit()\n // 2. \"unwind\", which is thrown by emscripten_unwind_to_js_event_loop() and others\n // that wish to return to JS event loop.\n if (e instanceof ExitStatus || e == \"unwind\") {\n return EXITSTATUS;\n }\n checkStackCookie();\n if (e instanceof WebAssembly.RuntimeError) {\n if (_emscripten_stack_get_current() <= 0) {\n err(\"Stack overflow detected. You can try increasing -sSTACK_SIZE (currently set to 65536)\");\n }\n }\n quit_(1, e);\n};\n\nvar lengthBytesUTF8 = str => {\n var len = 0;\n for (var i = 0; i < str.length; ++i) {\n // Gotcha: charCodeAt returns a 16-bit word that is a UTF-16 encoded code\n // unit, not a Unicode code point of the character! So decode\n // UTF16->UTF32->UTF8.\n // See http://unicode.org/faq/utf_bom.html#utf16-3\n var c = str.charCodeAt(i);\n // possibly a lead surrogate\n if (c <= 127) {\n len++;\n } else if (c <= 2047) {\n len += 2;\n } else if (c >= 55296 && c <= 57343) {\n len += 4;\n ++i;\n } else {\n len += 3;\n }\n }\n return len;\n};\n\nvar stringToUTF8Array = (str, heap, outIdx, maxBytesToWrite) => {\n assert(typeof str === \"string\", `stringToUTF8Array expects a string (got ${typeof str})`);\n // Parameter maxBytesToWrite is not optional. Negative values, 0, null,\n // undefined and false each don't write out any bytes.\n if (!(maxBytesToWrite > 0)) return 0;\n var startIdx = outIdx;\n var endIdx = outIdx + maxBytesToWrite - 1;\n // -1 for string null terminator.\n for (var i = 0; i < str.length; ++i) {\n // Gotcha: charCodeAt returns a 16-bit word that is a UTF-16 encoded code\n // unit, not a Unicode code point of the character! So decode\n // UTF16->UTF32->UTF8.\n // See http://unicode.org/faq/utf_bom.html#utf16-3\n // For UTF8 byte structure, see http://en.wikipedia.org/wiki/UTF-8#Description\n // and https://www.ietf.org/rfc/rfc2279.txt\n // and https://tools.ietf.org/html/rfc3629\n var u = str.charCodeAt(i);\n // possibly a lead surrogate\n if (u >= 55296 && u <= 57343) {\n var u1 = str.charCodeAt(++i);\n u = 65536 + ((u & 1023) << 10) | (u1 & 1023);\n }\n if (u <= 127) {\n if (outIdx >= endIdx) break;\n heap[outIdx++] = u;\n } else if (u <= 2047) {\n if (outIdx + 1 >= endIdx) break;\n heap[outIdx++] = 192 | (u >> 6);\n heap[outIdx++] = 128 | (u & 63);\n } else if (u <= 65535) {\n if (outIdx + 2 >= endIdx) break;\n heap[outIdx++] = 224 | (u >> 12);\n heap[outIdx++] = 128 | ((u >> 6) & 63);\n heap[outIdx++] = 128 | (u & 63);\n } else {\n if (outIdx + 3 >= endIdx) break;\n if (u > 1114111) warnOnce(\"Invalid Unicode code point \" + ptrToString(u) + \" encountered when serializing a JS string to a UTF-8 string in wasm memory! (Valid unicode code points should be in range 0-0x10FFFF).\");\n heap[outIdx++] = 240 | (u >> 18);\n heap[outIdx++] = 128 | ((u >> 12) & 63);\n heap[outIdx++] = 128 | ((u >> 6) & 63);\n heap[outIdx++] = 128 | (u & 63);\n }\n }\n // Null-terminate the pointer to the buffer.\n heap[outIdx] = 0;\n return outIdx - startIdx;\n};\n\nvar stringToUTF8 = (str, outPtr, maxBytesToWrite) => {\n assert(typeof maxBytesToWrite == \"number\", \"stringToUTF8(str, outPtr, maxBytesToWrite) is missing the third parameter that specifies the length of the output buffer!\");\n return stringToUTF8Array(str, HEAPU8, outPtr, maxBytesToWrite);\n};\n\nvar stackAlloc = sz => __emscripten_stack_alloc(sz);\n\nvar stringToUTF8OnStack = str => {\n var size = lengthBytesUTF8(str) + 1;\n var ret = stackAlloc(size);\n stringToUTF8(str, ret, size);\n return ret;\n};\n\nvar AsciiToString = ptr => {\n var str = \"\";\n while (1) {\n var ch = SAFE_HEAP_LOAD(ptr++, 1, 1);\n if (!ch) return str;\n str += String.fromCharCode(ch);\n }\n};\n\nvar stringToUTF16 = (str, outPtr, maxBytesToWrite) => {\n assert(outPtr % 2 == 0, \"Pointer passed to stringToUTF16 must be aligned to two bytes!\");\n assert(typeof maxBytesToWrite == \"number\", \"stringToUTF16(str, outPtr, maxBytesToWrite) is missing the third parameter that specifies the length of the output buffer!\");\n // Backwards compatibility: if max bytes is not specified, assume unsafe unbounded write is allowed.\n maxBytesToWrite ??= 2147483647;\n if (maxBytesToWrite < 2) return 0;\n maxBytesToWrite -= 2;\n // Null terminator.\n var startPtr = outPtr;\n var numCharsToWrite = (maxBytesToWrite < str.length * 2) ? (maxBytesToWrite / 2) : str.length;\n for (var i = 0; i < numCharsToWrite; ++i) {\n // charCodeAt returns a UTF-16 encoded code unit, so it can be directly written to the HEAP.\n var codeUnit = str.charCodeAt(i);\n // possibly a lead surrogate\n LE_HEAP_STORE_I16(((outPtr) >> 1) * 2, codeUnit);\n outPtr += 2;\n }\n // Null-terminate the pointer to the HEAP.\n LE_HEAP_STORE_I16(((outPtr) >> 1) * 2, 0);\n return outPtr - startPtr;\n};\n\nfunction checkIncomingModuleAPI() {\n ignoredModuleProp(\"fetchSettings\");\n}\n\nvar wasmImports = {\n /** @export */ __heap_base: ___heap_base,\n /** @export */ __indirect_function_table: wasmTable,\n /** @export */ __memory_base: ___memory_base,\n /** @export */ __stack_high: ___stack_high,\n /** @export */ __stack_low: ___stack_low,\n /** @export */ __stack_pointer: ___stack_pointer,\n /** @export */ __table_base: ___table_base,\n /** @export */ _abort_js: __abort_js,\n /** @export */ alignfault,\n /** @export */ clock_time_get: _clock_time_get,\n /** @export */ emscripten_resize_heap: _emscripten_resize_heap,\n /** @export */ fd_close: _fd_close,\n /** @export */ fd_seek: _fd_seek,\n /** @export */ fd_write: _fd_write,\n /** @export */ memory: wasmMemory,\n /** @export */ segfault,\n /** @export */ tree_sitter_log_callback: _tree_sitter_log_callback,\n /** @export */ tree_sitter_parse_callback: _tree_sitter_parse_callback,\n /** @export */ tree_sitter_progress_callback: _tree_sitter_progress_callback,\n /** @export */ tree_sitter_query_progress_callback: _tree_sitter_query_progress_callback\n};\n\nvar wasmExports = await createWasm();\n\nvar ___wasm_call_ctors = createExportWrapper(\"__wasm_call_ctors\", 0);\n\nvar _malloc = Module[\"_malloc\"] = createExportWrapper(\"malloc\", 1);\n\nvar _calloc = Module[\"_calloc\"] = createExportWrapper(\"calloc\", 2);\n\nvar _realloc = Module[\"_realloc\"] = createExportWrapper(\"realloc\", 2);\n\nvar _free = Module[\"_free\"] = createExportWrapper(\"free\", 1);\n\nvar _ts_language_symbol_count = Module[\"_ts_language_symbol_count\"] = createExportWrapper(\"ts_language_symbol_count\", 1);\n\nvar _ts_language_state_count = Module[\"_ts_language_state_count\"] = createExportWrapper(\"ts_language_state_count\", 1);\n\nvar _ts_language_version = Module[\"_ts_language_version\"] = createExportWrapper(\"ts_language_version\", 1);\n\nvar _ts_language_abi_version = Module[\"_ts_language_abi_version\"] = createExportWrapper(\"ts_language_abi_version\", 1);\n\nvar _ts_language_metadata = Module[\"_ts_language_metadata\"] = createExportWrapper(\"ts_language_metadata\", 1);\n\nvar _ts_language_name = Module[\"_ts_language_name\"] = createExportWrapper(\"ts_language_name\", 1);\n\nvar _ts_language_field_count = Module[\"_ts_language_field_count\"] = createExportWrapper(\"ts_language_field_count\", 1);\n\nvar _ts_language_next_state = Module[\"_ts_language_next_state\"] = createExportWrapper(\"ts_language_next_state\", 3);\n\nvar _ts_language_symbol_name = Module[\"_ts_language_symbol_name\"] = createExportWrapper(\"ts_language_symbol_name\", 2);\n\nvar _ts_language_symbol_for_name = Module[\"_ts_language_symbol_for_name\"] = createExportWrapper(\"ts_language_symbol_for_name\", 4);\n\nvar _strncmp = Module[\"_strncmp\"] = createExportWrapper(\"strncmp\", 3);\n\nvar _ts_language_symbol_type = Module[\"_ts_language_symbol_type\"] = createExportWrapper(\"ts_language_symbol_type\", 2);\n\nvar _ts_language_field_name_for_id = Module[\"_ts_language_field_name_for_id\"] = createExportWrapper(\"ts_language_field_name_for_id\", 2);\n\nvar _ts_lookahead_iterator_new = Module[\"_ts_lookahead_iterator_new\"] = createExportWrapper(\"ts_lookahead_iterator_new\", 2);\n\nvar _ts_lookahead_iterator_delete = Module[\"_ts_lookahead_iterator_delete\"] = createExportWrapper(\"ts_lookahead_iterator_delete\", 1);\n\nvar _ts_lookahead_iterator_reset_state = Module[\"_ts_lookahead_iterator_reset_state\"] = createExportWrapper(\"ts_lookahead_iterator_reset_state\", 2);\n\nvar _ts_lookahead_iterator_reset = Module[\"_ts_lookahead_iterator_reset\"] = createExportWrapper(\"ts_lookahead_iterator_reset\", 3);\n\nvar _ts_lookahead_iterator_next = Module[\"_ts_lookahead_iterator_next\"] = createExportWrapper(\"ts_lookahead_iterator_next\", 1);\n\nvar _ts_lookahead_iterator_current_symbol = Module[\"_ts_lookahead_iterator_current_symbol\"] = createExportWrapper(\"ts_lookahead_iterator_current_symbol\", 1);\n\nvar _ts_parser_delete = Module[\"_ts_parser_delete\"] = createExportWrapper(\"ts_parser_delete\", 1);\n\nvar _ts_parser_set_language = Module[\"_ts_parser_set_language\"] = createExportWrapper(\"ts_parser_set_language\", 2);\n\nvar _ts_parser_reset = Module[\"_ts_parser_reset\"] = createExportWrapper(\"ts_parser_reset\", 1);\n\nvar _ts_parser_timeout_micros = Module[\"_ts_parser_timeout_micros\"] = createExportWrapper(\"ts_parser_timeout_micros\", 1);\n\nvar _ts_parser_set_timeout_micros = Module[\"_ts_parser_set_timeout_micros\"] = createExportWrapper(\"ts_parser_set_timeout_micros\", 2);\n\nvar _ts_parser_set_included_ranges = Module[\"_ts_parser_set_included_ranges\"] = createExportWrapper(\"ts_parser_set_included_ranges\", 3);\n\nvar _ts_query_new = Module[\"_ts_query_new\"] = createExportWrapper(\"ts_query_new\", 5);\n\nvar _ts_query_delete = Module[\"_ts_query_delete\"] = createExportWrapper(\"ts_query_delete\", 1);\n\nvar _iswspace = Module[\"_iswspace\"] = createExportWrapper(\"iswspace\", 1);\n\nvar _ts_query_pattern_count = Module[\"_ts_query_pattern_count\"] = createExportWrapper(\"ts_query_pattern_count\", 1);\n\nvar _ts_query_capture_count = Module[\"_ts_query_capture_count\"] = createExportWrapper(\"ts_query_capture_count\", 1);\n\nvar _ts_query_string_count = Module[\"_ts_query_string_count\"] = createExportWrapper(\"ts_query_string_count\", 1);\n\nvar _ts_query_capture_name_for_id = Module[\"_ts_query_capture_name_for_id\"] = createExportWrapper(\"ts_query_capture_name_for_id\", 3);\n\nvar _ts_query_capture_quantifier_for_id = Module[\"_ts_query_capture_quantifier_for_id\"] = createExportWrapper(\"ts_query_capture_quantifier_for_id\", 3);\n\nvar _ts_query_string_value_for_id = Module[\"_ts_query_string_value_for_id\"] = createExportWrapper(\"ts_query_string_value_for_id\", 3);\n\nvar _ts_query_predicates_for_pattern = Module[\"_ts_query_predicates_for_pattern\"] = createExportWrapper(\"ts_query_predicates_for_pattern\", 3);\n\nvar _ts_query_start_byte_for_pattern = Module[\"_ts_query_start_byte_for_pattern\"] = createExportWrapper(\"ts_query_start_byte_for_pattern\", 2);\n\nvar _ts_query_end_byte_for_pattern = Module[\"_ts_query_end_byte_for_pattern\"] = createExportWrapper(\"ts_query_end_byte_for_pattern\", 2);\n\nvar _ts_query_is_pattern_rooted = Module[\"_ts_query_is_pattern_rooted\"] = createExportWrapper(\"ts_query_is_pattern_rooted\", 2);\n\nvar _ts_query_is_pattern_non_local = Module[\"_ts_query_is_pattern_non_local\"] = createExportWrapper(\"ts_query_is_pattern_non_local\", 2);\n\nvar _ts_query_is_pattern_guaranteed_at_step = Module[\"_ts_query_is_pattern_guaranteed_at_step\"] = createExportWrapper(\"ts_query_is_pattern_guaranteed_at_step\", 2);\n\nvar _ts_query_disable_capture = Module[\"_ts_query_disable_capture\"] = createExportWrapper(\"ts_query_disable_capture\", 3);\n\nvar _ts_query_disable_pattern = Module[\"_ts_query_disable_pattern\"] = createExportWrapper(\"ts_query_disable_pattern\", 2);\n\nvar _memcmp = Module[\"_memcmp\"] = createExportWrapper(\"memcmp\", 3);\n\nvar _ts_tree_copy = Module[\"_ts_tree_copy\"] = createExportWrapper(\"ts_tree_copy\", 1);\n\nvar _ts_tree_delete = Module[\"_ts_tree_delete\"] = createExportWrapper(\"ts_tree_delete\", 1);\n\nvar _iswalnum = Module[\"_iswalnum\"] = createExportWrapper(\"iswalnum\", 1);\n\nvar _ts_init = Module[\"_ts_init\"] = createExportWrapper(\"ts_init\", 0);\n\nvar _ts_parser_new_wasm = Module[\"_ts_parser_new_wasm\"] = createExportWrapper(\"ts_parser_new_wasm\", 0);\n\nvar _ts_parser_enable_logger_wasm = Module[\"_ts_parser_enable_logger_wasm\"] = createExportWrapper(\"ts_parser_enable_logger_wasm\", 2);\n\nvar _ts_parser_parse_wasm = Module[\"_ts_parser_parse_wasm\"] = createExportWrapper(\"ts_parser_parse_wasm\", 5);\n\nvar _ts_parser_included_ranges_wasm = Module[\"_ts_parser_included_ranges_wasm\"] = createExportWrapper(\"ts_parser_included_ranges_wasm\", 1);\n\nvar _ts_language_type_is_named_wasm = Module[\"_ts_language_type_is_named_wasm\"] = createExportWrapper(\"ts_language_type_is_named_wasm\", 2);\n\nvar _ts_language_type_is_visible_wasm = Module[\"_ts_language_type_is_visible_wasm\"] = createExportWrapper(\"ts_language_type_is_visible_wasm\", 2);\n\nvar _ts_language_supertypes_wasm = Module[\"_ts_language_supertypes_wasm\"] = createExportWrapper(\"ts_language_supertypes_wasm\", 1);\n\nvar _ts_language_subtypes_wasm = Module[\"_ts_language_subtypes_wasm\"] = createExportWrapper(\"ts_language_subtypes_wasm\", 2);\n\nvar _ts_tree_root_node_wasm = Module[\"_ts_tree_root_node_wasm\"] = createExportWrapper(\"ts_tree_root_node_wasm\", 1);\n\nvar _ts_tree_root_node_with_offset_wasm = Module[\"_ts_tree_root_node_with_offset_wasm\"] = createExportWrapper(\"ts_tree_root_node_with_offset_wasm\", 1);\n\nvar _ts_tree_edit_wasm = Module[\"_ts_tree_edit_wasm\"] = createExportWrapper(\"ts_tree_edit_wasm\", 1);\n\nvar _ts_tree_included_ranges_wasm = Module[\"_ts_tree_included_ranges_wasm\"] = createExportWrapper(\"ts_tree_included_ranges_wasm\", 1);\n\nvar _ts_tree_get_changed_ranges_wasm = Module[\"_ts_tree_get_changed_ranges_wasm\"] = createExportWrapper(\"ts_tree_get_changed_ranges_wasm\", 2);\n\nvar _ts_tree_cursor_new_wasm = Module[\"_ts_tree_cursor_new_wasm\"] = createExportWrapper(\"ts_tree_cursor_new_wasm\", 1);\n\nvar _ts_tree_cursor_copy_wasm = Module[\"_ts_tree_cursor_copy_wasm\"] = createExportWrapper(\"ts_tree_cursor_copy_wasm\", 1);\n\nvar _ts_tree_cursor_delete_wasm = Module[\"_ts_tree_cursor_delete_wasm\"] = createExportWrapper(\"ts_tree_cursor_delete_wasm\", 1);\n\nvar _ts_tree_cursor_reset_wasm = Module[\"_ts_tree_cursor_reset_wasm\"] = createExportWrapper(\"ts_tree_cursor_reset_wasm\", 1);\n\nvar _ts_tree_cursor_reset_to_wasm = Module[\"_ts_tree_cursor_reset_to_wasm\"] = createExportWrapper(\"ts_tree_cursor_reset_to_wasm\", 2);\n\nvar _ts_tree_cursor_goto_first_child_wasm = Module[\"_ts_tree_cursor_goto_first_child_wasm\"] = createExportWrapper(\"ts_tree_cursor_goto_first_child_wasm\", 1);\n\nvar _ts_tree_cursor_goto_last_child_wasm = Module[\"_ts_tree_cursor_goto_last_child_wasm\"] = createExportWrapper(\"ts_tree_cursor_goto_last_child_wasm\", 1);\n\nvar _ts_tree_cursor_goto_first_child_for_index_wasm = Module[\"_ts_tree_cursor_goto_first_child_for_index_wasm\"] = createExportWrapper(\"ts_tree_cursor_goto_first_child_for_index_wasm\", 1);\n\nvar _ts_tree_cursor_goto_first_child_for_position_wasm = Module[\"_ts_tree_cursor_goto_first_child_for_position_wasm\"] = createExportWrapper(\"ts_tree_cursor_goto_first_child_for_position_wasm\", 1);\n\nvar _ts_tree_cursor_goto_next_sibling_wasm = Module[\"_ts_tree_cursor_goto_next_sibling_wasm\"] = createExportWrapper(\"ts_tree_cursor_goto_next_sibling_wasm\", 1);\n\nvar _ts_tree_cursor_goto_previous_sibling_wasm = Module[\"_ts_tree_cursor_goto_previous_sibling_wasm\"] = createExportWrapper(\"ts_tree_cursor_goto_previous_sibling_wasm\", 1);\n\nvar _ts_tree_cursor_goto_descendant_wasm = Module[\"_ts_tree_cursor_goto_descendant_wasm\"] = createExportWrapper(\"ts_tree_cursor_goto_descendant_wasm\", 2);\n\nvar _ts_tree_cursor_goto_parent_wasm = Module[\"_ts_tree_cursor_goto_parent_wasm\"] = createExportWrapper(\"ts_tree_cursor_goto_parent_wasm\", 1);\n\nvar _ts_tree_cursor_current_node_type_id_wasm = Module[\"_ts_tree_cursor_current_node_type_id_wasm\"] = createExportWrapper(\"ts_tree_cursor_current_node_type_id_wasm\", 1);\n\nvar _ts_tree_cursor_current_node_state_id_wasm = Module[\"_ts_tree_cursor_current_node_state_id_wasm\"] = createExportWrapper(\"ts_tree_cursor_current_node_state_id_wasm\", 1);\n\nvar _ts_tree_cursor_current_node_is_named_wasm = Module[\"_ts_tree_cursor_current_node_is_named_wasm\"] = createExportWrapper(\"ts_tree_cursor_current_node_is_named_wasm\", 1);\n\nvar _ts_tree_cursor_current_node_is_missing_wasm = Module[\"_ts_tree_cursor_current_node_is_missing_wasm\"] = createExportWrapper(\"ts_tree_cursor_current_node_is_missing_wasm\", 1);\n\nvar _ts_tree_cursor_current_node_id_wasm = Module[\"_ts_tree_cursor_current_node_id_wasm\"] = createExportWrapper(\"ts_tree_cursor_current_node_id_wasm\", 1);\n\nvar _ts_tree_cursor_start_position_wasm = Module[\"_ts_tree_cursor_start_position_wasm\"] = createExportWrapper(\"ts_tree_cursor_start_position_wasm\", 1);\n\nvar _ts_tree_cursor_end_position_wasm = Module[\"_ts_tree_cursor_end_position_wasm\"] = createExportWrapper(\"ts_tree_cursor_end_position_wasm\", 1);\n\nvar _ts_tree_cursor_start_index_wasm = Module[\"_ts_tree_cursor_start_index_wasm\"] = createExportWrapper(\"ts_tree_cursor_start_index_wasm\", 1);\n\nvar _ts_tree_cursor_end_index_wasm = Module[\"_ts_tree_cursor_end_index_wasm\"] = createExportWrapper(\"ts_tree_cursor_end_index_wasm\", 1);\n\nvar _ts_tree_cursor_current_field_id_wasm = Module[\"_ts_tree_cursor_current_field_id_wasm\"] = createExportWrapper(\"ts_tree_cursor_current_field_id_wasm\", 1);\n\nvar _ts_tree_cursor_current_depth_wasm = Module[\"_ts_tree_cursor_current_depth_wasm\"] = createExportWrapper(\"ts_tree_cursor_current_depth_wasm\", 1);\n\nvar _ts_tree_cursor_current_descendant_index_wasm = Module[\"_ts_tree_cursor_current_descendant_index_wasm\"] = createExportWrapper(\"ts_tree_cursor_current_descendant_index_wasm\", 1);\n\nvar _ts_tree_cursor_current_node_wasm = Module[\"_ts_tree_cursor_current_node_wasm\"] = createExportWrapper(\"ts_tree_cursor_current_node_wasm\", 1);\n\nvar _ts_node_symbol_wasm = Module[\"_ts_node_symbol_wasm\"] = createExportWrapper(\"ts_node_symbol_wasm\", 1);\n\nvar _ts_node_field_name_for_child_wasm = Module[\"_ts_node_field_name_for_child_wasm\"] = createExportWrapper(\"ts_node_field_name_for_child_wasm\", 2);\n\nvar _ts_node_field_name_for_named_child_wasm = Module[\"_ts_node_field_name_for_named_child_wasm\"] = createExportWrapper(\"ts_node_field_name_for_named_child_wasm\", 2);\n\nvar _ts_node_children_by_field_id_wasm = Module[\"_ts_node_children_by_field_id_wasm\"] = createExportWrapper(\"ts_node_children_by_field_id_wasm\", 2);\n\nvar _ts_node_first_child_for_byte_wasm = Module[\"_ts_node_first_child_for_byte_wasm\"] = createExportWrapper(\"ts_node_first_child_for_byte_wasm\", 1);\n\nvar _ts_node_first_named_child_for_byte_wasm = Module[\"_ts_node_first_named_child_for_byte_wasm\"] = createExportWrapper(\"ts_node_first_named_child_for_byte_wasm\", 1);\n\nvar _ts_node_grammar_symbol_wasm = Module[\"_ts_node_grammar_symbol_wasm\"] = createExportWrapper(\"ts_node_grammar_symbol_wasm\", 1);\n\nvar _ts_node_child_count_wasm = Module[\"_ts_node_child_count_wasm\"] = createExportWrapper(\"ts_node_child_count_wasm\", 1);\n\nvar _ts_node_named_child_count_wasm = Module[\"_ts_node_named_child_count_wasm\"] = createExportWrapper(\"ts_node_named_child_count_wasm\", 1);\n\nvar _ts_node_child_wasm = Module[\"_ts_node_child_wasm\"] = createExportWrapper(\"ts_node_child_wasm\", 2);\n\nvar _ts_node_named_child_wasm = Module[\"_ts_node_named_child_wasm\"] = createExportWrapper(\"ts_node_named_child_wasm\", 2);\n\nvar _ts_node_child_by_field_id_wasm = Module[\"_ts_node_child_by_field_id_wasm\"] = createExportWrapper(\"ts_node_child_by_field_id_wasm\", 2);\n\nvar _ts_node_next_sibling_wasm = Module[\"_ts_node_next_sibling_wasm\"] = createExportWrapper(\"ts_node_next_sibling_wasm\", 1);\n\nvar _ts_node_prev_sibling_wasm = Module[\"_ts_node_prev_sibling_wasm\"] = createExportWrapper(\"ts_node_prev_sibling_wasm\", 1);\n\nvar _ts_node_next_named_sibling_wasm = Module[\"_ts_node_next_named_sibling_wasm\"] = createExportWrapper(\"ts_node_next_named_sibling_wasm\", 1);\n\nvar _ts_node_prev_named_sibling_wasm = Module[\"_ts_node_prev_named_sibling_wasm\"] = createExportWrapper(\"ts_node_prev_named_sibling_wasm\", 1);\n\nvar _ts_node_descendant_count_wasm = Module[\"_ts_node_descendant_count_wasm\"] = createExportWrapper(\"ts_node_descendant_count_wasm\", 1);\n\nvar _ts_node_parent_wasm = Module[\"_ts_node_parent_wasm\"] = createExportWrapper(\"ts_node_parent_wasm\", 1);\n\nvar _ts_node_child_with_descendant_wasm = Module[\"_ts_node_child_with_descendant_wasm\"] = createExportWrapper(\"ts_node_child_with_descendant_wasm\", 1);\n\nvar _ts_node_descendant_for_index_wasm = Module[\"_ts_node_descendant_for_index_wasm\"] = createExportWrapper(\"ts_node_descendant_for_index_wasm\", 1);\n\nvar _ts_node_named_descendant_for_index_wasm = Module[\"_ts_node_named_descendant_for_index_wasm\"] = createExportWrapper(\"ts_node_named_descendant_for_index_wasm\", 1);\n\nvar _ts_node_descendant_for_position_wasm = Module[\"_ts_node_descendant_for_position_wasm\"] = createExportWrapper(\"ts_node_descendant_for_position_wasm\", 1);\n\nvar _ts_node_named_descendant_for_position_wasm = Module[\"_ts_node_named_descendant_for_position_wasm\"] = createExportWrapper(\"ts_node_named_descendant_for_position_wasm\", 1);\n\nvar _ts_node_start_point_wasm = Module[\"_ts_node_start_point_wasm\"] = createExportWrapper(\"ts_node_start_point_wasm\", 1);\n\nvar _ts_node_end_point_wasm = Module[\"_ts_node_end_point_wasm\"] = createExportWrapper(\"ts_node_end_point_wasm\", 1);\n\nvar _ts_node_start_index_wasm = Module[\"_ts_node_start_index_wasm\"] = createExportWrapper(\"ts_node_start_index_wasm\", 1);\n\nvar _ts_node_end_index_wasm = Module[\"_ts_node_end_index_wasm\"] = createExportWrapper(\"ts_node_end_index_wasm\", 1);\n\nvar _ts_node_to_string_wasm = Module[\"_ts_node_to_string_wasm\"] = createExportWrapper(\"ts_node_to_string_wasm\", 1);\n\nvar _ts_node_children_wasm = Module[\"_ts_node_children_wasm\"] = createExportWrapper(\"ts_node_children_wasm\", 1);\n\nvar _ts_node_named_children_wasm = Module[\"_ts_node_named_children_wasm\"] = createExportWrapper(\"ts_node_named_children_wasm\", 1);\n\nvar _ts_node_descendants_of_type_wasm = Module[\"_ts_node_descendants_of_type_wasm\"] = createExportWrapper(\"ts_node_descendants_of_type_wasm\", 7);\n\nvar _ts_node_is_named_wasm = Module[\"_ts_node_is_named_wasm\"] = createExportWrapper(\"ts_node_is_named_wasm\", 1);\n\nvar _ts_node_has_changes_wasm = Module[\"_ts_node_has_changes_wasm\"] = createExportWrapper(\"ts_node_has_changes_wasm\", 1);\n\nvar _ts_node_has_error_wasm = Module[\"_ts_node_has_error_wasm\"] = createExportWrapper(\"ts_node_has_error_wasm\", 1);\n\nvar _ts_node_is_error_wasm = Module[\"_ts_node_is_error_wasm\"] = createExportWrapper(\"ts_node_is_error_wasm\", 1);\n\nvar _ts_node_is_missing_wasm = Module[\"_ts_node_is_missing_wasm\"] = createExportWrapper(\"ts_node_is_missing_wasm\", 1);\n\nvar _ts_node_is_extra_wasm = Module[\"_ts_node_is_extra_wasm\"] = createExportWrapper(\"ts_node_is_extra_wasm\", 1);\n\nvar _ts_node_parse_state_wasm = Module[\"_ts_node_parse_state_wasm\"] = createExportWrapper(\"ts_node_parse_state_wasm\", 1);\n\nvar _ts_node_next_parse_state_wasm = Module[\"_ts_node_next_parse_state_wasm\"] = createExportWrapper(\"ts_node_next_parse_state_wasm\", 1);\n\nvar _ts_query_matches_wasm = Module[\"_ts_query_matches_wasm\"] = createExportWrapper(\"ts_query_matches_wasm\", 11);\n\nvar _ts_query_captures_wasm = Module[\"_ts_query_captures_wasm\"] = createExportWrapper(\"ts_query_captures_wasm\", 11);\n\nvar _memset = Module[\"_memset\"] = createExportWrapper(\"memset\", 3);\n\nvar _memcpy = Module[\"_memcpy\"] = createExportWrapper(\"memcpy\", 3);\n\nvar _memmove = Module[\"_memmove\"] = createExportWrapper(\"memmove\", 3);\n\nvar _fflush = createExportWrapper(\"fflush\", 1);\n\nvar _strlen = Module[\"_strlen\"] = createExportWrapper(\"strlen\", 1);\n\nvar _iswalpha = Module[\"_iswalpha\"] = createExportWrapper(\"iswalpha\", 1);\n\nvar _iswblank = Module[\"_iswblank\"] = createExportWrapper(\"iswblank\", 1);\n\nvar _iswdigit = Module[\"_iswdigit\"] = createExportWrapper(\"iswdigit\", 1);\n\nvar _iswlower = Module[\"_iswlower\"] = createExportWrapper(\"iswlower\", 1);\n\nvar _iswupper = Module[\"_iswupper\"] = createExportWrapper(\"iswupper\", 1);\n\nvar _iswxdigit = Module[\"_iswxdigit\"] = createExportWrapper(\"iswxdigit\", 1);\n\nvar _memchr = Module[\"_memchr\"] = createExportWrapper(\"memchr\", 3);\n\nvar _strcmp = Module[\"_strcmp\"] = createExportWrapper(\"strcmp\", 2);\n\nvar _strncat = Module[\"_strncat\"] = createExportWrapper(\"strncat\", 3);\n\nvar _strncpy = Module[\"_strncpy\"] = createExportWrapper(\"strncpy\", 3);\n\nvar _towlower = Module[\"_towlower\"] = createExportWrapper(\"towlower\", 1);\n\nvar _towupper = Module[\"_towupper\"] = createExportWrapper(\"towupper\", 1);\n\nvar _sbrk = createExportWrapper(\"sbrk\", 1);\n\nvar _emscripten_get_sbrk_ptr = createExportWrapper(\"emscripten_get_sbrk_ptr\", 0);\n\nvar _setThrew = createExportWrapper(\"setThrew\", 2);\n\nvar _emscripten_stack_set_limits = wasmExports[\"emscripten_stack_set_limits\"];\n\nvar _emscripten_stack_get_free = wasmExports[\"emscripten_stack_get_free\"];\n\nvar _emscripten_stack_get_base = wasmExports[\"emscripten_stack_get_base\"];\n\nvar _emscripten_stack_get_end = wasmExports[\"emscripten_stack_get_end\"];\n\nvar __emscripten_stack_restore = wasmExports[\"_emscripten_stack_restore\"];\n\nvar __emscripten_stack_alloc = wasmExports[\"_emscripten_stack_alloc\"];\n\nvar _emscripten_stack_get_current = wasmExports[\"emscripten_stack_get_current\"];\n\nvar ___wasm_apply_data_relocs = createExportWrapper(\"__wasm_apply_data_relocs\", 0);\n\n// include: postamble.js\n// === Auto-generated postamble setup entry stuff ===\nModule[\"setValue\"] = setValue;\n\nModule[\"getValue\"] = getValue;\n\nModule[\"UTF8ToString\"] = UTF8ToString;\n\nModule[\"stringToUTF8\"] = stringToUTF8;\n\nModule[\"lengthBytesUTF8\"] = lengthBytesUTF8;\n\nModule[\"AsciiToString\"] = AsciiToString;\n\nModule[\"stringToUTF16\"] = stringToUTF16;\n\nModule[\"loadWebAssemblyModule\"] = loadWebAssemblyModule;\n\nvar missingLibrarySymbols = [ \"writeI53ToI64\", \"writeI53ToI64Clamped\", \"writeI53ToI64Signaling\", \"writeI53ToU64Clamped\", \"writeI53ToU64Signaling\", \"readI53FromI64\", \"readI53FromU64\", \"convertI32PairToI53\", \"convertI32PairToI53Checked\", \"convertU32PairToI53\", \"getTempRet0\", \"setTempRet0\", \"zeroMemory\", \"strError\", \"inetPton4\", \"inetNtop4\", \"inetPton6\", \"inetNtop6\", \"readSockaddr\", \"writeSockaddr\", \"emscriptenLog\", \"readEmAsmArgs\", \"runEmAsmFunction\", \"runMainThreadEmAsm\", \"jstoi_q\", \"getExecutableName\", \"listenOnce\", \"autoResumeAudioContext\", \"getDynCaller\", \"runtimeKeepalivePush\", \"runtimeKeepalivePop\", \"callUserCallback\", \"maybeExit\", \"asmjsMangle\", \"mmapAlloc\", \"HandleAllocator\", \"getNativeTypeSize\", \"addOnInit\", \"addOnPreMain\", \"addOnExit\", \"STACK_SIZE\", \"STACK_ALIGN\", \"POINTER_SIZE\", \"ASSERTIONS\", \"getCFunc\", \"ccall\", \"cwrap\", \"removeFunction\", \"reallyNegative\", \"strLen\", \"reSign\", \"formatString\", \"intArrayFromString\", \"intArrayToString\", \"stringToAscii\", \"UTF16ToString\", \"lengthBytesUTF16\", \"UTF32ToString\", \"stringToUTF32\", \"lengthBytesUTF32\", \"stringToNewUTF8\", \"writeArrayToMemory\", \"registerKeyEventCallback\", \"maybeCStringToJsString\", \"findEventTarget\", \"getBoundingClientRect\", \"fillMouseEventData\", \"registerMouseEventCallback\", \"registerWheelEventCallback\", \"registerUiEventCallback\", \"registerFocusEventCallback\", \"fillDeviceOrientationEventData\", \"registerDeviceOrientationEventCallback\", \"fillDeviceMotionEventData\", \"registerDeviceMotionEventCallback\", \"screenOrientation\", \"fillOrientationChangeEventData\", \"registerOrientationChangeEventCallback\", \"fillFullscreenChangeEventData\", \"registerFullscreenChangeEventCallback\", \"JSEvents_requestFullscreen\", \"JSEvents_resizeCanvasForFullscreen\", \"registerRestoreOldStyle\", \"hideEverythingExceptGivenElement\", \"restoreHiddenElements\", \"setLetterbox\", \"softFullscreenResizeWebGLRenderTarget\", \"doRequestFullscreen\", \"fillPointerlockChangeEventData\", \"registerPointerlockChangeEventCallback\", \"registerPointerlockErrorEventCallback\", \"requestPointerLock\", \"fillVisibilityChangeEventData\", \"registerVisibilityChangeEventCallback\", \"registerTouchEventCallback\", \"fillGamepadEventData\", \"registerGamepadEventCallback\", \"registerBeforeUnloadEventCallback\", \"fillBatteryEventData\", \"battery\", \"registerBatteryEventCallback\", \"setCanvasElementSize\", \"getCanvasElementSize\", \"jsStackTrace\", \"getCallstack\", \"convertPCtoSourceLocation\", \"getEnvStrings\", \"wasiRightsToMuslOFlags\", \"wasiOFlagsToMuslOFlags\", \"initRandomFill\", \"randomFill\", \"safeSetTimeout\", \"setImmediateWrapped\", \"safeRequestAnimationFrame\", \"clearImmediateWrapped\", \"registerPostMainLoop\", \"registerPreMainLoop\", \"getPromise\", \"makePromise\", \"idsToPromises\", \"makePromiseCallback\", \"Browser_asyncPrepareDataCounter\", \"isLeapYear\", \"ydayFromDate\", \"arraySum\", \"addDays\", \"getSocketFromFD\", \"getSocketAddress\", \"dlopenInternal\", \"heapObjectForWebGLType\", \"toTypedArrayIndex\", \"webgl_enable_ANGLE_instanced_arrays\", \"webgl_enable_OES_vertex_array_object\", \"webgl_enable_WEBGL_draw_buffers\", \"webgl_enable_WEBGL_multi_draw\", \"webgl_enable_EXT_polygon_offset_clamp\", \"webgl_enable_EXT_clip_control\", \"webgl_enable_WEBGL_polygon_mode\", \"emscriptenWebGLGet\", \"computeUnpackAlignedImageSize\", \"colorChannelsInGlTextureFormat\", \"emscriptenWebGLGetTexPixelData\", \"emscriptenWebGLGetUniform\", \"webglGetUniformLocation\", \"webglPrepareUniformLocationsBeforeFirstUse\", \"webglGetLeftBracePos\", \"emscriptenWebGLGetVertexAttrib\", \"__glGetActiveAttribOrUniform\", \"writeGLArray\", \"registerWebGlEventCallback\", \"runAndAbortIfError\", \"ALLOC_NORMAL\", \"ALLOC_STACK\", \"allocate\", \"writeStringToMemory\", \"writeAsciiToMemory\", \"setErrNo\", \"demangle\", \"stackTrace\" ];\n\nmissingLibrarySymbols.forEach(missingLibrarySymbol);\n\nvar unexportedSymbols = [ \"run\", \"addRunDependency\", \"removeRunDependency\", \"out\", \"err\", \"callMain\", \"abort\", \"wasmMemory\", \"wasmExports\", \"writeStackCookie\", \"checkStackCookie\", \"INT53_MAX\", \"INT53_MIN\", \"bigintToI53Checked\", \"stackSave\", \"stackRestore\", \"stackAlloc\", \"ptrToString\", \"exitJS\", \"getHeapMax\", \"growMemory\", \"ENV\", \"ERRNO_CODES\", \"DNS\", \"Protocols\", \"Sockets\", \"timers\", \"warnOnce\", \"readEmAsmArgsArray\", \"jstoi_s\", \"dynCall\", \"handleException\", \"keepRuntimeAlive\", \"asyncLoad\", \"alignMemory\", \"wasmTable\", \"noExitRuntime\", \"addOnPreRun\", \"addOnPostCtor\", \"addOnPostRun\", \"uleb128Encode\", \"sigToWasmTypes\", \"generateFuncType\", \"convertJsFunctionToWasm\", \"freeTableIndexes\", \"functionsInTableMap\", \"getEmptyTableSlot\", \"updateTableMap\", \"getFunctionAddress\", \"addFunction\", \"unSign\", \"PATH\", \"PATH_FS\", \"UTF8Decoder\", \"UTF8ArrayToString\", \"stringToUTF8Array\", \"UTF16Decoder\", \"stringToUTF8OnStack\", \"JSEvents\", \"specialHTMLTargets\", \"findCanvasEventTarget\", \"currentFullscreenStrategy\", \"restoreOldWindowedStyle\", \"UNWIND_CACHE\", \"ExitStatus\", \"checkWasiClock\", \"flush_NO_FILESYSTEM\", \"emSetImmediate\", \"emClearImmediate_deps\", \"emClearImmediate\", \"promiseMap\", \"Browser\", \"getPreloadedImageData__data\", \"wget\", \"MONTH_DAYS_REGULAR\", \"MONTH_DAYS_LEAP\", \"MONTH_DAYS_REGULAR_CUMULATIVE\", \"MONTH_DAYS_LEAP_CUMULATIVE\", \"SYSCALLS\", \"isSymbolDefined\", \"GOT\", \"currentModuleWeakSymbols\", \"LDSO\", \"getMemory\", \"mergeLibSymbols\", \"newDSO\", \"loadDynamicLibrary\", \"tempFixedLengthArray\", \"miniTempWebGLFloatBuffers\", \"miniTempWebGLIntBuffers\", \"GL\", \"AL\", \"GLUT\", \"EGL\", \"GLEW\", \"IDBStore\", \"SDL\", \"SDL_gfx\", \"allocateUTF8\", \"allocateUTF8OnStack\", \"print\", \"printErr\", \"LE_HEAP_STORE_U16\", \"LE_HEAP_STORE_I16\", \"LE_HEAP_STORE_U32\", \"LE_HEAP_STORE_I32\", \"LE_HEAP_STORE_F32\", \"LE_HEAP_STORE_F64\", \"LE_HEAP_LOAD_U16\", \"LE_HEAP_LOAD_I16\", \"LE_HEAP_LOAD_U32\", \"LE_HEAP_LOAD_I32\", \"LE_HEAP_LOAD_F32\", \"LE_HEAP_LOAD_F64\" ];\n\nunexportedSymbols.forEach(unexportedRuntimeSymbol);\n\nvar calledRun;\n\nfunction callMain(args = []) {\n assert(runDependencies == 0, 'cannot call main when async dependencies remain! (listen on Module[\"onRuntimeInitialized\"])');\n assert(typeof onPreRuns === \"undefined\" || onPreRuns.length == 0, \"cannot call main when preRun functions remain to be called\");\n var entryFunction = resolveGlobalSymbol(\"main\").sym;\n // Main modules can't tell if they have main() at compile time, since it may\n // arrive from a dynamic library.\n if (!entryFunction) return;\n args.unshift(thisProgram);\n var argc = args.length;\n var argv = stackAlloc((argc + 1) * 4);\n var argv_ptr = argv;\n args.forEach(arg => {\n LE_HEAP_STORE_U32(((argv_ptr) >> 2) * 4, stringToUTF8OnStack(arg));\n argv_ptr += 4;\n });\n LE_HEAP_STORE_U32(((argv_ptr) >> 2) * 4, 0);\n try {\n var ret = entryFunction(argc, argv);\n // if we're not running an evented main loop, it's time to exit\n exitJS(ret, /* implicit = */ true);\n return ret;\n } catch (e) {\n return handleException(e);\n }\n}\n\nfunction stackCheckInit() {\n // This is normally called automatically during __wasm_call_ctors but need to\n // get these values before even running any of the ctors so we call it redundantly\n // here.\n _emscripten_stack_set_limits(78208, 12672);\n // TODO(sbc): Move writeStackCookie to native to to avoid this.\n writeStackCookie();\n}\n\nfunction run(args = arguments_) {\n if (runDependencies > 0) {\n dependenciesFulfilled = run;\n return;\n }\n stackCheckInit();\n preRun();\n // a preRun added a dependency, run will be called later\n if (runDependencies > 0) {\n dependenciesFulfilled = run;\n return;\n }\n function doRun() {\n // run may have just been called through dependencies being fulfilled just in this very frame,\n // or while the async setStatus time below was happening\n assert(!calledRun);\n calledRun = true;\n Module[\"calledRun\"] = true;\n if (ABORT) return;\n initRuntime();\n preMain();\n readyPromiseResolve(Module);\n Module[\"onRuntimeInitialized\"]?.();\n consumedModuleProp(\"onRuntimeInitialized\");\n var noInitialRun = Module[\"noInitialRun\"];\n legacyModuleProp(\"noInitialRun\", \"noInitialRun\");\n if (!noInitialRun) callMain(args);\n postRun();\n }\n if (Module[\"setStatus\"]) {\n Module[\"setStatus\"](\"Running...\");\n setTimeout(() => {\n setTimeout(() => Module[\"setStatus\"](\"\"), 1);\n doRun();\n }, 1);\n } else {\n doRun();\n }\n checkStackCookie();\n}\n\nfunction checkUnflushedContent() {\n // Compiler settings do not allow exiting the runtime, so flushing\n // the streams is not possible. but in ASSERTIONS mode we check\n // if there was something to flush, and if so tell the user they\n // should request that the runtime be exitable.\n // Normally we would not even include flush() at all, but in ASSERTIONS\n // builds we do so just for this check, and here we see if there is any\n // content to flush, that is, we check if there would have been\n // something a non-ASSERTIONS build would have not seen.\n // How we flush the streams depends on whether we are in SYSCALLS_REQUIRE_FILESYSTEM=0\n // mode (which has its own special function for this; otherwise, all\n // the code is inside libc)\n var oldOut = out;\n var oldErr = err;\n var has = false;\n out = err = x => {\n has = true;\n };\n try {\n // it doesn't matter if it fails\n flush_NO_FILESYSTEM();\n } catch (e) {}\n out = oldOut;\n err = oldErr;\n if (has) {\n warnOnce(\"stdio streams had content in them that was not flushed. you should set EXIT_RUNTIME to 1 (see the Emscripten FAQ), or make sure to emit a newline when you printf etc.\");\n warnOnce(\"(this may also be due to not including full filesystem support - try building with -sFORCE_FILESYSTEM)\");\n }\n}\n\nif (Module[\"preInit\"]) {\n if (typeof Module[\"preInit\"] == \"function\") Module[\"preInit\"] = [ Module[\"preInit\"] ];\n while (Module[\"preInit\"].length > 0) {\n Module[\"preInit\"].pop()();\n }\n}\n\nconsumedModuleProp(\"preInit\");\n\nrun();\n\n// end include: postamble.js\n// include: postamble_modularize.js\n// In MODULARIZE mode we wrap the generated code in a factory function\n// and return either the Module itself, or a promise of the module.\n// We assign to the `moduleRtn` global here and configure closure to see\n// this as and extern so it won't get minified.\nmoduleRtn = readyPromise;\n\n// Assertion for attempting to access module properties on the incoming\n// moduleArg. In the past we used this object as the prototype of the module\n// and assigned properties to it, but now we return a distinct object. This\n// keeps the instance private until it is ready (i.e the promise has been\n// resolved).\nfor (const prop of Object.keys(Module)) {\n if (!(prop in moduleArg)) {\n Object.defineProperty(moduleArg, prop, {\n configurable: true,\n get() {\n abort(`Access to module property ('${prop}') is no longer possible via the module constructor argument; Instead, use the result of the module constructor.`);\n }\n });\n }\n}\n\n\n return moduleRtn;\n}\n);\n})();\n(() => {\n // Create a small, never-async wrapper around Module which\n // checks for callers incorrectly using it with `new`.\n var real_Module = Module;\n Module = function(arg) {\n if (new.target) throw new Error(\"Module() should not be called with `new Module()`\");\n return real_Module(arg);\n }\n})();\nif (typeof exports === 'object' && typeof module === 'object') {\n module.exports = Module;\n // This default export looks redundant, but it allows TS to import this\n // commonjs style module.\n module.exports.default = Module;\n} else if (typeof define === 'function' && define['amd'])\n define([], () => Module);\n", "export type {\n Point,\n Range,\n Edit,\n ParseCallback,\n ProgressCallback,\n LogCallback,\n} from './constants';\nexport {\n type ParseOptions,\n type ParseState,\n LANGUAGE_VERSION,\n MIN_COMPATIBLE_VERSION,\n Parser,\n} from './parser';\nexport { Language } from './language';\nexport { Tree } from './tree';\nexport { Node } from './node';\nexport { TreeCursor } from './tree_cursor';\nexport {\n type QueryOptions,\n type QueryState,\n type QueryProperties,\n type QueryPredicate,\n type QueryCapture,\n type QueryMatch,\n CaptureQuantifier,\n type PredicateStep,\n Query,\n} from './query';\nexport { LookaheadIterator } from './lookahead_iterator';\n", "import { type MainModule } from '../lib/tree-sitter';\n// eslint-disable-next-line @typescript-eslint/no-unused-vars\nimport { ParseState, type Parser } from './parser';\n\n/**\n * A position in a multi-line text document, in terms of rows and columns.\n *\n * Rows and columns are zero-based.\n */\nexport interface Point {\n /** The zero-based row number. */\n row: number;\n\n /** The zero-based column number. */\n column: number;\n}\n\n/**\n * A range of positions in a multi-line text document, both in terms of bytes\n * and of rows and columns.\n */\nexport interface Range {\n /** The start position of the range. */\n startPosition: Point;\n\n /** The end position of the range. */\n endPosition: Point;\n\n /** The start index of the range. */\n startIndex: number;\n\n /** The end index of the range. */\n endIndex: number;\n}\n\n/**\n * A summary of a change to a text document.\n */\nexport interface Edit {\n /** The start position of the change. */\n startPosition: Point;\n\n /** The end position of the change before the edit. */\n oldEndPosition: Point;\n\n /** The end position of the change after the edit. */\n newEndPosition: Point;\n\n /** The start index of the change. */\n startIndex: number;\n\n /** The end index of the change before the edit. */\n oldEndIndex: number;\n\n /** The end index of the change after the edit. */\n newEndIndex: number;\n}\n\n/** @internal */\nexport const SIZE_OF_SHORT = 2;\n\n/** @internal */\nexport const SIZE_OF_INT = 4;\n\n/** @internal */\nexport const SIZE_OF_CURSOR = 4 * SIZE_OF_INT;\n\n/** @internal */\nexport const SIZE_OF_NODE = 5 * SIZE_OF_INT;\n\n/** @internal */\nexport const SIZE_OF_POINT = 2 * SIZE_OF_INT;\n\n/** @internal */\nexport const SIZE_OF_RANGE = 2 * SIZE_OF_INT + 2 * SIZE_OF_POINT;\n\n/** @internal */\nexport const ZERO_POINT: Point = { row: 0, column: 0 };\n\n/**\n * A callback for parsing that takes an index and point, and should return a string.\n */\nexport type ParseCallback = (index: number, position: Point) => string | undefined;\n\n/**\n * A callback that receives the parse state during parsing.\n */\nexport type ProgressCallback = (progress: ParseState) => boolean;\n\n/**\n * A callback for logging messages.\n *\n * If `isLex` is `true`, the message is from the lexer, otherwise it's from the parser.\n */\nexport type LogCallback = (message: string, isLex: boolean) => void;\n\n// Helper type for internal use\n/** @internal */\nexport const INTERNAL = Symbol('INTERNAL');\n/** @internal */\nexport type Internal = typeof INTERNAL;\n\n// Helper functions for type checking\n/** @internal */\nexport function assertInternal(x: unknown): asserts x is Internal {\n if (x !== INTERNAL) throw new Error('Illegal constructor');\n}\n\n/** @internal */\nexport function isPoint(point?: Point): point is Point {\n return (\n !!point &&\n typeof (point).row === 'number' &&\n typeof (point).column === 'number'\n );\n}\n\n/**\n * @internal\n *\n * Sets the Tree-sitter WASM module. This should only be called by the {@link Parser} class via {@link Parser.init}.\n */\nexport function setModule(module: MainModule) {\n C = module;\n}\n\n/**\n * @internal\n *\n * `C` is a convenient shorthand for the Tree-sitter WASM module,\n * which allows us to call all of the exported functions.\n */\nexport let C: MainModule;\n", "import { C, Internal, assertInternal } from './constants';\nimport { Language } from './language';\n\nexport class LookaheadIterator implements Iterable<string> {\n /** @internal */\n private [0] = 0; // Internal handle for WASM\n\n /** @internal */\n private language: Language;\n\n /** @internal */\n constructor(internal: Internal, address: number, language: Language) {\n assertInternal(internal);\n this[0] = address;\n this.language = language;\n }\n\n /** Get the current symbol of the lookahead iterator. */\n get currentTypeId(): number {\n return C._ts_lookahead_iterator_current_symbol(this[0]);\n }\n\n /** Get the current symbol name of the lookahead iterator. */\n get currentType(): string {\n return this.language.types[this.currentTypeId] || 'ERROR';\n }\n\n /** Delete the lookahead iterator, freeing its resources. */\n delete(): void {\n C._ts_lookahead_iterator_delete(this[0]);\n this[0] = 0;\n }\n\n\n /**\n * Reset the lookahead iterator.\n *\n * This returns `true` if the language was set successfully and `false`\n * otherwise.\n */\n reset(language: Language, stateId: number): boolean {\n if (C._ts_lookahead_iterator_reset(this[0], language[0], stateId)) {\n this.language = language;\n return true;\n }\n return false;\n }\n\n /**\n * Reset the lookahead iterator to another state.\n *\n * This returns `true` if the iterator was reset to the given state and\n * `false` otherwise.\n */\n resetState(stateId: number): boolean {\n return Boolean(C._ts_lookahead_iterator_reset_state(this[0], stateId));\n }\n\n /**\n * Returns an iterator that iterates over the symbols of the lookahead iterator.\n *\n * The iterator will yield the current symbol name as a string for each step\n * until there are no more symbols to iterate over.\n */\n [Symbol.iterator](): Iterator<string> {\n return {\n next: (): IteratorResult<string> => {\n if (C._ts_lookahead_iterator_next(this[0])) {\n return { done: false, value: this.currentType };\n }\n return { done: true, value: '' };\n }\n };\n }\n}\n", "import { INTERNAL, Internal, assertInternal, ParseCallback, Point, Range, Edit, SIZE_OF_NODE, SIZE_OF_INT, SIZE_OF_RANGE, C } from './constants';\nimport { Language } from './language';\nimport { Node } from './node';\nimport { TreeCursor } from './tree_cursor';\nimport { marshalEdit, marshalPoint, unmarshalNode, unmarshalRange } from './marshal';\nimport { TRANSFER_BUFFER } from './parser';\n\n/** @internal */\nexport function getText(tree: Tree, startIndex: number, endIndex: number, startPosition: Point): string {\n const length = endIndex - startIndex;\n let result = tree.textCallback(startIndex, startPosition);\n if (result) {\n startIndex += result.length;\n while (startIndex < endIndex) {\n const string = tree.textCallback(startIndex, startPosition);\n if (string && string.length > 0) {\n startIndex += string.length;\n result += string;\n } else {\n break;\n }\n }\n if (startIndex > endIndex) {\n result = result.slice(0, length);\n }\n }\n return result ?? '';\n}\n\n/** A tree that represents the syntactic structure of a source code file. */\nexport class Tree {\n /** @internal */\n private [0] = 0; // Internal handle for WASM\n\n /** @internal */\n textCallback: ParseCallback;\n\n /** The language that was used to parse the syntax tree. */\n language: Language;\n\n /** @internal */\n constructor(internal: Internal, address: number, language: Language, textCallback: ParseCallback) {\n assertInternal(internal);\n this[0] = address;\n this.language = language;\n this.textCallback = textCallback;\n }\n\n /** Create a shallow copy of the syntax tree. This is very fast. */\n copy(): Tree {\n const address = C._ts_tree_copy(this[0]);\n return new Tree(INTERNAL, address, this.language, this.textCallback);\n }\n\n /** Delete the syntax tree, freeing its resources. */\n delete(): void {\n C._ts_tree_delete(this[0]);\n this[0] = 0;\n }\n\n /** Get the root node of the syntax tree. */\n get rootNode(): Node {\n C._ts_tree_root_node_wasm(this[0]);\n return unmarshalNode(this)!;\n }\n\n /**\n * Get the root node of the syntax tree, but with its position shifted\n * forward by the given offset.\n */\n rootNodeWithOffset(offsetBytes: number, offsetExtent: Point): Node {\n const address = TRANSFER_BUFFER + SIZE_OF_NODE;\n C.setValue(address, offsetBytes, 'i32');\n marshalPoint(address + SIZE_OF_INT, offsetExtent);\n C._ts_tree_root_node_with_offset_wasm(this[0]);\n return unmarshalNode(this)!;\n }\n\n /**\n * Edit the syntax tree to keep it in sync with source code that has been\n * edited.\n *\n * You must describe the edit both in terms of byte offsets and in terms of\n * row/column coordinates.\n */\n edit(edit: Edit): void {\n marshalEdit(edit);\n C._ts_tree_edit_wasm(this[0]);\n }\n\n /** Create a new {@link TreeCursor} starting from the root of the tree. */\n walk(): TreeCursor {\n return this.rootNode.walk();\n }\n\n /**\n * Compare this old edited syntax tree to a new syntax tree representing\n * the same document, returning a sequence of ranges whose syntactic\n * structure has changed.\n *\n * For this to work correctly, this syntax tree must have been edited such\n * that its ranges match up to the new tree. Generally, you'll want to\n * call this method right after calling one of the [`Parser::parse`]\n * functions. Call it on the old tree that was passed to parse, and\n * pass the new tree that was returned from `parse`.\n */\n getChangedRanges(other: Tree): Range[] {\n if (!(other instanceof Tree)) {\n throw new TypeError('Argument must be a Tree');\n }\n\n C._ts_tree_get_changed_ranges_wasm(this[0], other[0]);\n const count = C.getValue(TRANSFER_BUFFER, 'i32');\n const buffer = C.getValue(TRANSFER_BUFFER + SIZE_OF_INT, 'i32');\n const result = new Array<Range>(count);\n\n if (count > 0) {\n let address = buffer;\n for (let i = 0; i < count; i++) {\n result[i] = unmarshalRange(address);\n address += SIZE_OF_RANGE;\n }\n C._free(buffer);\n }\n return result;\n }\n\n /** Get the included ranges that were used to parse the syntax tree. */\n getIncludedRanges(): Range[] {\n C._ts_tree_included_ranges_wasm(this[0]);\n const count = C.getValue(TRANSFER_BUFFER, 'i32');\n const buffer = C.getValue(TRANSFER_BUFFER + SIZE_OF_INT, 'i32');\n const result = new Array<Range>(count);\n\n if (count > 0) {\n let address = buffer;\n for (let i = 0; i < count; i++) {\n result[i] = unmarshalRange(address);\n address += SIZE_OF_RANGE;\n }\n C._free(buffer);\n }\n return result;\n }\n}\n", "import { INTERNAL, Internal, assertInternal, Point, SIZE_OF_NODE, SIZE_OF_CURSOR, C } from './constants';\nimport { marshalNode, marshalPoint, marshalTreeCursor, unmarshalNode, unmarshalPoint, unmarshalTreeCursor } from './marshal';\nimport { Node } from './node';\nimport { TRANSFER_BUFFER } from './parser';\nimport { getText, Tree } from './tree';\n\n/** A stateful object for walking a syntax {@link Tree} efficiently. */\nexport class TreeCursor {\n /** @internal */\n // @ts-expect-error: never read\n private [0] = 0; // Internal handle for Wasm\n\n /** @internal */\n // @ts-expect-error: never read\n private [1] = 0; // Internal handle for Wasm\n\n /** @internal */\n // @ts-expect-error: never read\n private [2] = 0; // Internal handle for Wasm\n\n /** @internal */\n // @ts-expect-error: never read\n private [3] = 0; // Internal handle for Wasm\n\n /** @internal */\n private tree: Tree;\n\n /** @internal */\n constructor(internal: Internal, tree: Tree) {\n assertInternal(internal);\n this.tree = tree;\n unmarshalTreeCursor(this);\n }\n\n /** Creates a deep copy of the tree cursor. This allocates new memory. */\n copy(): TreeCursor {\n const copy = new TreeCursor(INTERNAL, this.tree);\n C._ts_tree_cursor_copy_wasm(this.tree[0]);\n unmarshalTreeCursor(copy);\n return copy;\n }\n\n /** Delete the tree cursor, freeing its resources. */\n delete(): void {\n marshalTreeCursor(this);\n C._ts_tree_cursor_delete_wasm(this.tree[0]);\n this[0] = this[1] = this[2] = 0;\n }\n\n /** Get the tree cursor's current {@link Node}. */\n get currentNode(): Node {\n marshalTreeCursor(this);\n C._ts_tree_cursor_current_node_wasm(this.tree[0]);\n return unmarshalNode(this.tree)!;\n }\n\n /**\n * Get the numerical field id of this tree cursor's current node.\n *\n * See also {@link TreeCursor#currentFieldName}.\n */\n get currentFieldId(): number {\n marshalTreeCursor(this);\n return C._ts_tree_cursor_current_field_id_wasm(this.tree[0]);\n }\n\n /** Get the field name of this tree cursor's current node. */\n get currentFieldName(): string | null {\n return this.tree.language.fields[this.currentFieldId];\n }\n\n /**\n * Get the depth of the cursor's current node relative to the original\n * node that the cursor was constructed with.\n */\n get currentDepth(): number {\n marshalTreeCursor(this);\n return C._ts_tree_cursor_current_depth_wasm(this.tree[0]);\n }\n\n /**\n * Get the index of the cursor's current node out of all of the\n * descendants of the original node that the cursor was constructed with.\n */\n get currentDescendantIndex(): number {\n marshalTreeCursor(this);\n return C._ts_tree_cursor_current_descendant_index_wasm(this.tree[0]);\n }\n\n /** Get the type of the cursor's current node. */\n get nodeType(): string {\n return this.tree.language.types[this.nodeTypeId] || 'ERROR';\n }\n\n /** Get the type id of the cursor's current node. */\n get nodeTypeId(): number {\n marshalTreeCursor(this);\n return C._ts_tree_cursor_current_node_type_id_wasm(this.tree[0]);\n }\n\n /** Get the state id of the cursor's current node. */\n get nodeStateId(): number {\n marshalTreeCursor(this);\n return C._ts_tree_cursor_current_node_state_id_wasm(this.tree[0]);\n }\n\n /** Get the id of the cursor's current node. */\n get nodeId(): number {\n marshalTreeCursor(this);\n return C._ts_tree_cursor_current_node_id_wasm(this.tree[0]);\n }\n\n /**\n * Check if the cursor's current node is *named*.\n *\n * Named nodes correspond to named rules in the grammar, whereas\n * *anonymous* nodes correspond to string literals in the grammar.\n */\n get nodeIsNamed(): boolean {\n marshalTreeCursor(this);\n return C._ts_tree_cursor_current_node_is_named_wasm(this.tree[0]) === 1;\n }\n\n /**\n * Check if the cursor's current node is *missing*.\n *\n * Missing nodes are inserted by the parser in order to recover from\n * certain kinds of syntax errors.\n */\n get nodeIsMissing(): boolean {\n marshalTreeCursor(this);\n return C._ts_tree_cursor_current_node_is_missing_wasm(this.tree[0]) === 1;\n }\n\n /** Get the string content of the cursor's current node. */\n get nodeText(): string {\n marshalTreeCursor(this);\n const startIndex = C._ts_tree_cursor_start_index_wasm(this.tree[0]);\n const endIndex = C._ts_tree_cursor_end_index_wasm(this.tree[0]);\n C._ts_tree_cursor_start_position_wasm(this.tree[0]);\n const startPosition = unmarshalPoint(TRANSFER_BUFFER);\n return getText(this.tree, startIndex, endIndex, startPosition);\n }\n\n /** Get the start position of the cursor's current node. */\n get startPosition(): Point {\n marshalTreeCursor(this);\n C._ts_tree_cursor_start_position_wasm(this.tree[0]);\n return unmarshalPoint(TRANSFER_BUFFER);\n }\n\n /** Get the end position of the cursor's current node. */\n get endPosition(): Point {\n marshalTreeCursor(this);\n C._ts_tree_cursor_end_position_wasm(this.tree[0]);\n return unmarshalPoint(TRANSFER_BUFFER);\n }\n\n /** Get the start index of the cursor's current node. */\n get startIndex(): number {\n marshalTreeCursor(this);\n return C._ts_tree_cursor_start_index_wasm(this.tree[0]);\n }\n\n /** Get the end index of the cursor's current node. */\n get endIndex(): number {\n marshalTreeCursor(this);\n return C._ts_tree_cursor_end_index_wasm(this.tree[0]);\n }\n\n /**\n * Move this cursor to the first child of its current node.\n *\n * This returns `true` if the cursor successfully moved, and returns\n * `false` if there were no children.\n */\n gotoFirstChild(): boolean {\n marshalTreeCursor(this);\n const result = C._ts_tree_cursor_goto_first_child_wasm(this.tree[0]);\n unmarshalTreeCursor(this);\n return result === 1;\n }\n\n /**\n * Move this cursor to the last child of its current node.\n *\n * This returns `true` if the cursor successfully moved, and returns\n * `false` if there were no children.\n *\n * Note that this function may be slower than\n * {@link TreeCursor#gotoFirstChild} because it needs to\n * iterate through all the children to compute the child's position.\n */\n gotoLastChild(): boolean {\n marshalTreeCursor(this);\n const result = C._ts_tree_cursor_goto_last_child_wasm(this.tree[0]);\n unmarshalTreeCursor(this);\n return result === 1;\n }\n\n /**\n * Move this cursor to the parent of its current node.\n *\n * This returns `true` if the cursor successfully moved, and returns\n * `false` if there was no parent node (the cursor was already on the\n * root node).\n *\n * Note that the node the cursor was constructed with is considered the root\n * of the cursor, and the cursor cannot walk outside this node.\n */\n gotoParent(): boolean {\n marshalTreeCursor(this);\n const result = C._ts_tree_cursor_goto_parent_wasm(this.tree[0]);\n unmarshalTreeCursor(this);\n return result === 1;\n }\n\n /**\n * Move this cursor to the next sibling of its current node.\n *\n * This returns `true` if the cursor successfully moved, and returns\n * `false` if there was no next sibling node.\n *\n * Note that the node the cursor was constructed with is considered the root\n * of the cursor, and the cursor cannot walk outside this node.\n */\n gotoNextSibling(): boolean {\n marshalTreeCursor(this);\n const result = C._ts_tree_cursor_goto_next_sibling_wasm(this.tree[0]);\n unmarshalTreeCursor(this);\n return result === 1;\n }\n\n /**\n * Move this cursor to the previous sibling of its current node.\n *\n * This returns `true` if the cursor successfully moved, and returns\n * `false` if there was no previous sibling node.\n *\n * Note that this function may be slower than\n * {@link TreeCursor#gotoNextSibling} due to how node\n * positions are stored. In the worst case, this will need to iterate\n * through all the children up to the previous sibling node to recalculate\n * its position. Also note that the node the cursor was constructed with is\n * considered the root of the cursor, and the cursor cannot walk outside this node.\n */\n gotoPreviousSibling(): boolean {\n marshalTreeCursor(this);\n const result = C._ts_tree_cursor_goto_previous_sibling_wasm(this.tree[0]);\n unmarshalTreeCursor(this);\n return result === 1;\n }\n\n /**\n * Move the cursor to the node that is the nth descendant of\n * the original node that the cursor was constructed with, where\n * zero represents the original node itself.\n */\n gotoDescendant(goalDescendantIndex: number): void {\n marshalTreeCursor(this);\n C._ts_tree_cursor_goto_descendant_wasm(this.tree[0], goalDescendantIndex);\n unmarshalTreeCursor(this);\n }\n\n /**\n * Move this cursor to the first child of its current node that contains or\n * starts after the given byte offset.\n *\n * This returns `true` if the cursor successfully moved to a child node, and returns\n * `false` if no such child was found.\n */\n gotoFirstChildForIndex(goalIndex: number): boolean {\n marshalTreeCursor(this);\n C.setValue(TRANSFER_BUFFER + SIZE_OF_CURSOR, goalIndex, 'i32');\n const result = C._ts_tree_cursor_goto_first_child_for_index_wasm(this.tree[0]);\n unmarshalTreeCursor(this);\n return result === 1;\n }\n\n /**\n * Move this cursor to the first child of its current node that contains or\n * starts after the given byte offset.\n *\n * This returns the index of the child node if one was found, and returns\n * `null` if no such child was found.\n */\n gotoFirstChildForPosition(goalPosition: Point): boolean {\n marshalTreeCursor(this);\n marshalPoint(TRANSFER_BUFFER + SIZE_OF_CURSOR, goalPosition);\n const result = C._ts_tree_cursor_goto_first_child_for_position_wasm(this.tree[0]);\n unmarshalTreeCursor(this);\n return result === 1;\n }\n\n /**\n * Re-initialize this tree cursor to start at the original node that the\n * cursor was constructed with.\n */\n reset(node: Node): void {\n marshalNode(node);\n marshalTreeCursor(this, TRANSFER_BUFFER + SIZE_OF_NODE);\n C._ts_tree_cursor_reset_wasm(this.tree[0]);\n unmarshalTreeCursor(this);\n }\n\n /**\n * Re-initialize a tree cursor to the same position as another cursor.\n *\n * Unlike {@link TreeCursor#reset}, this will not lose parent\n * information and allows reusing already created cursors.\n */\n resetTo(cursor: TreeCursor): void {\n marshalTreeCursor(this, TRANSFER_BUFFER);\n marshalTreeCursor(cursor, TRANSFER_BUFFER + SIZE_OF_CURSOR);\n C._ts_tree_cursor_reset_to_wasm(this.tree[0], cursor.tree[0]);\n unmarshalTreeCursor(this);\n }\n}\n", "import { INTERNAL, Internal, assertInternal, Point, Edit, SIZE_OF_INT, SIZE_OF_NODE, SIZE_OF_POINT, ZERO_POINT, isPoint, C } from './constants';\nimport { getText, Tree } from './tree';\nimport { TreeCursor } from './tree_cursor';\n// eslint-disable-next-line @typescript-eslint/no-unused-vars\nimport { Language } from './language';\nimport { marshalNode, marshalPoint, unmarshalNode, unmarshalPoint } from './marshal';\nimport { TRANSFER_BUFFER } from './parser';\n\n/** A single node within a syntax {@link Tree}. */\nexport class Node {\n /** @internal */\n // @ts-expect-error: never read\n private [0] = 0; // Internal handle for Wasm\n\n /** @internal */\n private _children?: (Node | null)[];\n\n /** @internal */\n private _namedChildren?: (Node | null)[];\n\n /** @internal */\n constructor(\n internal: Internal,\n {\n id,\n tree,\n startIndex,\n startPosition,\n other,\n }: {\n id: number;\n tree: Tree;\n startIndex: number;\n startPosition: Point;\n other: number;\n }\n ) {\n assertInternal(internal);\n this[0] = other;\n this.id = id;\n this.tree = tree;\n this.startIndex = startIndex;\n this.startPosition = startPosition;\n }\n\n /**\n * The numeric id for this node that is unique.\n *\n * Within a given syntax tree, no two nodes have the same id. However:\n *\n * * If a new tree is created based on an older tree, and a node from the old tree is reused in\n * the process, then that node will have the same id in both trees.\n *\n * * A node not marked as having changes does not guarantee it was reused.\n *\n * * If a node is marked as having changed in the old tree, it will not be reused.\n */\n id: number;\n\n /** The byte index where this node starts. */\n startIndex: number;\n\n /** The position where this node starts. */\n startPosition: Point;\n\n /** The tree that this node belongs to. */\n tree: Tree;\n\n /** Get this node's type as a numerical id. */\n get typeId(): number {\n marshalNode(this);\n return C._ts_node_symbol_wasm(this.tree[0]);\n }\n\n /**\n * Get the node's type as a numerical id as it appears in the grammar,\n * ignoring aliases.\n */\n get grammarId(): number {\n marshalNode(this);\n return C._ts_node_grammar_symbol_wasm(this.tree[0]);\n }\n\n /** Get this node's type as a string. */\n get type(): string {\n return this.tree.language.types[this.typeId] || 'ERROR';\n }\n\n /**\n * Get this node's symbol name as it appears in the grammar, ignoring\n * aliases as a string.\n */\n get grammarType(): string {\n return this.tree.language.types[this.grammarId] || 'ERROR';\n }\n\n /**\n * Check if this node is *named*.\n *\n * Named nodes correspond to named rules in the grammar, whereas\n * *anonymous* nodes correspond to string literals in the grammar.\n */\n get isNamed(): boolean {\n marshalNode(this);\n return C._ts_node_is_named_wasm(this.tree[0]) === 1;\n }\n\n /**\n * Check if this node is *extra*.\n *\n * Extra nodes represent things like comments, which are not required\n * by the grammar, but can appear anywhere.\n */\n get isExtra(): boolean {\n marshalNode(this);\n return C._ts_node_is_extra_wasm(this.tree[0]) === 1;\n }\n\n /**\n * Check if this node represents a syntax error.\n *\n * Syntax errors represent parts of the code that could not be incorporated\n * into a valid syntax tree.\n */\n get isError(): boolean {\n marshalNode(this);\n return C._ts_node_is_error_wasm(this.tree[0]) === 1;\n }\n\n /**\n * Check if this node is *missing*.\n *\n * Missing nodes are inserted by the parser in order to recover from\n * certain kinds of syntax errors.\n */\n get isMissing(): boolean {\n marshalNode(this);\n return C._ts_node_is_missing_wasm(this.tree[0]) === 1;\n }\n\n /** Check if this node has been edited. */\n get hasChanges(): boolean {\n marshalNode(this);\n return C._ts_node_has_changes_wasm(this.tree[0]) === 1;\n }\n\n /**\n * Check if this node represents a syntax error or contains any syntax\n * errors anywhere within it.\n */\n get hasError(): boolean {\n marshalNode(this);\n return C._ts_node_has_error_wasm(this.tree[0]) === 1;\n }\n\n /** Get the byte index where this node ends. */\n get endIndex(): number {\n marshalNode(this);\n return C._ts_node_end_index_wasm(this.tree[0]);\n }\n\n /** Get the position where this node ends. */\n get endPosition(): Point {\n marshalNode(this);\n C._ts_node_end_point_wasm(this.tree[0]);\n return unmarshalPoint(TRANSFER_BUFFER);\n }\n\n /** Get the string content of this node. */\n get text(): string {\n return getText(this.tree, this.startIndex, this.endIndex, this.startPosition);\n }\n\n /** Get this node's parse state. */\n get parseState(): number {\n marshalNode(this);\n return C._ts_node_parse_state_wasm(this.tree[0]);\n }\n\n /** Get the parse state after this node. */\n get nextParseState(): number {\n marshalNode(this);\n return C._ts_node_next_parse_state_wasm(this.tree[0]);\n }\n\n /** Check if this node is equal to another node. */\n equals(other: Node): boolean {\n return this.tree === other.tree && this.id === other.id;\n }\n\n /**\n * Get the node's child at the given index, where zero represents the first child.\n *\n * This method is fairly fast, but its cost is technically log(n), so if\n * you might be iterating over a long list of children, you should use\n * {@link Node#children} instead.\n */\n child(index: number): Node | null {\n marshalNode(this);\n C._ts_node_child_wasm(this.tree[0], index);\n return unmarshalNode(this.tree);\n }\n\n /**\n * Get this node's *named* child at the given index.\n *\n * See also {@link Node#isNamed}.\n * This method is fairly fast, but its cost is technically log(n), so if\n * you might be iterating over a long list of children, you should use\n * {@link Node#namedChildren} instead.\n */\n namedChild(index: number): Node | null {\n marshalNode(this);\n C._ts_node_named_child_wasm(this.tree[0], index);\n return unmarshalNode(this.tree);\n }\n\n /**\n * Get this node's child with the given numerical field id.\n *\n * See also {@link Node#childForFieldName}. You can\n * convert a field name to an id using {@link Language#fieldIdForName}.\n */\n childForFieldId(fieldId: number): Node | null {\n marshalNode(this);\n C._ts_node_child_by_field_id_wasm(this.tree[0], fieldId);\n return unmarshalNode(this.tree);\n }\n\n /**\n * Get the first child with the given field name.\n *\n * If multiple children may have the same field name, access them using\n * {@link Node#childrenForFieldName}.\n */\n childForFieldName(fieldName: string): Node | null {\n const fieldId = this.tree.language.fields.indexOf(fieldName);\n if (fieldId !== -1) return this.childForFieldId(fieldId);\n return null;\n }\n\n /** Get the field name of this node's child at the given index. */\n fieldNameForChild(index: number): string | null {\n marshalNode(this);\n const address = C._ts_node_field_name_for_child_wasm(this.tree[0], index);\n if (!address) return null;\n return C.AsciiToString(address);\n }\n\n /** Get the field name of this node's named child at the given index. */\n fieldNameForNamedChild(index: number): string | null {\n marshalNode(this);\n const address = C._ts_node_field_name_for_named_child_wasm(this.tree[0], index);\n if (!address) return null;\n return C.AsciiToString(address);\n }\n /**\n * Get an array of this node's children with a given field name.\n *\n * See also {@link Node#children}.\n */\n childrenForFieldName(fieldName: string): (Node | null)[] {\n const fieldId = this.tree.language.fields.indexOf(fieldName);\n if (fieldId !== -1 && fieldId !== 0) return this.childrenForFieldId(fieldId);\n return [];\n }\n\n /**\n * Get an array of this node's children with a given field id.\n *\n * See also {@link Node#childrenForFieldName}.\n */\n childrenForFieldId(fieldId: number): (Node | null)[] {\n marshalNode(this);\n C._ts_node_children_by_field_id_wasm(this.tree[0], fieldId);\n const count = C.getValue(TRANSFER_BUFFER, 'i32');\n const buffer = C.getValue(TRANSFER_BUFFER + SIZE_OF_INT, 'i32');\n const result = new Array<Node | null>(count);\n\n if (count > 0) {\n let address = buffer;\n for (let i = 0; i < count; i++) {\n result[i] = unmarshalNode(this.tree, address);\n address += SIZE_OF_NODE;\n }\n C._free(buffer);\n }\n return result;\n }\n\n /** Get the node's first child that contains or starts after the given byte offset. */\n firstChildForIndex(index: number): Node | null {\n marshalNode(this);\n const address = TRANSFER_BUFFER + SIZE_OF_NODE;\n C.setValue(address, index, 'i32');\n C._ts_node_first_child_for_byte_wasm(this.tree[0]);\n return unmarshalNode(this.tree);\n }\n\n /** Get the node's first named child that contains or starts after the given byte offset. */\n firstNamedChildForIndex(index: number): Node | null {\n marshalNode(this);\n const address = TRANSFER_BUFFER + SIZE_OF_NODE;\n C.setValue(address, index, 'i32');\n C._ts_node_first_named_child_for_byte_wasm(this.tree[0]);\n return unmarshalNode(this.tree);\n }\n\n /** Get this node's number of children. */\n get childCount(): number {\n marshalNode(this);\n return C._ts_node_child_count_wasm(this.tree[0]);\n }\n\n\n /**\n * Get this node's number of *named* children.\n *\n * See also {@link Node#isNamed}.\n */\n get namedChildCount(): number {\n marshalNode(this);\n return C._ts_node_named_child_count_wasm(this.tree[0]);\n }\n\n /** Get this node's first child. */\n get firstChild(): Node | null {\n return this.child(0);\n }\n\n /**\n * Get this node's first named child.\n *\n * See also {@link Node#isNamed}.\n */\n get firstNamedChild(): Node | null {\n return this.namedChild(0);\n }\n\n /** Get this node's last child. */\n get lastChild(): Node | null {\n return this.child(this.childCount - 1);\n }\n\n /**\n * Get this node's last named child.\n *\n * See also {@link Node#isNamed}.\n */\n get lastNamedChild(): Node | null {\n return this.namedChild(this.namedChildCount - 1);\n }\n\n /**\n * Iterate over this node's children.\n *\n * If you're walking the tree recursively, you may want to use the\n * {@link TreeCursor} APIs directly instead.\n */\n get children(): (Node | null)[] {\n if (!this._children) {\n marshalNode(this);\n C._ts_node_children_wasm(this.tree[0]);\n const count = C.getValue(TRANSFER_BUFFER, 'i32');\n const buffer = C.getValue(TRANSFER_BUFFER + SIZE_OF_INT, 'i32');\n this._children = new Array<Node>(count);\n if (count > 0) {\n let address = buffer;\n for (let i = 0; i < count; i++) {\n this._children[i] = unmarshalNode(this.tree, address);\n address += SIZE_OF_NODE;\n }\n C._free(buffer);\n }\n }\n return this._children;\n }\n\n /**\n * Iterate over this node's named children.\n *\n * See also {@link Node#children}.\n */\n get namedChildren(): (Node | null)[] {\n if (!this._namedChildren) {\n marshalNode(this);\n C._ts_node_named_children_wasm(this.tree[0]);\n const count = C.getValue(TRANSFER_BUFFER, 'i32');\n const buffer = C.getValue(TRANSFER_BUFFER + SIZE_OF_INT, 'i32');\n this._namedChildren = new Array<Node>(count);\n if (count > 0) {\n let address = buffer;\n for (let i = 0; i < count; i++) {\n this._namedChildren[i] = unmarshalNode(this.tree, address);\n address += SIZE_OF_NODE;\n }\n C._free(buffer);\n }\n }\n return this._namedChildren;\n }\n\n /**\n * Get the descendants of this node that are the given type, or in the given types array.\n *\n * The types array should contain node type strings, which can be retrieved from {@link Language#types}.\n *\n * Additionally, a `startPosition` and `endPosition` can be passed in to restrict the search to a byte range.\n */\n descendantsOfType(\n types: string | string[],\n startPosition: Point = ZERO_POINT,\n endPosition: Point = ZERO_POINT\n ): (Node | null)[] {\n if (!Array.isArray(types)) types = [types];\n\n // Convert the type strings to numeric type symbols\n const symbols: number[] = [];\n const typesBySymbol = this.tree.language.types;\n for (const node_type of types) {\n if (node_type == \"ERROR\") {\n symbols.push(65535); // Internally, ts_builtin_sym_error is -1, which is UINT_16MAX\n }\n }\n for (let i = 0, n = typesBySymbol.length; i < n; i++) {\n if (types.includes(typesBySymbol[i])) {\n symbols.push(i);\n }\n }\n\n // Copy the array of symbols to the WASM heap\n const symbolsAddress = C._malloc(SIZE_OF_INT * symbols.length);\n for (let i = 0, n = symbols.length; i < n; i++) {\n C.setValue(symbolsAddress + i * SIZE_OF_INT, symbols[i], 'i32');\n }\n\n // Call the C API to compute the descendants\n marshalNode(this);\n C._ts_node_descendants_of_type_wasm(\n this.tree[0],\n symbolsAddress,\n symbols.length,\n startPosition.row,\n startPosition.column,\n endPosition.row,\n endPosition.column\n );\n\n // Instantiate the nodes based on the data returned\n const descendantCount = C.getValue(TRANSFER_BUFFER, 'i32');\n const descendantAddress = C.getValue(TRANSFER_BUFFER + SIZE_OF_INT, 'i32');\n const result = new Array<Node | null>(descendantCount);\n if (descendantCount > 0) {\n let address = descendantAddress;\n for (let i = 0; i < descendantCount; i++) {\n result[i] = unmarshalNode(this.tree, address);\n address += SIZE_OF_NODE;\n }\n }\n\n // Free the intermediate buffers\n C._free(descendantAddress);\n C._free(symbolsAddress);\n return result;\n }\n\n /** Get this node's next sibling. */\n get nextSibling(): Node | null {\n marshalNode(this);\n C._ts_node_next_sibling_wasm(this.tree[0]);\n return unmarshalNode(this.tree);\n }\n\n /** Get this node's previous sibling. */\n get previousSibling(): Node | null {\n marshalNode(this);\n C._ts_node_prev_sibling_wasm(this.tree[0]);\n return unmarshalNode(this.tree);\n }\n\n /**\n * Get this node's next *named* sibling.\n *\n * See also {@link Node#isNamed}.\n */\n get nextNamedSibling(): Node | null {\n marshalNode(this);\n C._ts_node_next_named_sibling_wasm(this.tree[0]);\n return unmarshalNode(this.tree);\n }\n\n /**\n * Get this node's previous *named* sibling.\n *\n * See also {@link Node#isNamed}.\n */\n get previousNamedSibling(): Node | null {\n marshalNode(this);\n C._ts_node_prev_named_sibling_wasm(this.tree[0]);\n return unmarshalNode(this.tree);\n }\n\n /** Get the node's number of descendants, including one for the node itself. */\n get descendantCount(): number {\n marshalNode(this);\n return C._ts_node_descendant_count_wasm(this.tree[0]);\n }\n\n /**\n * Get this node's immediate parent.\n * Prefer {@link Node#childWithDescendant} for iterating over this node's ancestors.\n */\n get parent(): Node | null {\n marshalNode(this);\n C._ts_node_parent_wasm(this.tree[0]);\n return unmarshalNode(this.tree);\n }\n\n /**\n * Get the node that contains `descendant`.\n *\n * Note that this can return `descendant` itself.\n */\n childWithDescendant(descendant: Node): Node | null {\n marshalNode(this);\n marshalNode(descendant, 1);\n C._ts_node_child_with_descendant_wasm(this.tree[0]);\n return unmarshalNode(this.tree);\n }\n\n /** Get the smallest node within this node that spans the given byte range. */\n descendantForIndex(start: number, end: number = start): Node | null {\n if (typeof start !== 'number' || typeof end !== 'number') {\n throw new Error('Arguments must be numbers');\n }\n\n marshalNode(this);\n const address = TRANSFER_BUFFER + SIZE_OF_NODE;\n C.setValue(address, start, 'i32');\n C.setValue(address + SIZE_OF_INT, end, 'i32');\n C._ts_node_descendant_for_index_wasm(this.tree[0]);\n return unmarshalNode(this.tree);\n }\n\n /** Get the smallest named node within this node that spans the given byte range. */\n namedDescendantForIndex(start: number, end: number = start): Node | null {\n if (typeof start !== 'number' || typeof end !== 'number') {\n throw new Error('Arguments must be numbers');\n }\n\n marshalNode(this);\n const address = TRANSFER_BUFFER + SIZE_OF_NODE;\n C.setValue(address, start, 'i32');\n C.setValue(address + SIZE_OF_INT, end, 'i32');\n C._ts_node_named_descendant_for_index_wasm(this.tree[0]);\n return unmarshalNode(this.tree);\n }\n\n /** Get the smallest node within this node that spans the given point range. */\n descendantForPosition(start: Point, end: Point = start) {\n if (!isPoint(start) || !isPoint(end)) {\n throw new Error('Arguments must be {row, column} objects');\n }\n\n marshalNode(this);\n const address = TRANSFER_BUFFER + SIZE_OF_NODE;\n marshalPoint(address, start);\n marshalPoint(address + SIZE_OF_POINT, end);\n C._ts_node_descendant_for_position_wasm(this.tree[0]);\n return unmarshalNode(this.tree);\n }\n\n /** Get the smallest named node within this node that spans the given point range. */\n namedDescendantForPosition(start: Point, end: Point = start) {\n if (!isPoint(start) || !isPoint(end)) {\n throw new Error('Arguments must be {row, column} objects');\n }\n\n marshalNode(this);\n const address = TRANSFER_BUFFER + SIZE_OF_NODE;\n marshalPoint(address, start);\n marshalPoint(address + SIZE_OF_POINT, end);\n C._ts_node_named_descendant_for_position_wasm(this.tree[0]);\n return unmarshalNode(this.tree);\n }\n\n /**\n * Create a new {@link TreeCursor} starting from this node.\n *\n * Note that the given node is considered the root of the cursor,\n * and the cursor cannot walk outside this node.\n */\n walk(): TreeCursor {\n marshalNode(this);\n C._ts_tree_cursor_new_wasm(this.tree[0]);\n return new TreeCursor(INTERNAL, this.tree);\n }\n\n /**\n * Edit this node to keep it in-sync with source code that has been edited.\n *\n * This function is only rarely needed. When you edit a syntax tree with\n * the {@link Tree#edit} method, all of the nodes that you retrieve from\n * the tree afterward will already reflect the edit. You only need to\n * use {@link Node#edit} when you have a specific {@link Node} instance that\n * you want to keep and continue to use after an edit.\n */\n edit(edit: Edit) {\n if (this.startIndex >= edit.oldEndIndex) {\n this.startIndex = edit.newEndIndex + (this.startIndex - edit.oldEndIndex);\n let subbedPointRow;\n let subbedPointColumn;\n if (this.startPosition.row > edit.oldEndPosition.row) {\n subbedPointRow = this.startPosition.row - edit.oldEndPosition.row;\n subbedPointColumn = this.startPosition.column;\n } else {\n subbedPointRow = 0;\n subbedPointColumn = this.startPosition.column;\n if (this.startPosition.column >= edit.oldEndPosition.column) {\n subbedPointColumn =\n this.startPosition.column - edit.oldEndPosition.column;\n }\n }\n\n if (subbedPointRow > 0) {\n this.startPosition.row += subbedPointRow;\n this.startPosition.column = subbedPointColumn;\n } else {\n this.startPosition.column += subbedPointColumn;\n }\n } else if (this.startIndex > edit.startIndex) {\n this.startIndex = edit.newEndIndex;\n this.startPosition.row = edit.newEndPosition.row;\n this.startPosition.column = edit.newEndPosition.column;\n }\n }\n\n /** Get the S-expression representation of this node. */\n toString(): string {\n marshalNode(this);\n const address = C._ts_node_to_string_wasm(this.tree[0]);\n const result = C.AsciiToString(address);\n C._free(address);\n return result;\n }\n}\n", "import { Edit, INTERNAL, Point, Range, SIZE_OF_INT, SIZE_OF_NODE, SIZE_OF_POINT, C } from \"./constants\";\nimport { Node } from \"./node\";\nimport { Tree } from \"./tree\";\n// eslint-disable-next-line @typescript-eslint/no-unused-vars\nimport { Query, QueryCapture, type QueryMatch } from \"./query\";\nimport { TreeCursor } from \"./tree_cursor\";\nimport { TRANSFER_BUFFER } from \"./parser\";\nimport { LanguageMetadata } from \"./language\";\n\n/**\n * @internal\n *\n * Unmarshals a {@link QueryMatch} to the transfer buffer.\n */\nexport function unmarshalCaptures(\n query: Query,\n tree: Tree,\n address: number,\n patternIndex: number,\n result: QueryCapture[]\n) {\n for (let i = 0, n = result.length; i < n; i++) {\n const captureIndex = C.getValue(address, 'i32');\n address += SIZE_OF_INT;\n const node = unmarshalNode(tree, address)!;\n address += SIZE_OF_NODE;\n result[i] = {patternIndex, name: query.captureNames[captureIndex], node};\n }\n return address;\n}\n\n/**\n * @internal\n *\n * Marshals a {@link Node} to the transfer buffer.\n */\nexport function marshalNode(node: Node, index = 0) {\n let address = TRANSFER_BUFFER + index * SIZE_OF_NODE;\n C.setValue(address, node.id, 'i32');\n address += SIZE_OF_INT;\n C.setValue(address, node.startIndex, 'i32');\n address += SIZE_OF_INT;\n C.setValue(address, node.startPosition.row, 'i32');\n address += SIZE_OF_INT;\n C.setValue(address, node.startPosition.column, 'i32');\n address += SIZE_OF_INT;\n C.setValue(address, node[0], 'i32');\n}\n\n/**\n * @internal\n *\n * Unmarshals a {@link Node} from the transfer buffer.\n */\nexport function unmarshalNode(tree: Tree, address = TRANSFER_BUFFER): Node | null {\n const id = C.getValue(address, 'i32');\n address += SIZE_OF_INT;\n if (id === 0) return null;\n\n const index = C.getValue(address, 'i32');\n address += SIZE_OF_INT;\n const row = C.getValue(address, 'i32');\n address += SIZE_OF_INT;\n const column = C.getValue(address, 'i32');\n address += SIZE_OF_INT;\n const other = C.getValue(address, 'i32');\n\n const result = new Node(INTERNAL, {\n id,\n tree,\n startIndex: index,\n startPosition: {row, column},\n other,\n });\n\n return result;\n}\n\n/**\n * @internal\n *\n * Marshals a {@link TreeCursor} to the transfer buffer.\n */\nexport function marshalTreeCursor(cursor: TreeCursor, address = TRANSFER_BUFFER) {\n C.setValue(address + 0 * SIZE_OF_INT, cursor[0], 'i32');\n C.setValue(address + 1 * SIZE_OF_INT, cursor[1], 'i32');\n C.setValue(address + 2 * SIZE_OF_INT, cursor[2], 'i32');\n C.setValue(address + 3 * SIZE_OF_INT, cursor[3], 'i32');\n}\n\n/**\n * @internal\n *\n * Unmarshals a {@link TreeCursor} from the transfer buffer.\n */\nexport function unmarshalTreeCursor(cursor: TreeCursor) {\n cursor[0] = C.getValue(TRANSFER_BUFFER + 0 * SIZE_OF_INT, 'i32');\n cursor[1] = C.getValue(TRANSFER_BUFFER + 1 * SIZE_OF_INT, 'i32');\n cursor[2] = C.getValue(TRANSFER_BUFFER + 2 * SIZE_OF_INT, 'i32');\n cursor[3] = C.getValue(TRANSFER_BUFFER + 3 * SIZE_OF_INT, 'i32');\n}\n\n/**\n * @internal\n *\n * Marshals a {@link Point} to the transfer buffer.\n */\nexport function marshalPoint(address: number, point: Point): void {\n C.setValue(address, point.row, 'i32');\n C.setValue(address + SIZE_OF_INT, point.column, 'i32');\n}\n\n/**\n * @internal\n *\n * Unmarshals a {@link Point} from the transfer buffer.\n */\nexport function unmarshalPoint(address: number): Point {\n const result = {\n row: C.getValue(address, 'i32') >>> 0,\n column: C.getValue(address + SIZE_OF_INT, 'i32') >>> 0,\n };\n return result;\n}\n\n/**\n * @internal\n *\n * Marshals a {@link Range} to the transfer buffer.\n */\nexport function marshalRange(address: number, range: Range): void {\n marshalPoint(address, range.startPosition); address += SIZE_OF_POINT;\n marshalPoint(address, range.endPosition); address += SIZE_OF_POINT;\n C.setValue(address, range.startIndex, 'i32'); address += SIZE_OF_INT;\n C.setValue(address, range.endIndex, 'i32'); address += SIZE_OF_INT;\n}\n\n/**\n * @internal\n *\n * Unmarshals a {@link Range} from the transfer buffer.\n */\nexport function unmarshalRange(address: number): Range {\n const result = {} as Range;\n result.startPosition = unmarshalPoint(address); address += SIZE_OF_POINT;\n result.endPosition = unmarshalPoint(address); address += SIZE_OF_POINT;\n result.startIndex = C.getValue(address, 'i32') >>> 0; address += SIZE_OF_INT;\n result.endIndex = C.getValue(address, 'i32') >>> 0;\n return result;\n}\n\n/**\n * @internal\n *\n * Marshals an {@link Edit} to the transfer buffer.\n */\nexport function marshalEdit(edit: Edit, address = TRANSFER_BUFFER) {\n marshalPoint(address, edit.startPosition); address += SIZE_OF_POINT;\n marshalPoint(address, edit.oldEndPosition); address += SIZE_OF_POINT;\n marshalPoint(address, edit.newEndPosition); address += SIZE_OF_POINT;\n C.setValue(address, edit.startIndex, 'i32'); address += SIZE_OF_INT;\n C.setValue(address, edit.oldEndIndex, 'i32'); address += SIZE_OF_INT;\n C.setValue(address, edit.newEndIndex, 'i32'); address += SIZE_OF_INT;\n}\n\n/**\n * @internal\n *\n * Unmarshals a {@link LanguageMetadata} from the transfer buffer.\n */\nexport function unmarshalLanguageMetadata(address: number): LanguageMetadata { \n const major_version = C.getValue(address, 'i32');\n const minor_version = C.getValue(address += SIZE_OF_INT, 'i32');\n const patch_version = C.getValue(address += SIZE_OF_INT, 'i32');\n return { major_version, minor_version, patch_version };\n}\n", "import { Point, ZERO_POINT, SIZE_OF_INT, C } from './constants';\nimport { Node } from './node';\nimport { marshalNode, unmarshalCaptures } from './marshal';\nimport { TRANSFER_BUFFER } from './parser';\nimport { Language } from './language';\n\nconst PREDICATE_STEP_TYPE_CAPTURE = 1;\n\nconst PREDICATE_STEP_TYPE_STRING = 2;\n\nconst QUERY_WORD_REGEX = /[\\w-]+/g;\n\n/**\n * Options for query execution\n */\nexport interface QueryOptions {\n /** The start position of the range to query */\n startPosition?: Point;\n\n /** The end position of the range to query */\n endPosition?: Point;\n\n /** The start index of the range to query */\n startIndex?: number;\n\n /** The end index of the range to query */\n endIndex?: number;\n\n /**\n * The maximum number of in-progress matches for this query.\n * The limit must be > 0 and <= 65536.\n */\n matchLimit?: number;\n\n /**\n * The maximum start depth for a query cursor.\n *\n * This prevents cursors from exploring children nodes at a certain depth.\n * Note if a pattern includes many children, then they will still be\n * checked.\n *\n * The zero max start depth value can be used as a special behavior and\n * it helps to destructure a subtree by staying on a node and using\n * captures for interested parts. Note that the zero max start depth\n * only limit a search depth for a pattern's root node but other nodes\n * that are parts of the pattern may be searched at any depth what\n * defined by the pattern structure.\n *\n * Set to `null` to remove the maximum start depth.\n */\n maxStartDepth?: number;\n\n /**\n * The maximum duration in microseconds that query execution should be allowed to\n * take before halting.\n *\n * If query execution takes longer than this, it will halt early, returning an empty array.\n */\n timeoutMicros?: number;\n\n /**\n * A function that will be called periodically during the execution of the query to check\n * if query execution should be cancelled. You can also use this to instrument query execution\n * and check where the query is at in the document. The progress callback takes a single argument,\n * which is a {@link QueryState} representing the current state of the query.\n */\n progressCallback?: (state: QueryState) => void;\n}\n\n/**\n * A stateful object that is passed into the progress callback {@link QueryOptions#progressCallback}\n * to provide the current state of the query.\n */\nexport interface QueryState {\n /** The byte offset in the document that the query is at. */\n currentOffset: number;\n}\n\n/** A record of key-value pairs associated with a particular pattern in a {@link Query}. */\nexport type QueryProperties = Record<string, string | null>;\n\n/**\n * A predicate that contains an operator and list of operands.\n */\nexport interface QueryPredicate {\n /** The operator of the predicate, like `match?`, `eq?`, `set!`, etc. */\n operator: string;\n\n /** The operands of the predicate, which are either captures or strings. */\n operands: PredicateStep[];\n}\n\n/**\n * A particular {@link Node} that has been captured with a particular name within a\n * {@link Query}.\n */\nexport interface QueryCapture {\n /** The index of the pattern that matched. */\n patternIndex: number;\n\n /** The name of the capture */\n name: string;\n\n /** The captured node */\n node: Node;\n\n /** The properties for predicates declared with the operator `set!`. */\n setProperties?: QueryProperties;\n\n /** The properties for predicates declared with the operator `is?`. */\n assertedProperties?: QueryProperties;\n\n /** The properties for predicates declared with the operator `is-not?`. */\n refutedProperties?: QueryProperties;\n}\n\n/** A match of a {@link Query} to a particular set of {@link Node}s. */\nexport interface QueryMatch {\n /** @deprecated since version 0.25.0, use `patternIndex` instead. */\n pattern: number;\n\n /** The index of the pattern that matched. */\n patternIndex: number;\n\n /** The captures associated with the match. */\n captures: QueryCapture[];\n\n /** The properties for predicates declared with the operator `set!`. */\n setProperties?: QueryProperties;\n\n /** The properties for predicates declared with the operator `is?`. */\n assertedProperties?: QueryProperties;\n\n /** The properties for predicates declared with the operator `is-not?`. */\n refutedProperties?: QueryProperties;\n}\n\n/** A quantifier for captures */\nexport const CaptureQuantifier = {\n Zero: 0,\n ZeroOrOne: 1,\n ZeroOrMore: 2,\n One: 3,\n OneOrMore: 4\n} as const;\n\n/** A quantifier for captures */\nexport type CaptureQuantifier = typeof CaptureQuantifier[keyof typeof CaptureQuantifier];\n\n/**\n * Predicates are represented as a single array of steps. There are two\n * types of steps, which correspond to the two legal values for\n * the `type` field:\n *\n * - `CapturePredicateStep` - Steps with this type represent names\n * of captures.\n *\n * - `StringPredicateStep` - Steps with this type represent literal\n * strings.\n */\nexport type PredicateStep = CapturePredicateStep | StringPredicateStep;\n\n/**\n * A step in a predicate that refers to a capture.\n *\n * The `name` field is the name of the capture.\n */\nexport interface CapturePredicateStep { type: 'capture', name: string }\n\n/**\n * A step in a predicate that refers to a string.\n *\n * The `value` field is the string value.\n */\nexport interface StringPredicateStep { type: 'string', value: string }\n\nconst isCaptureStep = (step: PredicateStep): step is Extract<PredicateStep, { type: 'capture' }> =>\n step.type === 'capture';\n\nconst isStringStep = (step: PredicateStep): step is Extract<PredicateStep, { type: 'string' }> =>\n step.type === 'string';\n\n/**\n * @internal\n *\n * A function that checks if a given set of captures matches a particular\n * condition. This is used in the built-in `eq?`, `match?`, and `any-of?`\n * predicates.\n */\nexport type TextPredicate = (captures: QueryCapture[]) => boolean;\n\n/** Error codes returned from tree-sitter query parsing */\nexport const QueryErrorKind = {\n Syntax: 1,\n NodeName: 2,\n FieldName: 3,\n CaptureName: 4,\n PatternStructure: 5,\n} as const;\n\n/** An error that occurred while parsing a query string. */\nexport type QueryErrorKind = typeof QueryErrorKind[keyof typeof QueryErrorKind];\n\n/** Information about a {@link QueryError}. */\nexport interface QueryErrorInfo {\n [QueryErrorKind.NodeName]: { word: string };\n [QueryErrorKind.FieldName]: { word: string };\n [QueryErrorKind.CaptureName]: { word: string };\n [QueryErrorKind.PatternStructure]: { suffix: string };\n [QueryErrorKind.Syntax]: { suffix: string };\n}\n\n/** Error thrown when parsing a tree-sitter query fails */\nexport class QueryError extends Error {\n constructor(\n public kind: QueryErrorKind,\n public info: QueryErrorInfo[typeof kind],\n public index: number,\n public length: number\n ) {\n super(QueryError.formatMessage(kind, info));\n this.name = 'QueryError';\n }\n\n /** Formats an error message based on the error kind and info */\n private static formatMessage(kind: QueryErrorKind, info: QueryErrorInfo[QueryErrorKind]): string {\n switch (kind) {\n case QueryErrorKind.NodeName:\n return `Bad node name '${(info as QueryErrorInfo[2]).word}'`;\n case QueryErrorKind.FieldName:\n return `Bad field name '${(info as QueryErrorInfo[3]).word}'`;\n case QueryErrorKind.CaptureName:\n return `Bad capture name @${(info as QueryErrorInfo[4]).word}`;\n case QueryErrorKind.PatternStructure:\n return `Bad pattern structure at offset ${(info as QueryErrorInfo[5]).suffix}`;\n case QueryErrorKind.Syntax:\n return `Bad syntax at offset ${(info as QueryErrorInfo[1]).suffix}`;\n }\n }\n}\n\n/**\n * Parses the `eq?` and `not-eq?` predicates in a query, and updates the text predicates.\n */\nfunction parseAnyPredicate(\n steps: PredicateStep[],\n index: number,\n operator: string,\n textPredicates: TextPredicate[][],\n) {\n if (steps.length !== 3) {\n throw new Error(\n `Wrong number of arguments to \\`#${operator}\\` predicate. Expected 2, got ${steps.length - 1}`\n );\n }\n\n if (!isCaptureStep(steps[1])) {\n throw new Error(\n `First argument of \\`#${operator}\\` predicate must be a capture. Got \"${steps[1].value}\"`\n );\n }\n\n const isPositive = operator === 'eq?' || operator === 'any-eq?';\n const matchAll = !operator.startsWith('any-');\n\n if (isCaptureStep(steps[2])) {\n const captureName1 = steps[1].name;\n const captureName2 = steps[2].name;\n textPredicates[index].push((captures) => {\n const nodes1: Node[] = [];\n const nodes2: Node[] = [];\n for (const c of captures) {\n if (c.name === captureName1) nodes1.push(c.node);\n if (c.name === captureName2) nodes2.push(c.node);\n }\n const compare = (n1: { text: string }, n2: { text: string }, positive: boolean) => {\n return positive ? n1.text === n2.text : n1.text !== n2.text;\n };\n return matchAll\n ? nodes1.every((n1) => nodes2.some((n2) => compare(n1, n2, isPositive)))\n : nodes1.some((n1) => nodes2.some((n2) => compare(n1, n2, isPositive)));\n });\n } else {\n const captureName = steps[1].name;\n const stringValue = steps[2].value;\n const matches = (n: Node) => n.text === stringValue;\n const doesNotMatch = (n: Node) => n.text !== stringValue;\n textPredicates[index].push((captures) => {\n const nodes = [];\n for (const c of captures) {\n if (c.name === captureName) nodes.push(c.node);\n }\n const test = isPositive ? matches : doesNotMatch;\n return matchAll ? nodes.every(test) : nodes.some(test);\n });\n }\n}\n\n/**\n * Parses the `match?` and `not-match?` predicates in a query, and updates the text predicates.\n */\nfunction parseMatchPredicate(\n steps: PredicateStep[],\n index: number,\n operator: string,\n textPredicates: TextPredicate[][],\n) {\n if (steps.length !== 3) {\n throw new Error(\n `Wrong number of arguments to \\`#${operator}\\` predicate. Expected 2, got ${steps.length - 1}.`,\n );\n }\n\n if (steps[1].type !== 'capture') {\n throw new Error(\n `First argument of \\`#${operator}\\` predicate must be a capture. Got \"${steps[1].value}\".`,\n );\n }\n\n if (steps[2].type !== 'string') {\n throw new Error(\n `Second argument of \\`#${operator}\\` predicate must be a string. Got @${steps[2].name}.`,\n );\n }\n\n const isPositive = operator === 'match?' || operator === 'any-match?';\n const matchAll = !operator.startsWith('any-');\n const captureName = steps[1].name;\n const regex = new RegExp(steps[2].value);\n textPredicates[index].push((captures) => {\n const nodes = [];\n for (const c of captures) {\n if (c.name === captureName) nodes.push(c.node.text);\n }\n const test = (text: string, positive: boolean) => {\n return positive ?\n regex.test(text) :\n !regex.test(text);\n };\n if (nodes.length === 0) return !isPositive;\n return matchAll ?\n nodes.every((text) => test(text, isPositive)) :\n nodes.some((text) => test(text, isPositive));\n });\n}\n\n/**\n * Parses the `any-of?` and `not-any-of?` predicates in a query, and updates the text predicates.\n */\nfunction parseAnyOfPredicate(\n steps: PredicateStep[],\n index: number,\n operator: string,\n textPredicates: TextPredicate[][],\n) {\n if (steps.length < 2) {\n throw new Error(\n `Wrong number of arguments to \\`#${operator}\\` predicate. Expected at least 1. Got ${steps.length - 1}.`,\n );\n }\n\n if (steps[1].type !== 'capture') {\n throw new Error(\n `First argument of \\`#${operator}\\` predicate must be a capture. Got \"${steps[1].value}\".`,\n );\n }\n\n const isPositive = operator === 'any-of?';\n const captureName = steps[1].name;\n\n const stringSteps = steps.slice(2);\n if (!stringSteps.every(isStringStep)) {\n throw new Error(\n `Arguments to \\`#${operator}\\` predicate must be strings.\".`,\n );\n }\n const values = stringSteps.map((s) => s.value);\n\n textPredicates[index].push((captures) => {\n const nodes = [];\n for (const c of captures) {\n if (c.name === captureName) nodes.push(c.node.text);\n }\n if (nodes.length === 0) return !isPositive;\n return nodes.every((text) => values.includes(text)) === isPositive;\n });\n}\n\n/**\n * Parses the `is?` and `is-not?` predicates in a query, and updates the asserted or refuted properties,\n * depending on if the operator is positive or negative.\n */\nfunction parseIsPredicate(\n steps: PredicateStep[],\n index: number,\n operator: string,\n assertedProperties: QueryProperties[],\n refutedProperties: QueryProperties[],\n) {\n if (steps.length < 2 || steps.length > 3) {\n throw new Error(\n `Wrong number of arguments to \\`#${operator}\\` predicate. Expected 1 or 2. Got ${steps.length - 1}.`,\n );\n }\n\n if (!steps.every(isStringStep)) {\n throw new Error(\n `Arguments to \\`#${operator}\\` predicate must be strings.\".`,\n );\n }\n\n const properties = operator === 'is?' ? assertedProperties : refutedProperties;\n if (!properties[index]) properties[index] = {};\n properties[index][steps[1].value] = steps[2]?.value ?? null;\n}\n\n/**\n * Parses the `set!` directive in a query, and updates the set properties.\n */\nfunction parseSetDirective(\n steps: PredicateStep[],\n index: number,\n setProperties: QueryProperties[],\n) {\n if (steps.length < 2 || steps.length > 3) {\n throw new Error(`Wrong number of arguments to \\`#set!\\` predicate. Expected 1 or 2. Got ${steps.length - 1}.`);\n }\n if (!steps.every(isStringStep)) {\n throw new Error(`Arguments to \\`#set!\\` predicate must be strings.\".`);\n }\n if (!setProperties[index]) setProperties[index] = {};\n setProperties[index][steps[1].value] = steps[2]?.value ?? null;\n}\n\n/**\n * Parses the predicate at a given step in a pattern, and updates the appropriate\n * predicates or properties.\n */\nfunction parsePattern(\n index: number,\n stepType: number,\n stepValueId: number,\n captureNames: string[],\n stringValues: string[],\n steps: PredicateStep[],\n textPredicates: TextPredicate[][],\n predicates: QueryPredicate[][],\n setProperties: QueryProperties[],\n assertedProperties: QueryProperties[],\n refutedProperties: QueryProperties[],\n) {\n if (stepType === PREDICATE_STEP_TYPE_CAPTURE) {\n const name = captureNames[stepValueId];\n steps.push({ type: 'capture', name });\n } else if (stepType === PREDICATE_STEP_TYPE_STRING) {\n steps.push({ type: 'string', value: stringValues[stepValueId] });\n } else if (steps.length > 0) {\n if (steps[0].type !== 'string') {\n throw new Error('Predicates must begin with a literal value');\n }\n\n const operator = steps[0].value;\n switch (operator) {\n case 'any-not-eq?':\n case 'not-eq?':\n case 'any-eq?':\n case 'eq?':\n parseAnyPredicate(steps, index, operator, textPredicates);\n break;\n\n case 'any-not-match?':\n case 'not-match?':\n case 'any-match?':\n case 'match?':\n parseMatchPredicate(steps, index, operator, textPredicates);\n break;\n\n case 'not-any-of?':\n case 'any-of?':\n parseAnyOfPredicate(steps, index, operator, textPredicates);\n break;\n\n case 'is?':\n case 'is-not?':\n parseIsPredicate(steps, index, operator, assertedProperties, refutedProperties);\n break;\n\n case 'set!':\n parseSetDirective(steps, index, setProperties);\n break;\n\n default:\n predicates[index].push({ operator, operands: steps.slice(1) });\n }\n\n steps.length = 0;\n }\n}\n\nexport class Query {\n /** @internal */\n private [0] = 0; // Internal handle for WASM\n\n /** @internal */\n private exceededMatchLimit: boolean;\n\n /** @internal */\n private textPredicates: TextPredicate[][];\n\n /** The names of the captures used in the query. */\n readonly captureNames: string[];\n\n /** The quantifiers of the captures used in the query. */\n readonly captureQuantifiers: CaptureQuantifier[][];\n\n /**\n * The other user-defined predicates associated with the given index.\n *\n * This includes predicates with operators other than:\n * - `match?`\n * - `eq?` and `not-eq?`\n * - `any-of?` and `not-any-of?`\n * - `is?` and `is-not?`\n * - `set!`\n */\n readonly predicates: QueryPredicate[][];\n\n /** The properties for predicates with the operator `set!`. */\n readonly setProperties: QueryProperties[];\n\n /** The properties for predicates with the operator `is?`. */\n readonly assertedProperties: QueryProperties[];\n\n /** The properties for predicates with the operator `is-not?`. */\n readonly refutedProperties: QueryProperties[];\n\n /** The maximum number of in-progress matches for this cursor. */\n matchLimit?: number;\n\n /**\n * Create a new query from a string containing one or more S-expression\n * patterns.\n *\n * The query is associated with a particular language, and can only be run\n * on syntax nodes parsed with that language. References to Queries can be\n * shared between multiple threads.\n *\n * @link {@see https://tree-sitter.github.io/tree-sitter/using-parsers/queries}\n */\n constructor(language: Language, source: string) {\n const sourceLength = C.lengthBytesUTF8(source);\n const sourceAddress = C._malloc(sourceLength + 1);\n C.stringToUTF8(source, sourceAddress, sourceLength + 1);\n const address = C._ts_query_new(\n language[0],\n sourceAddress,\n sourceLength,\n TRANSFER_BUFFER,\n TRANSFER_BUFFER + SIZE_OF_INT\n );\n\n if (!address) {\n const errorId = C.getValue(TRANSFER_BUFFER + SIZE_OF_INT, 'i32') as QueryErrorKind;\n const errorByte = C.getValue(TRANSFER_BUFFER, 'i32');\n const errorIndex = C.UTF8ToString(sourceAddress, errorByte).length;\n const suffix = source.slice(errorIndex, errorIndex + 100).split('\\n')[0];\n const word = suffix.match(QUERY_WORD_REGEX)?.[0] ?? '';\n C._free(sourceAddress);\n\n switch (errorId) {\n case QueryErrorKind.Syntax:\n throw new QueryError(QueryErrorKind.Syntax, { suffix: `${errorIndex}: '${suffix}'...` }, errorIndex, 0);\n case QueryErrorKind.NodeName:\n throw new QueryError(errorId, { word }, errorIndex, word.length);\n case QueryErrorKind.FieldName:\n throw new QueryError(errorId, { word }, errorIndex, word.length);\n case QueryErrorKind.CaptureName:\n throw new QueryError(errorId, { word }, errorIndex, word.length);\n case QueryErrorKind.PatternStructure:\n throw new QueryError(errorId, { suffix: `${errorIndex}: '${suffix}'...` }, errorIndex, 0);\n }\n }\n\n const stringCount = C._ts_query_string_count(address);\n const captureCount = C._ts_query_capture_count(address);\n const patternCount = C._ts_query_pattern_count(address);\n const captureNames = new Array<string>(captureCount);\n const captureQuantifiers = new Array<CaptureQuantifier[]>(patternCount);\n const stringValues = new Array<string>(stringCount);\n\n // Fill in the capture names\n for (let i = 0; i < captureCount; i++) {\n const nameAddress = C._ts_query_capture_name_for_id(\n address,\n i,\n TRANSFER_BUFFER\n );\n const nameLength = C.getValue(TRANSFER_BUFFER, 'i32');\n captureNames[i] = C.UTF8ToString(nameAddress, nameLength);\n }\n\n // Fill in the capture quantifiers\n for (let i = 0; i < patternCount; i++) {\n const captureQuantifiersArray = new Array<CaptureQuantifier>(captureCount);\n for (let j = 0; j < captureCount; j++) {\n const quantifier = C._ts_query_capture_quantifier_for_id(address, i, j);\n captureQuantifiersArray[j] = quantifier as CaptureQuantifier;\n }\n captureQuantifiers[i] = captureQuantifiersArray;\n }\n\n // Fill in the string values\n for (let i = 0; i < stringCount; i++) {\n const valueAddress = C._ts_query_string_value_for_id(\n address,\n i,\n TRANSFER_BUFFER\n );\n const nameLength = C.getValue(TRANSFER_BUFFER, 'i32');\n stringValues[i] = C.UTF8ToString(valueAddress, nameLength);\n }\n\n const setProperties = new Array<QueryProperties>(patternCount);\n const assertedProperties = new Array<QueryProperties>(patternCount);\n const refutedProperties = new Array<QueryProperties>(patternCount);\n const predicates = new Array<QueryPredicate[]>(patternCount);\n const textPredicates = new Array<TextPredicate[]>(patternCount);\n\n // Parse the predicates, and add the appropriate predicates or properties\n for (let i = 0; i < patternCount; i++) {\n const predicatesAddress = C._ts_query_predicates_for_pattern(address, i, TRANSFER_BUFFER);\n const stepCount = C.getValue(TRANSFER_BUFFER, 'i32');\n\n predicates[i] = [];\n textPredicates[i] = [];\n\n const steps = new Array<PredicateStep>();\n\n let stepAddress = predicatesAddress;\n for (let j = 0; j < stepCount; j++) {\n const stepType = C.getValue(stepAddress, 'i32');\n stepAddress += SIZE_OF_INT;\n\n const stepValueId = C.getValue(stepAddress, 'i32');\n stepAddress += SIZE_OF_INT;\n\n parsePattern(\n i,\n stepType,\n stepValueId,\n captureNames,\n stringValues,\n steps,\n textPredicates,\n predicates,\n setProperties,\n assertedProperties,\n refutedProperties,\n );\n }\n\n Object.freeze(textPredicates[i]);\n Object.freeze(predicates[i]);\n Object.freeze(setProperties[i]);\n Object.freeze(assertedProperties[i]);\n Object.freeze(refutedProperties[i]);\n }\n\n C._free(sourceAddress);\n\n\n this[0] = address;\n this.captureNames = captureNames;\n this.captureQuantifiers = captureQuantifiers;\n this.textPredicates = textPredicates;\n this.predicates = predicates;\n this.setProperties = setProperties;\n this.assertedProperties = assertedProperties;\n this.refutedProperties = refutedProperties;\n this.exceededMatchLimit = false;\n }\n\n /** Delete the query, freeing its resources. */\n delete(): void {\n C._ts_query_delete(this[0]);\n this[0] = 0;\n }\n\n /**\n * Iterate over all of the matches in the order that they were found.\n *\n * Each match contains the index of the pattern that matched, and a list of\n * captures. Because multiple patterns can match the same set of nodes,\n * one match may contain captures that appear *before* some of the\n * captures from a previous match.\n *\n * @param {Node} node - The node to execute the query on.\n *\n * @param {QueryOptions} options - Options for query execution.\n */\n matches(\n node: Node,\n options: QueryOptions = {}\n ): QueryMatch[] {\n const startPosition = options.startPosition ?? ZERO_POINT;\n const endPosition = options.endPosition ?? ZERO_POINT;\n const startIndex = options.startIndex ?? 0;\n const endIndex = options.endIndex ?? 0;\n const matchLimit = options.matchLimit ?? 0xFFFFFFFF;\n const maxStartDepth = options.maxStartDepth ?? 0xFFFFFFFF;\n const timeoutMicros = options.timeoutMicros ?? 0;\n const progressCallback = options.progressCallback;\n\n if (typeof matchLimit !== 'number') {\n throw new Error('Arguments must be numbers');\n }\n this.matchLimit = matchLimit;\n\n if (endIndex !== 0 && startIndex > endIndex) {\n throw new Error('`startIndex` cannot be greater than `endIndex`');\n }\n\n if (endPosition !== ZERO_POINT && (\n startPosition.row > endPosition.row ||\n (startPosition.row === endPosition.row && startPosition.column > endPosition.column)\n )) {\n throw new Error('`startPosition` cannot be greater than `endPosition`');\n }\n\n if (progressCallback) {\n C.currentQueryProgressCallback = progressCallback;\n }\n\n marshalNode(node);\n\n C._ts_query_matches_wasm(\n this[0],\n node.tree[0],\n startPosition.row,\n startPosition.column,\n endPosition.row,\n endPosition.column,\n startIndex,\n endIndex,\n matchLimit,\n maxStartDepth,\n timeoutMicros,\n );\n\n const rawCount = C.getValue(TRANSFER_BUFFER, 'i32');\n const startAddress = C.getValue(TRANSFER_BUFFER + SIZE_OF_INT, 'i32');\n const didExceedMatchLimit = C.getValue(TRANSFER_BUFFER + 2 * SIZE_OF_INT, 'i32');\n const result = new Array<QueryMatch>(rawCount);\n this.exceededMatchLimit = Boolean(didExceedMatchLimit);\n\n let filteredCount = 0;\n let address = startAddress;\n for (let i = 0; i < rawCount; i++) {\n const patternIndex = C.getValue(address, 'i32');\n address += SIZE_OF_INT;\n const captureCount = C.getValue(address, 'i32');\n address += SIZE_OF_INT;\n\n const captures = new Array<QueryCapture>(captureCount);\n address = unmarshalCaptures(this, node.tree, address, patternIndex, captures);\n\n if (this.textPredicates[patternIndex].every((p) => p(captures))) {\n result[filteredCount] = { pattern: patternIndex, patternIndex, captures };\n const setProperties = this.setProperties[patternIndex];\n result[filteredCount].setProperties = setProperties;\n const assertedProperties = this.assertedProperties[patternIndex];\n result[filteredCount].assertedProperties = assertedProperties;\n const refutedProperties = this.refutedProperties[patternIndex];\n result[filteredCount].refutedProperties = refutedProperties;\n filteredCount++;\n }\n }\n result.length = filteredCount;\n\n C._free(startAddress);\n C.currentQueryProgressCallback = null;\n return result;\n }\n\n /**\n * Iterate over all of the individual captures in the order that they\n * appear.\n *\n * This is useful if you don't care about which pattern matched, and just\n * want a single, ordered sequence of captures.\n *\n * @param {Node} node - The node to execute the query on.\n *\n * @param {QueryOptions} options - Options for query execution.\n */\n captures(\n node: Node,\n options: QueryOptions = {}\n ): QueryCapture[] {\n const startPosition = options.startPosition ?? ZERO_POINT;\n const endPosition = options.endPosition ?? ZERO_POINT;\n const startIndex = options.startIndex ?? 0;\n const endIndex = options.endIndex ?? 0;\n const matchLimit = options.matchLimit ?? 0xFFFFFFFF;\n const maxStartDepth = options.maxStartDepth ?? 0xFFFFFFFF;\n const timeoutMicros = options.timeoutMicros ?? 0;\n const progressCallback = options.progressCallback;\n\n if (typeof matchLimit !== 'number') {\n throw new Error('Arguments must be numbers');\n }\n this.matchLimit = matchLimit;\n\n if (endIndex !== 0 && startIndex > endIndex) {\n throw new Error('`startIndex` cannot be greater than `endIndex`');\n }\n\n if (endPosition !== ZERO_POINT && (\n startPosition.row > endPosition.row ||\n (startPosition.row === endPosition.row && startPosition.column > endPosition.column)\n )) {\n throw new Error('`startPosition` cannot be greater than `endPosition`');\n }\n\n if (progressCallback) {\n C.currentQueryProgressCallback = progressCallback;\n }\n\n marshalNode(node);\n\n C._ts_query_captures_wasm(\n this[0],\n node.tree[0],\n startPosition.row,\n startPosition.column,\n endPosition.row,\n endPosition.column,\n startIndex,\n endIndex,\n matchLimit,\n maxStartDepth,\n timeoutMicros,\n );\n\n const count = C.getValue(TRANSFER_BUFFER, 'i32');\n const startAddress = C.getValue(TRANSFER_BUFFER + SIZE_OF_INT, 'i32');\n const didExceedMatchLimit = C.getValue(TRANSFER_BUFFER + 2 * SIZE_OF_INT, 'i32');\n const result = new Array<QueryCapture>();\n this.exceededMatchLimit = Boolean(didExceedMatchLimit);\n\n const captures = new Array<QueryCapture>();\n let address = startAddress;\n for (let i = 0; i < count; i++) {\n const patternIndex = C.getValue(address, 'i32');\n address += SIZE_OF_INT;\n const captureCount = C.getValue(address, 'i32');\n address += SIZE_OF_INT;\n const captureIndex = C.getValue(address, 'i32');\n address += SIZE_OF_INT;\n\n captures.length = captureCount;\n address = unmarshalCaptures(this, node.tree, address, patternIndex, captures);\n\n if (this.textPredicates[patternIndex].every(p => p(captures))) {\n const capture = captures[captureIndex];\n const setProperties = this.setProperties[patternIndex];\n capture.setProperties = setProperties;\n const assertedProperties = this.assertedProperties[patternIndex];\n capture.assertedProperties = assertedProperties;\n const refutedProperties = this.refutedProperties[patternIndex];\n capture.refutedProperties = refutedProperties;\n result.push(capture);\n }\n }\n\n C._free(startAddress);\n C.currentQueryProgressCallback = null;\n return result;\n }\n\n /** Get the predicates for a given pattern. */\n predicatesForPattern(patternIndex: number): QueryPredicate[] {\n return this.predicates[patternIndex];\n }\n\n /**\n * Disable a certain capture within a query.\n *\n * This prevents the capture from being returned in matches, and also\n * avoids any resource usage associated with recording the capture.\n */\n disableCapture(captureName: string): void {\n const captureNameLength = C.lengthBytesUTF8(captureName);\n const captureNameAddress = C._malloc(captureNameLength + 1);\n C.stringToUTF8(captureName, captureNameAddress, captureNameLength + 1);\n C._ts_query_disable_capture(this[0], captureNameAddress, captureNameLength);\n C._free(captureNameAddress);\n }\n\n /**\n * Disable a certain pattern within a query.\n *\n * This prevents the pattern from matching, and also avoids any resource\n * usage associated with the pattern. This throws an error if the pattern\n * index is out of bounds.\n */\n disablePattern(patternIndex: number): void {\n if (patternIndex >= this.predicates.length) {\n throw new Error(\n `Pattern index is ${patternIndex} but the pattern count is ${this.predicates.length}`\n );\n }\n C._ts_query_disable_pattern(this[0], patternIndex);\n }\n\n /**\n * Check if, on its last execution, this cursor exceeded its maximum number\n * of in-progress matches.\n */\n didExceedMatchLimit(): boolean {\n return this.exceededMatchLimit;\n }\n\n /** Get the byte offset where the given pattern starts in the query's source. */\n startIndexForPattern(patternIndex: number): number {\n if (patternIndex >= this.predicates.length) {\n throw new Error(\n `Pattern index is ${patternIndex} but the pattern count is ${this.predicates.length}`\n );\n }\n return C._ts_query_start_byte_for_pattern(this[0], patternIndex);\n }\n\n /** Get the byte offset where the given pattern ends in the query's source. */\n endIndexForPattern(patternIndex: number): number {\n if (patternIndex >= this.predicates.length) {\n throw new Error(\n `Pattern index is ${patternIndex} but the pattern count is ${this.predicates.length}`\n );\n }\n return C._ts_query_end_byte_for_pattern(this[0], patternIndex);\n }\n\n /** Get the number of patterns in the query. */\n patternCount(): number {\n return C._ts_query_pattern_count(this[0]);\n }\n\n /** Get the index for a given capture name. */\n captureIndexForName(captureName: string): number {\n return this.captureNames.indexOf(captureName);\n }\n\n /** Check if a given pattern within a query has a single root node. */\n isPatternRooted(patternIndex: number): boolean {\n return C._ts_query_is_pattern_rooted(this[0], patternIndex) === 1;\n }\n\n /** Check if a given pattern within a query has a single root node. */\n isPatternNonLocal(patternIndex: number): boolean {\n return C._ts_query_is_pattern_non_local(this[0], patternIndex) === 1;\n }\n\n /**\n * Check if a given step in a query is 'definite'.\n *\n * A query step is 'definite' if its parent pattern will be guaranteed to\n * match successfully once it reaches the step.\n */\n isPatternGuaranteedAtStep(byteIndex: number): boolean {\n return C._ts_query_is_pattern_guaranteed_at_step(this[0], byteIndex) === 1;\n }\n}\n", "import { C, INTERNAL, Internal, assertInternal, SIZE_OF_INT, SIZE_OF_SHORT } from './constants';\nimport { LookaheadIterator } from './lookahead_iterator';\nimport { unmarshalLanguageMetadata } from './marshal';\nimport { TRANSFER_BUFFER } from './parser';\nimport { Query } from './query';\n\nconst LANGUAGE_FUNCTION_REGEX = /^tree_sitter_\\w+$/;\n\nexport interface LanguageMetadata {\n readonly major_version: number;\n readonly minor_version: number;\n readonly patch_version: number;\n}\n\n/**\n * An opaque object that defines how to parse a particular language.\n * The code for each `Language` is generated by the Tree-sitter CLI.\n */\nexport class Language {\n /** @internal */\n private [0] = 0; // Internal handle for WASM\n\n /**\n * A list of all node types in the language. The index of each type in this\n * array is its node type id.\n */\n types: string[];\n\n /**\n * A list of all field names in the language. The index of each field name in\n * this array is its field id.\n */\n fields: (string | null)[];\n\n /** @internal */\n constructor(internal: Internal, address: number) {\n assertInternal(internal);\n this[0] = address;\n this.types = new Array<string>(C._ts_language_symbol_count(this[0]));\n for (let i = 0, n = this.types.length; i < n; i++) {\n if (C._ts_language_symbol_type(this[0], i) < 2) {\n this.types[i] = C.UTF8ToString(C._ts_language_symbol_name(this[0], i));\n }\n }\n this.fields = new Array<string>(C._ts_language_field_count(this[0]) + 1);\n for (let i = 0, n = this.fields.length; i < n; i++) {\n const fieldName = C._ts_language_field_name_for_id(this[0], i);\n if (fieldName !== 0) {\n this.fields[i] = C.UTF8ToString(fieldName);\n } else {\n this.fields[i] = null;\n }\n }\n }\n\n\n /**\n * Gets the name of the language.\n */\n get name(): string | null {\n const ptr = C._ts_language_name(this[0]);\n if (ptr === 0) return null;\n return C.UTF8ToString(ptr);\n }\n\n /**\n * @deprecated since version 0.25.0, use {@link Language#abiVersion} instead\n * Gets the version of the language.\n */\n get version(): number {\n return C._ts_language_version(this[0]);\n }\n\n /**\n * Gets the ABI version of the language.\n */\n get abiVersion(): number {\n return C._ts_language_abi_version(this[0]);\n }\n\n /**\n * Get the metadata for this language. This information is generated by the\n * CLI, and relies on the language author providing the correct metadata in\n * the language's `tree-sitter.json` file.\n */\n get metadata(): LanguageMetadata | null {\n C._ts_language_metadata(this[0]);\n const length = C.getValue(TRANSFER_BUFFER, 'i32');\n const address = C.getValue(TRANSFER_BUFFER + SIZE_OF_INT, 'i32');\n if (length === 0) return null;\n return unmarshalLanguageMetadata(address);\n }\n\n /**\n * Gets the number of fields in the language.\n */\n get fieldCount(): number {\n return this.fields.length - 1;\n }\n\n /**\n * Gets the number of states in the language.\n */\n get stateCount(): number {\n return C._ts_language_state_count(this[0]);\n }\n\n /**\n * Get the field id for a field name.\n */\n fieldIdForName(fieldName: string): number | null {\n const result = this.fields.indexOf(fieldName);\n return result !== -1 ? result : null;\n }\n\n /**\n * Get the field name for a field id.\n */\n fieldNameForId(fieldId: number): string | null {\n return this.fields[fieldId] ?? null;\n }\n\n /**\n * Get the node type id for a node type name.\n */\n idForNodeType(type: string, named: boolean): number | null {\n const typeLength = C.lengthBytesUTF8(type);\n const typeAddress = C._malloc(typeLength + 1);\n C.stringToUTF8(type, typeAddress, typeLength + 1);\n const result = C._ts_language_symbol_for_name(this[0], typeAddress, typeLength, named ? 1 : 0);\n C._free(typeAddress);\n return result || null;\n }\n\n /**\n * Gets the number of node types in the language.\n */\n get nodeTypeCount(): number {\n return C._ts_language_symbol_count(this[0]);\n }\n\n /**\n * Get the node type name for a node type id.\n */\n nodeTypeForId(typeId: number): string | null {\n const name = C._ts_language_symbol_name(this[0], typeId);\n return name ? C.UTF8ToString(name) : null;\n }\n\n /**\n * Check if a node type is named.\n *\n * @see {@link https://tree-sitter.github.io/tree-sitter/using-parsers/2-basic-parsing.html#named-vs-anonymous-nodes}\n */\n nodeTypeIsNamed(typeId: number): boolean {\n return C._ts_language_type_is_named_wasm(this[0], typeId) ? true : false;\n }\n\n /**\n * Check if a node type is visible.\n */\n nodeTypeIsVisible(typeId: number): boolean {\n return C._ts_language_type_is_visible_wasm(this[0], typeId) ? true : false;\n }\n\n /**\n * Get the supertypes ids of this language.\n *\n * @see {@link https://tree-sitter.github.io/tree-sitter/using-parsers/6-static-node-types.html?highlight=supertype#supertype-nodes}\n */\n get supertypes(): number[] {\n C._ts_language_supertypes_wasm(this[0]);\n const count = C.getValue(TRANSFER_BUFFER, 'i32');\n const buffer = C.getValue(TRANSFER_BUFFER + SIZE_OF_INT, 'i32');\n const result = new Array<number>(count);\n\n if (count > 0) {\n let address = buffer;\n for (let i = 0; i < count; i++) {\n result[i] = C.getValue(address, 'i16');\n address += SIZE_OF_SHORT;\n }\n }\n\n return result;\n }\n\n /**\n * Get the subtype ids for a given supertype node id.\n */\n subtypes(supertype: number): number[] {\n C._ts_language_subtypes_wasm(this[0], supertype);\n const count = C.getValue(TRANSFER_BUFFER, 'i32');\n const buffer = C.getValue(TRANSFER_BUFFER + SIZE_OF_INT, 'i32');\n const result = new Array<number>(count);\n\n if (count > 0) {\n let address = buffer;\n for (let i = 0; i < count; i++) {\n result[i] = C.getValue(address, 'i16');\n address += SIZE_OF_SHORT;\n }\n }\n\n return result;\n }\n\n /**\n * Get the next state id for a given state id and node type id.\n */\n nextState(stateId: number, typeId: number): number {\n return C._ts_language_next_state(this[0], stateId, typeId);\n }\n\n /**\n * Create a new lookahead iterator for this language and parse state.\n *\n * This returns `null` if state is invalid for this language.\n *\n * Iterating {@link LookaheadIterator} will yield valid symbols in the given\n * parse state. Newly created lookahead iterators will return the `ERROR`\n * symbol from {@link LookaheadIterator#currentType}.\n *\n * Lookahead iterators can be useful for generating suggestions and improving\n * syntax error diagnostics. To get symbols valid in an `ERROR` node, use the\n * lookahead iterator on its first leaf node state. For `MISSING` nodes, a\n * lookahead iterator created on the previous non-extra leaf node may be\n * appropriate.\n */\n lookaheadIterator(stateId: number): LookaheadIterator | null {\n const address = C._ts_lookahead_iterator_new(this[0], stateId);\n if (address) return new LookaheadIterator(INTERNAL, address, this);\n return null;\n }\n\n /**\n * @deprecated since version 0.25.0, call `new` on a {@link Query} instead\n *\n * Create a new query from a string containing one or more S-expression\n * patterns.\n *\n * The query is associated with a particular language, and can only be run\n * on syntax nodes parsed with that language. References to Queries can be\n * shared between multiple threads.\n *\n * @link {@see https://tree-sitter.github.io/tree-sitter/using-parsers/queries}\n */\n query(source: string): Query {\n console.warn('Language.query is deprecated. Use new Query(language, source) instead.');\n return new Query(this, source);\n }\n\n /**\n * Load a language from a WebAssembly module.\n * The module can be provided as a path to a file or as a buffer.\n */\n static async load(input: string | Uint8Array): Promise<Language> {\n let bytes: Promise<Uint8Array>;\n if (input instanceof Uint8Array) {\n bytes = Promise.resolve(input);\n } else {\n // eslint-disable-next-line @typescript-eslint/no-unnecessary-condition\n if (globalThis.process?.versions.node) {\n const fs: typeof import('fs/promises') = await import('fs/promises');\n bytes = fs.readFile(input);\n } else {\n bytes = fetch(input)\n .then((response) => response.arrayBuffer()\n .then((buffer) => {\n if (response.ok) {\n return new Uint8Array(buffer);\n } else {\n const body = new TextDecoder('utf-8').decode(buffer);\n throw new Error(`Language.load failed with status ${response.status}.\\n\\n${body}`);\n }\n }));\n }\n }\n\n const mod = await C.loadWebAssemblyModule(await bytes, { loadAsync: true });\n const symbolNames = Object.keys(mod);\n const functionName = symbolNames.find((key) => LANGUAGE_FUNCTION_REGEX.test(key) &&\n !key.includes('external_scanner_'));\n if (!functionName) {\n console.log(`Couldn't find language function in WASM file. Symbols:\\n${JSON.stringify(symbolNames, null, 2)}`);\n throw new Error('Language.load failed: no language function found in WASM file');\n }\n const languageAddress = mod[functionName]();\n return new Language(INTERNAL, languageAddress);\n }\n}\n", "import createModule, { type MainModule } from '../lib/tree-sitter';\n// eslint-disable-next-line @typescript-eslint/no-unused-vars\nimport { type Parser } from './parser';\n\nexport let Module: MainModule | null = null;\n\n/**\n * @internal\n *\n * Initialize the Tree-sitter WASM module. This should only be called by the {@link Parser} class via {@link Parser.init}.\n */\nexport async function initializeBinding(moduleOptions?: EmscriptenModule): Promise<MainModule> {\n if (!Module) {\n Module = await createModule(moduleOptions);\n }\n return Module;\n}\n\n/**\n * @internal\n *\n * Checks if the Tree-sitter WASM module has been initialized.\n */\nexport function checkModule(): boolean {\n return !!Module;\n}\n", "import { C, INTERNAL, LogCallback, ParseCallback, Range, SIZE_OF_INT, SIZE_OF_RANGE, setModule } from './constants';\nimport { Language } from './language';\nimport { marshalRange, unmarshalRange } from './marshal';\nimport { checkModule, initializeBinding } from './bindings';\nimport { Tree } from './tree';\n\n/**\n * Options for parsing\n *\n * The `includedRanges` property is an array of {@link Range} objects that\n * represent the ranges of text that the parser should include when parsing.\n *\n * The `progressCallback` property is a function that is called periodically\n * during parsing to check whether parsing should be cancelled.\n *\n * See {@link Parser#parse} for more information.\n */\nexport interface ParseOptions {\n /**\n * An array of {@link Range} objects that\n * represent the ranges of text that the parser should include when parsing.\n *\n * This sets the ranges of text that the parser should include when parsing.\n * By default, the parser will always include entire documents. This\n * function allows you to parse only a *portion* of a document but\n * still return a syntax tree whose ranges match up with the document\n * as a whole. You can also pass multiple disjoint ranges.\n * If `ranges` is empty, then the entire document will be parsed.\n * Otherwise, the given ranges must be ordered from earliest to latest\n * in the document, and they must not overlap. That is, the following\n * must hold for all `i` < `length - 1`:\n * ```text\n * ranges[i].end_byte <= ranges[i + 1].start_byte\n * ```\n */\n includedRanges?: Range[];\n\n /**\n * A function that is called periodically during parsing to check\n * whether parsing should be cancelled. If the progress callback returns\n * `true`, then parsing will be cancelled. You can also use this to instrument\n * parsing and check where the parser is at in the document. The progress callback\n * takes a single argument, which is a {@link ParseState} representing the current\n * state of the parser.\n */\n progressCallback?: (state: ParseState) => void;\n}\n\n/**\n * A stateful object that is passed into the progress callback {@link ParseOptions#progressCallback}\n * to provide the current state of the parser.\n */\nexport interface ParseState {\n /** The byte offset in the document that the parser is at. */\n currentOffset: number;\n\n /** Indicates whether the parser has encountered an error during parsing. */\n hasError: boolean;\n}\n\n/**\n * @internal\n *\n * Global variable for transferring data across the FFI boundary\n */\nexport let TRANSFER_BUFFER: number;\n\n/**\n * The latest ABI version that is supported by the current version of the\n * library.\n *\n * When Languages are generated by the Tree-sitter CLI, they are\n * assigned an ABI version number that corresponds to the current CLI version.\n * The Tree-sitter library is generally backwards-compatible with languages\n * generated using older CLI versions, but is not forwards-compatible.\n */\nexport let LANGUAGE_VERSION: number;\n\n/**\n * The earliest ABI version that is supported by the current version of the\n * library.\n */\nexport let MIN_COMPATIBLE_VERSION: number;\n\n/**\n * A stateful object that is used to produce a {@link Tree} based on some\n * source code.\n */\nexport class Parser {\n /** @internal */\n private [0] = 0; // Internal handle for WASM\n\n /** @internal */\n private [1] = 0; // Internal handle for WASM\n\n /** @internal */\n private logCallback: LogCallback | null = null;\n\n /** The parser's current language. */\n language: Language | null = null;\n\n /**\n * This must always be called before creating a Parser.\n *\n * You can optionally pass in options to configure the WASM module, the most common\n * one being `locateFile` to help the module find the `.wasm` file.\n */\n static async init(moduleOptions?: EmscriptenModule) {\n setModule(await initializeBinding(moduleOptions));\n TRANSFER_BUFFER = C._ts_init();\n LANGUAGE_VERSION = C.getValue(TRANSFER_BUFFER, 'i32');\n MIN_COMPATIBLE_VERSION = C.getValue(TRANSFER_BUFFER + SIZE_OF_INT, 'i32');\n }\n\n /**\n * Create a new parser.\n */\n constructor() {\n this.initialize();\n }\n\n /** @internal */\n initialize() {\n if (!checkModule()) {\n throw new Error(\"cannot construct a Parser before calling `init()`\");\n }\n C._ts_parser_new_wasm();\n this[0] = C.getValue(TRANSFER_BUFFER, 'i32');\n this[1] = C.getValue(TRANSFER_BUFFER + SIZE_OF_INT, 'i32');\n }\n\n /** Delete the parser, freeing its resources. */\n delete() {\n C._ts_parser_delete(this[0]);\n C._free(this[1]);\n this[0] = 0;\n this[1] = 0;\n }\n\n /**\n * Set the language that the parser should use for parsing.\n *\n * If the language was not successfully assigned, an error will be thrown.\n * This happens if the language was generated with an incompatible\n * version of the Tree-sitter CLI. Check the language's version using\n * {@link Language#version} and compare it to this library's\n * {@link LANGUAGE_VERSION} and {@link MIN_COMPATIBLE_VERSION} constants.\n */\n setLanguage(language: Language | null): this {\n let address: number;\n if (!language) {\n address = 0;\n this.language = null;\n } else if (language.constructor === Language) {\n address = language[0];\n const version = C._ts_language_version(address);\n if (version < MIN_COMPATIBLE_VERSION || LANGUAGE_VERSION < version) {\n throw new Error(\n `Incompatible language version ${version}. ` +\n `Compatibility range ${MIN_COMPATIBLE_VERSION} through ${LANGUAGE_VERSION}.`\n );\n }\n this.language = language;\n } else {\n throw new Error('Argument must be a Language');\n }\n\n C._ts_parser_set_language(this[0], address);\n return this;\n }\n\n /**\n * Parse a slice of UTF8 text.\n *\n * @param {string | ParseCallback} callback - The UTF8-encoded text to parse or a callback function.\n *\n * @param {Tree | null} [oldTree] - A previous syntax tree parsed from the same document. If the text of the\n * document has changed since `oldTree` was created, then you must edit `oldTree` to match\n * the new text using {@link Tree#edit}.\n *\n * @param {ParseOptions} [options] - Options for parsing the text.\n * This can be used to set the included ranges, or a progress callback.\n *\n * @returns {Tree | null} A {@link Tree} if parsing succeeded, or `null` if:\n * - The parser has not yet had a language assigned with {@link Parser#setLanguage}.\n * - The progress callback returned true.\n */\n parse(\n callback: string | ParseCallback,\n oldTree?: Tree | null,\n options?: ParseOptions,\n ): Tree | null {\n if (typeof callback === 'string') {\n C.currentParseCallback = (index: number) => callback.slice(index);\n } else if (typeof callback === 'function') {\n C.currentParseCallback = callback;\n } else {\n throw new Error('Argument must be a string or a function');\n }\n\n if (options?.progressCallback) {\n C.currentProgressCallback = options.progressCallback;\n } else {\n C.currentProgressCallback = null;\n }\n\n if (this.logCallback) {\n C.currentLogCallback = this.logCallback;\n C._ts_parser_enable_logger_wasm(this[0], 1);\n } else {\n C.currentLogCallback = null;\n C._ts_parser_enable_logger_wasm(this[0], 0);\n }\n\n let rangeCount = 0;\n let rangeAddress = 0;\n if (options?.includedRanges) {\n rangeCount = options.includedRanges.length;\n rangeAddress = C._calloc(rangeCount, SIZE_OF_RANGE);\n let address = rangeAddress;\n for (let i = 0; i < rangeCount; i++) {\n marshalRange(address, options.includedRanges[i]);\n address += SIZE_OF_RANGE;\n }\n }\n\n const treeAddress = C._ts_parser_parse_wasm(\n this[0],\n this[1],\n oldTree ? oldTree[0] : 0,\n rangeAddress,\n rangeCount\n );\n\n if (!treeAddress) {\n C.currentParseCallback = null;\n C.currentLogCallback = null;\n C.currentProgressCallback = null;\n return null;\n }\n\n if (!this.language) {\n throw new Error('Parser must have a language to parse');\n }\n\n const result = new Tree(INTERNAL, treeAddress, this.language, C.currentParseCallback);\n C.currentParseCallback = null;\n C.currentLogCallback = null;\n C.currentProgressCallback = null;\n return result;\n }\n\n /**\n * Instruct the parser to start the next parse from the beginning.\n *\n * If the parser previously failed because of a timeout, cancellation,\n * or callback, then by default, it will resume where it left off on the\n * next call to {@link Parser#parse} or other parsing functions.\n * If you don't want to resume, and instead intend to use this parser to\n * parse some other document, you must call `reset` first.\n */\n reset(): void {\n C._ts_parser_reset(this[0]);\n }\n\n /** Get the ranges of text that the parser will include when parsing. */\n getIncludedRanges(): Range[] {\n C._ts_parser_included_ranges_wasm(this[0]);\n const count = C.getValue(TRANSFER_BUFFER, 'i32');\n const buffer = C.getValue(TRANSFER_BUFFER + SIZE_OF_INT, 'i32');\n const result = new Array<Range>(count);\n\n if (count > 0) {\n let address = buffer;\n for (let i = 0; i < count; i++) {\n result[i] = unmarshalRange(address);\n address += SIZE_OF_RANGE;\n }\n C._free(buffer);\n }\n\n return result;\n }\n\n /**\n * @deprecated since version 0.25.0, prefer passing a progress callback to {@link Parser#parse}\n *\n * Get the duration in microseconds that parsing is allowed to take.\n *\n * This is set via {@link Parser#setTimeoutMicros}.\n */\n getTimeoutMicros(): number {\n return C._ts_parser_timeout_micros(this[0]);\n }\n\n /**\n * @deprecated since version 0.25.0, prefer passing a progress callback to {@link Parser#parse}\n *\n * Set the maximum duration in microseconds that parsing should be allowed\n * to take before halting.\n *\n * If parsing takes longer than this, it will halt early, returning `null`.\n * See {@link Parser#parse} for more information.\n */\n setTimeoutMicros(timeout: number): void {\n C._ts_parser_set_timeout_micros(this[0], 0, timeout);\n }\n\n /** Set the logging callback that a parser should use during parsing. */\n setLogger(callback: LogCallback | boolean | null): this {\n if (!callback) {\n this.logCallback = null;\n } else if (typeof callback !== 'function') {\n throw new Error('Logger callback must be a function');\n } else {\n this.logCallback = callback;\n }\n return this;\n }\n\n /** Get the parser's current logger. */\n getLogger(): LogCallback | null {\n return this.logCallback;\n }\n}\n"],
5
+ "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA,QAAI,UAAU,MAAM;AAClB,UAAI,cAAc,OAAO,YAAY,cAAc,SAAS,eAAe,MAAM;AACjF,UAAI,OAAO,cAAc,YAAa,eAAc,eAAe;AACnE,aACF,eAAe,YAAY,CAAC,GAAG;AAC7B,YAAI;AAgBN,YAAI,SAAS;AAGb,YAAI,qBAAqB;AAEzB,YAAI,eAAe,IAAI,QAAQ,CAAC,SAAS,WAAW;AAClD,gCAAsB;AACtB,+BAAqB;AAAA,QACvB,CAAC;AAKD,YAAI,qBAAqB,OAAO,UAAU;AAE1C,YAAI,wBAAwB,OAAO,qBAAqB;AAIxD,YAAI,sBAAsB,OAAO,WAAW,YAAY,OAAO,QAAQ,YAAY,YAAY,OAAO,QAAQ,SAAS,QAAQ,YAAY,QAAQ,QAAQ;AAE3J,YAAI,uBAAuB,CAAC,sBAAsB,CAAC,uBAAuB,CAAC;AAE3E,YAAI,qBAAqB;AAAA,QAAC;AAK1B,eAAO,+BAA+B;AAEtC,eAAO,0BAA0B;AAEjC,eAAO,qBAAqB;AAE5B,eAAO,uBAAuB;AAQ9B,YAAI,kBAAkB,OAAO,OAAO,CAAC,GAAG,MAAM;AAE9C,YAAI,aAAa,CAAC;AA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OAAO;AAClC,mBAAW;AAAA,MACb;AACA,QAAE,MAAM,MAAM;AAAA,IAChB;AAEA,WAAO;AAAA,EACT;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EASA,mBAA2B;AACzB,WAAO,EAAE,0BAA0B,KAAK,CAAC,CAAC;AAAA,EAC5C;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAWA,iBAAiB,SAAuB;AACtC,MAAE,8BAA8B,KAAK,CAAC,GAAG,GAAG,OAAO;AAAA,EACrD;AAAA;AAAA,EAGA,UAAU,UAA8C;AACtD,QAAI,CAAC,UAAU;AACb,WAAK,cAAc;AAAA,IACrB,WAAW,OAAO,aAAa,YAAY;AACzC,YAAM,IAAI,MAAM,oCAAoC;AAAA,IACtD,OAAO;AACL,WAAK,cAAc;AAAA,IACrB;AACA,WAAO;AAAA,EACT;AAAA;AAAA,EAGA,YAAgC;AAC9B,WAAO,KAAK;AAAA,EACd;AACF;",
6
+ "names": ["binary", "name", "func", "args", "instance", "module", "metadata", "result", "info", "exports", "i", "flags", "handle", "err", "memoryBase", "libName", "localScope", "module", "i", "i", "start", "i", "info", "name", "i", "i", "name", "fs", "body", "Module", "createModule", "i"]
7
+ }