tinywasm-parser

Crates.iotinywasm-parser
lib.rstinywasm-parser
version0.8.0
sourcesrc
created_at2023-12-09 14:10:42.77741
updated_at2024-08-29 13:24:03.255595
descriptionTinyWasm parser
homepage
repositoryhttps://github.com/explodingcamera/tinywasm
max_upload_size
id1063700
size59,186
Henry Gressmann (explodingcamera)

documentation

README

tinywasm-parser

This crate provides a parser that can parse WebAssembly modules into a TinyWasm module. It uses my fork of the wasmparser crate that has been modified to be compatible with no_std environments.

Features

  • std: Enables the use of std and std::io for parsing from files and streams.
  • logging: Enables logging of the parsing process using the log crate.

Usage

use tinywasm_parser::Parser;
let bytes = include_bytes!("./file.wasm");

let parser = Parser::new();
let module = parser.parse_module_bytes(bytes).unwrap();
let mudule = parser.parse_module_file("path/to/file.wasm").unwrap();
let module = parser.parse_module_stream(&mut stream).unwrap();
Commit count: 263

cargo fmt