Initial support for function, table, memory, and global imports.
This commit is contained in:
@@ -94,7 +94,7 @@ fn main() {
|
||||
}
|
||||
|
||||
let isa = isa_builder.finish(settings::Flags::new(flag_builder));
|
||||
let mut wast_context = WastContext::new();
|
||||
let mut wast_context = WastContext::new().expect("Error creating WastContext");
|
||||
for filename in &args.arg_file {
|
||||
wast_context
|
||||
.run_file(&*isa, Path::new(&filename))
|
||||
|
||||
@@ -184,11 +184,13 @@ fn handle_module(args: &Args, path: &Path, isa: &TargetIsa) -> Result<(), String
|
||||
if split.len() != 3 {
|
||||
break;
|
||||
}
|
||||
let memory = world.inspect_memory(
|
||||
MemoryIndex::new(str::parse(split[0]).unwrap()),
|
||||
str::parse(split[1]).unwrap(),
|
||||
str::parse(split[2]).unwrap(),
|
||||
);
|
||||
let memory = world
|
||||
.inspect_memory(
|
||||
MemoryIndex::new(str::parse(split[0]).unwrap()),
|
||||
str::parse(split[1]).unwrap(),
|
||||
str::parse(split[2]).unwrap(),
|
||||
)
|
||||
.map_err(|e| e.to_string())?;
|
||||
let mut s = memory.iter().fold(String::from("#"), |mut acc, byte| {
|
||||
acc.push_str(format!("{:02x}_", byte).as_str());
|
||||
acc
|
||||
|
||||
Reference in New Issue
Block a user