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

Commit c1945c5

Browse files
committed
rust: turn evmc_host_context instantiable
1 parent a1d2845 commit c1945c5

2 files changed

Lines changed: 7 additions & 1 deletion

File tree

bindings/rust/evmc-sys/build.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ fn gen_bindings() {
1919
.derive_hash(true)
2020
// force deriving the PratialEq trait on basic types (address, bytes32)
2121
.derive_partialeq(true)
22-
.opaque_type("evmc_host_context")
22+
.blocklist_type("evmc_host_context")
2323
.allowlist_type("evmc_.*")
2424
.allowlist_function("evmc_.*")
2525
.allowlist_var("EVMC_ABI_VERSION")

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

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,12 @@
88

99
include!(concat!(env!("OUT_DIR"), "/bindings.rs"));
1010

11+
// Defining evmc_host_context here, because bindgen cannot create a useful declaration yet.
12+
13+
pub type evmc_host_context = ::std::os::raw::c_void;
14+
15+
//pub struct evmc_host_context { }
16+
1117
// TODO: add `.derive_default(true)` to bindgen instead?
1218

1319
impl Default for evmc_address {

0 commit comments

Comments
 (0)