Instantiates the pre-instance.
(&self, store: impl AsContextMut<Data = T>)
| 303 | impl<T: 'static> ProxyPre<T> { |
| 304 | /// Instantiates the pre-instance. |
| 305 | pub async fn instantiate_async(&self, store: impl AsContextMut<Data = T>) -> Result<Proxy> |
| 306 | where |
| 307 | T: Send, |
| 308 | { |
| 309 | Ok(match self { |
| 310 | #[cfg(feature = "p2")] |
| 311 | Self::P2(pre) => Proxy::P2(pre.instantiate_async(store).await?), |
| 312 | #[cfg(feature = "p3")] |
| 313 | Self::P3(pre) => Proxy::P3(pre.instantiate_async(store).await?), |
| 314 | }) |
| 315 | } |
| 316 | } |
| 317 | |
| 318 | /// Represents either a `wasi:http/incoming-handler@0.2.x` or |