summaryrefslogtreecommitdiff
path: root/crates/parser/src/lib.rs
diff options
context:
space:
mode:
authorHenry Gressmann <mail@henrygressmann.de>2023-12-04 01:53:09 +0100
committerHenry Gressmann <mail@henrygressmann.de>2023-12-04 01:53:09 +0100
commit829db60c869ea5ec9be37e6fc2ad94c2965d63d4 (patch)
treee007a6885b4d8425d05d09f9d1297c3a599f6c30 /crates/parser/src/lib.rs
parent1fb52089715631f4edb2abdc592547d0f5121161 (diff)
feat: add wat support to cli
Signed-off-by: Henry Gressmann <mail@henrygressmann.de>
Diffstat (limited to 'crates/parser/src/lib.rs')
-rw-r--r--crates/parser/src/lib.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/crates/parser/src/lib.rs b/crates/parser/src/lib.rs
index 3cc51d6..b1729f4 100644
--- a/crates/parser/src/lib.rs
+++ b/crates/parser/src/lib.rs
@@ -40,10 +40,10 @@ impl Parser {
#[cfg(feature = "std")]
pub fn parse_module_file(
&self,
- path: impl AsRef<crate::std::path::Path>,
+ path: impl AsRef<crate::std::path::Path> + Clone,
) -> Result<TinyWasmModule> {
use alloc::format;
- let f = crate::std::fs::File::open("log.txt").map_err(|e| {
+ let f = crate::std::fs::File::open(path.clone()).map_err(|e| {
ParseError::Other(format!("Error opening file {:?}: {}", path.as_ref(), e))
})?;