Skip to content

Commit

Permalink
Fix review comments
Browse files Browse the repository at this point in the history
  • Loading branch information
chipshort committed Jul 26, 2023
1 parent c23482f commit 18faa26
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions packages/vm/src/compatibility.rs
Original file line number Diff line number Diff line change
Expand Up @@ -213,10 +213,10 @@ fn full_import_name(ie: &Import) -> String {
}

fn check_wasm_capabilities(
exports: &ParsedWasm,
module: &ParsedWasm,
available_capabilities: &HashSet<String>,
) -> VmResult<()> {
let required_capabilities = required_capabilities_from_module(exports);
let required_capabilities = required_capabilities_from_module(module);
if !required_capabilities.is_subset(available_capabilities) {
// We switch to BTreeSet to get a sorted error message
let unavailable: BTreeSet<_> = required_capabilities
Expand Down Expand Up @@ -303,7 +303,7 @@ mod tests {
fn check_wasm_tables_works() {
// No tables is fine
let wasm = wat::parse_str("(module)").unwrap();
assert!(ParsedWasm::parse(&wasm).unwrap().memories.is_empty());
assert!(ParsedWasm::parse(&wasm).unwrap().tables.is_empty());

// One table (bound)
let wasm = wat::parse_str("(module (table $name 123 123 funcref))").unwrap();
Expand Down

0 comments on commit 18faa26

Please sign in to comment.