tlaplus-community / tree-sitter-tlaplus

A tree-sitter grammar for TLA⁺ and PlusCal
MIT License
57 stars 10 forks source link

Build rust project with tree-sitter-tlaplus to wasm target #121

Closed FedericoPonzi closed 4 months ago

FedericoPonzi commented 4 months ago

I'd like to write a program in rust using tree-sitter-tlaplus and compile it to wasm. When I try to compile it to wasm it fails with:

[...]
  CFLAGS = None
  cargo:warning=In file included from /home/fponzi/.cargo/registry/src/index.crates.io-6f17d22bba15001f/tree-sitter-0.22.6/src/lib.c:3:
  cargo:warning=In file included from /home/fponzi/.cargo/registry/src/index.crates.io-6f17d22bba15001f/tree-sitter-0.22.6/src/./alloc.c:1:
  cargo:warning=/home/fponzi/.cargo/registry/src/index.crates.io-6f17d22bba15001f/tree-sitter-0.22.6/src/alloc.h:9:10: fatal error: 'stdio.h' file not found
  cargo:warning=#include <stdio.h>
  cargo:warning=         ^~~~~~~~~
  cargo:warning=1 error generated.
[...]

Is it possible to compile it to wasm?