shnewto / bnf

Parse BNF grammar definitions
MIT License
256 stars 22 forks source link

Fix WASM #122

Closed amascolo closed 1 year ago

amascolo commented 1 year ago

Additional fixes on top of https://github.com/shnewto/bnf/pull/121

So we can run:

cargo build --no-default-features --target=wasm32-unknown-unknown
coveralls commented 1 year ago

Coverage Status

Coverage: 92.231% (+0.1%) from 92.114% when pulling 13face00bddf78165b90dce9eddd02ab97fddf70 on tably-team:fix-wasm into f3ca02101c71636be2d0e7e1605578e63767082c on shnewto:main.

CrockAgile commented 1 year ago

thanks for the contribution! if you can share, i am curious what wasm plans you have in mind.

someday (months away) i was hoping to make a little wasm web app that visualizes the parse trees, so just a personal curiosity

amascolo commented 1 year ago

if you can share, i am curious what wasm plans you have in mind

Sure, it's for a spreadsheet search feature in https://tably.com/

All our code is in Rust and needs to target WASM for fast execution in the browser

I've been using bnf for the search grammar – as it's an Earley parser in Rust, which can now target WASM 🙂