Performs the instantiation process into the store specified. # Errors This function will return an [`OutOfMemory`][crate::OutOfMemory] error when memory allocation fails. See the `OutOfMemory` type's documentation for details on Wasmtime's out-of-memory handling. TODO: needs more docs
(&self, mut store: impl AsContextMut<Data = T>)
| 1134 | // |
| 1135 | // TODO: needs more docs |
| 1136 | pub fn instantiate(&self, mut store: impl AsContextMut<Data = T>) -> Result<Instance> { |
| 1137 | let store = store.as_context_mut(); |
| 1138 | |
| 1139 | // If this instance requires an async host, set that flag in the store, |
| 1140 | // and then afterwards assert nothing else in the store, nor this |
| 1141 | // instance, required async. |
| 1142 | store.0.set_async_required(self.asyncness); |
| 1143 | store.0.validate_sync_call()?; |
| 1144 | |
| 1145 | vm::assert_ready(self._instantiate(store, Asyncness::No)) |
| 1146 | } |
| 1147 | /// Performs the instantiation process into the store specified. |
| 1148 | /// |
| 1149 | /// Exactly like [`Self::instantiate`] except for use on async stores. |
nothing calls this directly
no test coverage detected