wasmer/lib/runtime-c-api/src/lib.rs

40 lines
648 B
Rust
Raw Normal View History

2019-02-01 05:51:34 +00:00
extern crate wasmer_runtime;
extern crate wasmer_runtime_core;
2019-02-01 05:51:34 +00:00
use libc::{uint32_t, uint8_t};
2019-02-01 05:51:34 +00:00
pub mod error;
pub mod export;
pub mod global;
pub mod import;
pub mod instance;
pub mod memory;
pub mod module;
pub mod table;
pub mod value;
2019-02-01 05:51:34 +00:00
#[allow(non_camel_case_types)]
#[repr(C)]
2019-02-12 01:07:28 +00:00
pub enum wasmer_result_t {
WASMER_OK = 1,
WASMER_ERROR = 2,
2019-02-09 19:37:07 +00:00
}
2019-02-05 03:46:47 +00:00
#[repr(C)]
pub struct wasmer_limits_t {
pub min: uint32_t,
pub max: wasmer_limit_option_t,
}
#[repr(C)]
pub struct wasmer_limit_option_t {
pub has_some: bool,
pub some: uint32_t,
}
2019-02-14 06:00:39 +00:00
#[repr(C)]
pub struct wasmer_byte_array {
bytes: *const uint8_t,
bytes_len: uint32_t,
}