mirror of
https://github.com/tree-sitter/tree-sitter.git
synced 2026-09-10 07:36:22 -04:00
* feat(wasm): make syntax trees sendable
* test(wasm): transfer trees across workers
* test(wasm): use JSON grammar for tree transfer
* test(wasm): edit trees across workers
* test(wasm): share dlmalloc with tree-sitter
* test(wasm): simplify worker tree exchange
* test(wasm): drive tree exchange from Rust
* test(wasm): split sendable-tree xtask
* test(wasm): generalize Rust web fixture
* test(wasm): exercise parallel Rust tree access
* fix(wasm): use Rust global allocator for C core
* test(wasm): use default Rust allocator
* feat(wasm): support external scanners in Rust web apps
* Simplify example further, add a readme
* Regenerate wasm-stdlib
* Fix wasm_stdlib check script
* Vendor the Wasm standard library subset
* Test Unicode Ruby scanner behavior in Wasm
* Make Wasm tree languages instance-aware
* Test multi-threaded use of queries in wasm32-unknown
* Refactor reference-counted language storage
* Check ABI version compat before loading rest of language
* 🎨 Remove redundant #ifdef block
* Reject unsupported Rust Wasm builds on 0.26
15 lines
544 B
Rust
15 lines
544 B
Rust
fn main() {
|
|
if std::env::var("TARGET")
|
|
.unwrap_or_default()
|
|
.starts_with("wasm32-unknown")
|
|
{
|
|
let manifest_dir = std::env::var("CARGO_MANIFEST_DIR").unwrap();
|
|
let wasm_headers = std::path::Path::new(&manifest_dir).join("wasm/include");
|
|
let wasm_src =
|
|
std::path::Path::new(&manifest_dir).join("wasm/unsupported/tree-sitter-0.26");
|
|
|
|
println!("cargo::metadata=wasm-headers={}", wasm_headers.display());
|
|
println!("cargo::metadata=wasm-src={}", wasm_src.display());
|
|
}
|
|
}
|