Sha256: e3cd62f66534358b2274ca1e4978a3fd5f7f05e2e1a4b35a9366055cb69dce6a
Contents?: true
Size: 989 Bytes
Versions: 2
Compression:
Stored size: 989 Bytes
Contents
//! Custom platform support in Wasmtime. //! //! This module contains an implementation of defining Wasmtime's platform //! support in terms of a minimal C API. This API can be found in the `capi` //! module and all other functionality here is implemented in terms of that //! module. //! //! For more information about this see `./examples/min-platform` as well as //! `./docs/examples-minimal.md`. #![warn(dead_code, unused_imports)] #[cfg(feature = "signals-based-traps")] use crate::prelude::*; pub mod capi; #[cfg(feature = "signals-based-traps")] pub mod mmap; pub mod traphandlers; pub mod unwind; #[cfg(feature = "signals-based-traps")] pub mod vm; #[cfg(feature = "signals-based-traps")] fn cvt(rc: i32) -> Result<()> { match rc { 0 => Ok(()), code => bail!("os error {code}"), } } #[inline] pub fn tls_get() -> *mut u8 { unsafe { capi::wasmtime_tls_get() } } #[inline] pub fn tls_set(ptr: *mut u8) { unsafe { capi::wasmtime_tls_set(ptr) } }
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
wasmtime-29.0.0 | ./ext/cargo-vendor/wasmtime-29.0.0/src/runtime/vm/sys/custom/mod.rs |
wasmtime-28.0.0 | ./ext/cargo-vendor/wasmtime-28.0.0/src/runtime/vm/sys/custom/mod.rs |