py-wasm
py-wasm copied to clipboard
[WIP] S-expression parsing of text modules
What was wrong?
Issue #
How was it fixed?
Summary of approach.
Cute Animal Picture
Was just taking a look at this. It looks like you've written a grammar which is pretty explicit. Is there a reason you didn't go with a more generic s-expression grammar and then verify s-expression content as a kind of post-processing step? I'm wondering if that wouldn't be simpler and allow you to forgo any possible headaches relating to writing a lengthy grammar.
Actually, reviewing the WASM spec now, it looks like the text grammar is pretty well-defined. So I guess that's probably one reason you did it that way.
Actually, reviewing the WASM spec now, it looks like the text grammar is pretty well-defined. So I guess that's probably one reason you did it that way.
Yeah, I took their provided grammar and am converting it bit-by-bit to parsimonious.
I had that thought yesterday (use a generic s-expression grammar), but I think I like the up-front validation that this explicit grammar provides.