#[repr(C)]pub struct TVMFFICustomAllocator {
pub allocate: Option<unsafe extern "C" fn(size: usize, alignment: usize, type_index: i32, context: *mut c_void) -> *mut c_void>,
pub context: *mut c_void,
}Expand description
Custom allocator entry. See TVMFFICustomAllocator in tvm/ffi/c_api.h.
Fields§
§allocate: Option<unsafe extern "C" fn(size: usize, alignment: usize, type_index: i32, context: *mut c_void) -> *mut c_void>§context: *mut c_voidAuto Trait Implementations§
impl Freeze for TVMFFICustomAllocator
impl RefUnwindSafe for TVMFFICustomAllocator
impl !Send for TVMFFICustomAllocator
impl !Sync for TVMFFICustomAllocator
impl Unpin for TVMFFICustomAllocator
impl UnsafeUnpin for TVMFFICustomAllocator
impl UnwindSafe for TVMFFICustomAllocator
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