Commit graph

32 commits

Author SHA1 Message Date
ObserverOfTime
b9c2d1dc89 feat(bindings): add Java bindings 2025-12-08 15:47:15 -05:00
Will Lillis
bec7c3272b fix(loader)!: correct arguments passed to select_language 2025-12-07 17:11:28 -05:00
WillLillis
df8b62fc50 feat(xtask): bring wasi-sdk treatment up to par with the loader
The loader package's `ensure_wasi_sdk_exists` private method checks for
the wasi-sdk, fetching it if it can't be found. This logic was
re-implemented in xtask for `build-wasm-stdlib`, but without the
fetching functionality. We can have nice things in xtask too! Rather
than make this function a public member of `tree-sitter-loader`, we
just re-implement and leave a nice comment asking people to keep the
two in sync.
2025-11-27 16:06:25 -05:00
ObserverOfTime
14b4708018 fix(loader): write Wasm lib directly to lib dir
Problem: `fs::rename` fails if the parser directory and the Tree-sitter
library directory are on different file systems.

Solution: Write the library file directly to the final directory.
2025-11-25 17:23:44 +01:00
Christian Clason
d64b863030 build(deps): bump wasi-sdk to v29 2025-11-25 07:41:04 +01:00
Antonin Delpeuch
0e1f715ef1 Move PathsJSON method, reformat 2025-11-19 03:57:13 -05:00
Antonin Delpeuch
f3012a999d feat(bindings): expose the queries dynamically
Available in the Rust, Python, and Node bindings

Co-authored-by: ObserverOfTime <chronobserver@disroot.org>
2025-11-19 03:57:13 -05:00
Valeriy Kosikhin
57e3a7b2ca fix(loader): set correct runtime host for cc while cross-compiling
Pass the BUILD_TARGET variable from the build environment as 'host' for
the cc crate. Otherwise, when cross-compiled, cc will keep looking for a
cross-compiler instead of the native one on the target system.

Signed-off-by: Valeriy Kosikhin <vkosikhin@gmail.com>
2025-11-17 18:19:34 +01:00
WillLillis
67cb3cb881 refactor(loader)!: transition from anyhow to thiserror 2025-11-14 11:28:00 +01:00
Amaan Qureshi
92efd26380 fix(loader): allow parallel compilation on windows 2025-10-01 02:57:04 -04:00
Amaan Qureshi
4edcca9850 style(loader): appease clippy 2025-09-28 05:54:28 -04:00
Amaan Qureshi
d543e2e50b refactor(loader): use the logger 2025-09-21 01:53:22 -04:00
ObserverOfTime
60c3bed6a4 fix(loader): install arm64 wasi-sdk on arm64 windows 2025-09-20 18:11:48 -04:00
ObserverOfTime
6dfa79013f feat(loader): respect NM env var 2025-09-20 18:08:07 -04:00
Nia
f09dc3cf46
fix(wasm): fix alias map size computation
This fixes a crash where parsing with certain languages can lead to a crash due to how the alias map was allocated and laid out in wasm memory
2025-09-18 18:34:27 -04:00
Will Lillis
46ea65c89b refactor: remove url dependency 2025-09-17 04:31:53 -04:00
Amaan Qureshi
1d0ebd1065 fix(rust): do not interpret readme doc comments as doc tests 2025-09-04 04:22:32 -04:00
Amaan Qureshi
4559ec51f7 fix(loader): correct logic when downloading wasi-sdk 2025-09-02 16:07:37 -04:00
Amaan Qureshi
5263cd0706 refactor(loader): use the tar binary to extract the wasi sdk 2025-09-02 16:07:37 -04:00
Amaan Qureshi
4535ea6aaa refactor(loader): use the curl binary instead of ureq to download wasi-sdk 2025-09-02 16:07:37 -04:00
Amaan Qureshi
22d658518b feat(loader): allow specifying the wasi sdk path 2025-09-01 23:14:20 -04:00
Boris Verkhovskiy
9b23cd5394
feat: use compileStreaming when loading wasm parsers 2025-09-01 22:08:20 -04:00
Will Lillis
a12a79b366 fix(cli): canonicalize --lib-path arguments
This fixes an issue where "./foo.so" would would work but "foo.so" would not.
2025-08-31 01:10:43 -04:00
ObserverOfTime
b57b7213a9 fix(rust): make some methods const
Addresses clippy::missing-const-for-fn
2025-08-30 16:47:47 +03:00
ObserverOfTime
88e0b4cea4 docs: change WASM/wasm to Wasm
That is the official capitalisation.
2025-08-21 09:56:32 +03:00
Will Lillis
e749a97f9f fix(rust): make String clones more explicit 2025-08-09 16:02:28 -04:00
ObserverOfTime
f7838748df fix(cli): drop homepage link from config
We don't actually use this currently and the vast majority of grammars
don't have a homepage other than the repository itself.
2025-08-09 10:14:17 +03:00
Will Lillis
346080aad2 refactor(loader): replace replace_dashes_with_underscores with rust std lib 2025-08-03 14:34:04 -04:00
Will Lillis
acfeed006a feat(cli): allow users to specify dynamic libraries directly for
parse, query, test, and fuzz subcommands
2025-08-03 14:34:04 -04:00
sammyne
4c51f27b0a feat(cli): support selecting bindings in init cmd 2025-06-15 12:43:03 +03:00
ObserverOfTime
a2c98b4b5f
fix(loader): fix no-default-features build (#4505) 2025-06-11 09:00:54 -07:00
Max Brunsfeld
0fdf569571
Reorganize rust crates into a flat crates directory, simplify some CI steps (#4496)
* Move all rust crates (except lib) into crates dir, w/o nesting

* Remove stale path from .gitattributes

* Rename lib.rs files for easier navigation

* Rename mod.rs file for easier navigation

* Fix emscripten-version path

* Fix fixtures dir paths

* Use the default rustfmt settings

* Don't use nightly on CI
2025-06-06 14:25:37 -07:00