#[repr(C)]pub struct NativeInfo {
pub name: *const c_char,
pub func: Option<unsafe extern "C" fn(ctx: IPluginContextPtr, args: *const cell_t) -> cell_t>,
}
Expand description
Struct to contain name/fnptr pairs for native registration.
SourceMod has very strict lifetime requirements for this data and you should not construct
instances of this type yourself - use the register_natives!
macro instead.
Fields§
§name: *const c_char
§func: Option<unsafe extern "C" fn(ctx: IPluginContextPtr, args: *const cell_t) -> cell_t>
Auto Trait Implementations§
impl Freeze for NativeInfo
impl RefUnwindSafe for NativeInfo
impl !Send for NativeInfo
impl !Sync for NativeInfo
impl Unpin for NativeInfo
impl UnwindSafe for NativeInfo
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