wasmi_c_api/foreign.rs
1use alloc::boxed::Box;
2
3/// A foreign defined non-Wasm object.
4#[derive(Clone)]
5#[repr(C)]
6pub struct wasm_foreign_t {}
7
8wasmi_c_api_macros::declare_ref!(wasm_foreign_t);
9
10/// Creates a new foreign non-Wasm object for the [`wasm_store_t`](crate::wasm_store_t).
11///
12/// # Note
13///
14/// This API is unsupported and will panic upon use.
15#[cfg_attr(not(feature = "prefix-symbols"), no_mangle)]
16#[cfg_attr(feature = "prefix-symbols", wasmi_c_api_macros::prefix_symbol)]
17pub extern "C" fn wasm_foreign_new(_store: &crate::wasm_store_t) -> Box<wasm_foreign_t> {
18 unimplemented!("wasm_foreign_new")
19}