Struct wasmer_types::InstanceConfig
source · [−]pub struct InstanceConfig {
pub gas_counter: *mut FastGasCounter,
pub stack_limit: i32,
/* private fields */
}
Expand description
External configuration of execution environment for Instance.
Fields
gas_counter: *mut FastGasCounter
External gas counter pointer.
stack_limit: i32
Stack limit, in 8-byte slots.
Implementations
sourceimpl InstanceConfig
impl InstanceConfig
sourcepub unsafe fn with_counter(self, gas_counter: *mut FastGasCounter) -> Self
pub unsafe fn with_counter(self, gas_counter: *mut FastGasCounter) -> Self
Create instance configuration with an external gas counter, unsafe as it creates
an alias on raw memory of gas_counter. This memory could be accessed until
instance configured with this InstanceConfig
exists.
sourcepub unsafe fn with_stack_limit(self, stack_limit: i32) -> Self
pub unsafe fn with_stack_limit(self, stack_limit: i32) -> Self
Create instance configuration with given stack limit.
Trait Implementations
sourceimpl Clone for InstanceConfig
impl Clone for InstanceConfig
sourcefn clone(&self) -> InstanceConfig
fn clone(&self) -> InstanceConfig
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
Auto Trait Implementations
impl !RefUnwindSafe for InstanceConfig
impl !Send for InstanceConfig
impl !Sync for InstanceConfig
impl Unpin for InstanceConfig
impl !UnwindSafe for InstanceConfig
Blanket Implementations
sourceimpl<T> ArchivePointee for T
impl<T> ArchivePointee for T
type ArchivedMetadata = ()
type ArchivedMetadata = ()
The archived version of the pointer metadata for this type.
sourcefn pointer_metadata(
&<T as ArchivePointee>::ArchivedMetadata
) -> <T as Pointee>::Metadata
fn pointer_metadata(
&<T as ArchivePointee>::ArchivedMetadata
) -> <T as Pointee>::Metadata
Converts some archived metadata to the pointer metadata for itself.
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<F, W, T, D> Deserialize<With<T, W>, D> for F where
W: DeserializeWith<F, T, D>,
D: Fallible + ?Sized,
F: ?Sized,
impl<F, W, T, D> Deserialize<With<T, W>, D> for F where
W: DeserializeWith<F, T, D>,
D: Fallible + ?Sized,
F: ?Sized,
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more