[][src]Function wit_text::parse_file

pub fn parse_file(file: impl AsRef<Path>) -> Result<Vec<u8>>

Parses a file on the filesystem as a textual representation of WebAssembly Interface Types, returning the binary representation of the module.

Note that the file could either be a valid *.wat or *.wasm file. In the *.wasm case the bytes are passed through unmodified.

Errors

For information about errors, see the parse_bytes documentation.