Struct evmc_sys::evmc_vm[][src]

#[repr(C)]
pub struct evmc_vm { pub abi_version: c_int, pub name: *const c_char, pub version: *const c_char, pub destroy: evmc_destroy_fn, pub execute: evmc_execute_fn, pub get_capabilities: evmc_get_capabilities_fn, pub set_option: evmc_set_option_fn, }
Expand description

The VM instance.

Defines the base struct of the VM implementation.

Fields

abi_version: c_int

EVMC ABI version implemented by the VM instance.

Can be used to detect ABI incompatibilities. The EVMC ABI version represented by this file is in ::EVMC_ABI_VERSION.

name: *const c_char

The name of the EVMC VM implementation.

It MUST be a NULL-terminated not empty string. The content MUST be UTF-8 encoded (this implies ASCII encoding is also allowed).

version: *const c_char

The version of the EVMC VM implementation, e.g. “1.2.3b4”.

It MUST be a NULL-terminated not empty string. The content MUST be UTF-8 encoded (this implies ASCII encoding is also allowed).

destroy: evmc_destroy_fn

Pointer to function destroying the VM instance.

This is a mandatory method and MUST NOT be set to NULL.

execute: evmc_execute_fn

Pointer to function executing a code by the VM instance.

This is a mandatory method and MUST NOT be set to NULL.

get_capabilities: evmc_get_capabilities_fn

A method returning capabilities supported by the VM instance.

The value returned MAY change when different options are set via the set_option() method.

A Client SHOULD only rely on the value returned if it has queried it after it has called the set_option().

This is a mandatory method and MUST NOT be set to NULL.

set_option: evmc_set_option_fn

Optional pointer to function modifying VM’s options.

If the VM does not support this feature the pointer can be NULL.

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

Feeds this value into the given Hasher. Read more

Feeds a slice of this type into the given Hasher. Read more

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Performs the conversion.

Performs the conversion.

The resulting type after obtaining ownership.

Creates owned data from borrowed data, usually by cloning. Read more

🔬 This is a nightly-only experimental API. (toowned_clone_into)

recently added

Uses borrowed data to replace owned data, usually by cloning. Read more

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.