Remove the concept of non-dense jump tables.
WebAssembly doesn't have non-dense jump tables, and higher-level users are better served by the facilities in lib/frontend/src/switch.rs for working with non-dense switches. This eliminates the concept of "absent" jump table entries, which were represented as "0" in the text format. Also, jump table contents are now enclosed in `[` and `]`, so that we can unambiguously display empty jump tables. Previously, empty jump tables were displayed as if they had a single absent entry.
This commit is contained in:
@@ -1229,8 +1229,8 @@ impl<'a> Verifier<'a> {
|
||||
);
|
||||
}
|
||||
}
|
||||
for (_, ebb) in self.func.jump_tables[table].entries() {
|
||||
let arg_count = self.func.dfg.num_ebb_params(ebb);
|
||||
for ebb in self.func.jump_tables[table].iter() {
|
||||
let arg_count = self.func.dfg.num_ebb_params(*ebb);
|
||||
if arg_count != 0 {
|
||||
return nonfatal!(
|
||||
errors,
|
||||
|
||||
Reference in New Issue
Block a user