Skip to content
This repository was archived by the owner on Apr 8, 2026. It is now read-only.

Commit 885582b

Browse files
committed
rust: turn evmc_host_context instantiable
1 parent 61f61a6 commit 885582b

2 files changed

Lines changed: 7 additions & 2 deletions

File tree

bindings/rust/evmc-sys/build.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ fn gen_bindings() {
2222
.rustified_enum("*")
2323
// force deriving the Hash trait on basic types (address, bytes32)
2424
.derive_hash(true)
25-
.opaque_type("evmc_host_context")
25+
.blacklist_type("evmc_host_context")
2626
.whitelist_type("evmc_.*")
2727
.whitelist_function("evmc_.*")
2828
.whitelist_var("EVMC_ABI_VERSION")

bindings/rust/evmc-sys/src/lib.rs

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,15 @@
66
#![allow(non_upper_case_globals)]
77
#![allow(non_camel_case_types)]
88
#![allow(non_snake_case)]
9-
#![allow(clippy::derive_hash_xor_eq)]
109

1110
include!(concat!(env!("OUT_DIR"), "/bindings.rs"));
1211

12+
// Defining evmc_host_context here, because bindgen cannot create a useful declaration yet.
13+
14+
pub type evmc_host_context = ::std::os::raw::c_void;
15+
16+
//pub struct evmc_host_context { }
17+
1318
// TODO: with bindgen's interface improving these may be moved to
1419
// bindgen configuration
1520

0 commit comments

Comments
 (0)