Switch from wabt crate to wast (#434)
* Switch lightbeam from `wabt` to `wast` Switch from a C++-based `*.wat` parser to a Rust-based parser * Remove unneeded `wabt` dev-dependency from wasmtime-api * Rewrite `wasmtime-wast` crate with `wast-parser` This commit moves the `wasmtime-wast` crate off the `wabt` crate on to the `wast-parser` crate which is a Rust implementation of a `*.wast` and `*.wat` parser. The intention here is to continue to reduce the amount of C++ required to build wasmtime! * Use new `wat` and `wast` crate names
This commit is contained in:
committed by
Dan Gohman
parent
ebef2c6b57
commit
9947bc5209
@@ -20,8 +20,6 @@ extern crate lazy_static;
|
||||
#[cfg(test)]
|
||||
#[macro_use]
|
||||
extern crate quickcheck;
|
||||
#[cfg(test)]
|
||||
extern crate wabt;
|
||||
// Just so we can implement `Signature` for `cranelift_codegen::ir::Signature`
|
||||
extern crate cranelift_codegen;
|
||||
extern crate multi_mut;
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
use super::{module::ExecutionError, translate, ExecutableModule};
|
||||
use wabt;
|
||||
|
||||
fn translate_wat(wat: &str) -> ExecutableModule {
|
||||
let wasm = wabt::wat2wasm(wat).unwrap();
|
||||
let wasm = wat::parse_str(wat).unwrap();
|
||||
let compiled = translate(&wasm).unwrap();
|
||||
compiled
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user