1#![allow(non_upper_case_globals)]
7#![allow(non_camel_case_types)]
8#![allow(non_snake_case)]
9
10include!(concat!(env!("OUT_DIR"), "/bindings.rs"));
11
12pub type evmc_host_context = ::std::os::raw::c_void;
15
16impl Default for evmc_address {
21 fn default() -> Self {
22 evmc_address { bytes: [0u8; 20] }
23 }
24}
25
26impl Default for evmc_bytes32 {
27 fn default() -> Self {
28 evmc_bytes32 { bytes: [0u8; 32] }
29 }
30}
31
32#[cfg(test)]
33mod tests {
34 use std::mem::size_of;
35
36 use super::*;
37
38 #[test]
39 fn container_new() {
40 assert_eq!(size_of::<evmc_bytes32>(), 32);
42 assert_eq!(size_of::<evmc_address>(), 20);
43 assert!(size_of::<evmc_result>() <= 64);
44 assert!(size_of::<evmc_vm>() <= 64);
45 }
46}