Get access to a global within this instance's globals index space. This permits accessing globals whether they are exported or not. However, it is only available for purposes of debugging, and so is only permitted when `guest_debug` is enabled in the Engine's configuration. The intent of the Wasmtime API is to enforce the Wasm type system's encapsulation even in the host API, except where necessa
(
&self,
mut store: impl AsContextMut,
global_index: u32,
)
| 190 | /// `None` is returned if guest-debugging is not enabled in the |
| 191 | /// engine configuration for this Store. |
| 192 | pub fn debug_global( |
| 193 | &self, |
| 194 | mut store: impl AsContextMut, |
| 195 | global_index: u32, |
| 196 | ) -> Option<crate::Global> { |
| 197 | self.debug_export( |
| 198 | store.as_context_mut().0, |
| 199 | GlobalIndex::from_bits(global_index).into(), |
| 200 | ) |
| 201 | .and_then(|s| s.into_global()) |
| 202 | } |
| 203 | |
| 204 | /// Get access to a memory (unshared only) within this instance's |
| 205 | /// memory index space. |
no test coverage detected