Get two mutable tables at the actual index in the store
(
&mut self,
addr: TableAddr,
addr2: TableAddr,
)
| 216 | |
| 217 | /// Get two mutable tables at the actual index in the store |
| 218 | pub(crate) fn get_tables_mut( |
| 219 | &mut self, |
| 220 | addr: TableAddr, |
| 221 | addr2: TableAddr, |
| 222 | ) -> (&mut TableInstance, &mut TableInstance) { |
| 223 | match self.tables.get_disjoint_mut([addr as usize, addr2 as usize]) { |
| 224 | Ok([table_a, table_b]) => (table_a, table_b), |
| 225 | Err(_) => { |
| 226 | cold_path(); |
| 227 | unreachable!("table {addr} or {addr2} not found. This should be unreachable") |
| 228 | } |
| 229 | } |
| 230 | } |
| 231 | |
| 232 | /// Get the data at the actual index in the store |
| 233 | pub(crate) fn get_data_mut(&mut self, addr: DataAddr) -> &mut DataInstance { |