#[repr(C)]pub struct MemoryContextMethods {
pub alloc: Option<unsafe extern "C" fn(context: MemoryContext, size: Size) -> *mut c_void>,
pub free_p: Option<unsafe extern "C" fn(context: MemoryContext, pointer: *mut c_void)>,
pub realloc: Option<unsafe extern "C" fn(context: MemoryContext, pointer: *mut c_void, size: Size) -> *mut c_void>,
pub reset: Option<unsafe extern "C" fn(context: MemoryContext)>,
pub delete_context: Option<unsafe extern "C" fn(context: MemoryContext)>,
pub get_chunk_space: Option<unsafe extern "C" fn(context: MemoryContext, pointer: *mut c_void) -> Size>,
pub is_empty: Option<unsafe extern "C" fn(context: MemoryContext) -> bool>,
pub stats: Option<unsafe extern "C" fn(context: MemoryContext, printfunc: MemoryStatsPrintFunc, passthru: *mut c_void, totals: *mut MemoryContextCounters, print_to_stderr: bool)>,
pub check: Option<unsafe extern "C" fn(context: MemoryContext)>,
}
Fields§
§alloc: Option<unsafe extern "C" fn(context: MemoryContext, size: Size) -> *mut c_void>
§free_p: Option<unsafe extern "C" fn(context: MemoryContext, pointer: *mut c_void)>
§realloc: Option<unsafe extern "C" fn(context: MemoryContext, pointer: *mut c_void, size: Size) -> *mut c_void>
§reset: Option<unsafe extern "C" fn(context: MemoryContext)>
§delete_context: Option<unsafe extern "C" fn(context: MemoryContext)>
§get_chunk_space: Option<unsafe extern "C" fn(context: MemoryContext, pointer: *mut c_void) -> Size>
§is_empty: Option<unsafe extern "C" fn(context: MemoryContext) -> bool>
§stats: Option<unsafe extern "C" fn(context: MemoryContext, printfunc: MemoryStatsPrintFunc, passthru: *mut c_void, totals: *mut MemoryContextCounters, print_to_stderr: bool)>
§check: Option<unsafe extern "C" fn(context: MemoryContext)>
Trait Implementations§
Source§impl Clone for MemoryContextMethods
impl Clone for MemoryContextMethods
Source§fn clone(&self) -> MemoryContextMethods
fn clone(&self) -> MemoryContextMethods
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for MemoryContextMethods
impl Debug for MemoryContextMethods
Source§impl Default for MemoryContextMethods
impl Default for MemoryContextMethods
Source§fn default() -> MemoryContextMethods
fn default() -> MemoryContextMethods
Returns the “default value” for a type. Read more
impl Copy for MemoryContextMethods
Auto Trait Implementations§
impl Freeze for MemoryContextMethods
impl RefUnwindSafe for MemoryContextMethods
impl Send for MemoryContextMethods
impl Sync for MemoryContextMethods
impl Unpin for MemoryContextMethods
impl UnwindSafe for MemoryContextMethods
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more