pub enum Abi {
Rust,
C,
System,
Win64,
Sysv64,
Aapcs,
Cdecl,
Stdcall,
Fastcall,
Vectorcall,
}Expand description
The abi or calling convention of a function pointer.
Variants§
Rust
The default ABI when you write a normal fn foo() in any Rust code.
C
This is the same as extern fn foo(); whatever the default your C compiler supports.
System
Usually the same as extern "C", except on Win32, in which case it’s "stdcall", or what you should use to link to the Windows API itself.
Win64
The default for C code on x86_64 Windows.
Sysv64
The default for C code on non-Windows x86_64.
Aapcs
The default for ARM.
Cdecl
The default for x86_32 C code.
Stdcall
The default for the Win32 API on x86_32.
Fastcall
The fastcall ABI – corresponds to MSVC’s __fastcall and GCC and clang’s __attribute__((fastcall))
Vectorcall
The vectorcall ABI – corresponds to MSVC’s __vectorcall and GCC and clang’s __attribute__((vectorcall))
Implementations§
Trait Implementations§
impl ConstParamTy_ for Abi
impl Copy for Abi
impl Eq for Abi
impl StructuralPartialEq for Abi
Auto Trait Implementations§
impl Freeze for Abi
impl RefUnwindSafe for Abi
impl Send for Abi
impl Sync for Abi
impl Unpin for Abi
impl UnwindSafe for Abi
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