Enum target_lexicon::CallingConvention
source · [−]#[non_exhaustive]
pub enum CallingConvention {
SystemV,
WasmBasicCAbi,
WindowsFastcall,
AppleAarch64,
}
Expand description
The calling convention, which specifies things like which registers are used for passing arguments, which registers are callee-saved, and so on.
Variants (Non-exhaustive)
This enum is marked as non-exhaustive
SystemV
“System V”, which is used on most Unix-like platfoms. Note that the specific conventions vary between hardware architectures; for example, x86-32’s “System V” is entirely different from x86-64’s “System V”.
WasmBasicCAbi
The WebAssembly C ABI. https://github.com/WebAssembly/tool-conventions/blob/master/BasicCABI.md
WindowsFastcall
“Windows Fastcall”, which is used on Windows. Note that like “System V”, this varies between hardware architectures. On x86-32 it describes what Windows documentation calls “fastcall”, and on x86-64 it describes what Windows documentation often just calls the Windows x64 calling convention (though the compiler still recognizes “fastcall” as an alias for it).
AppleAarch64
Apple Aarch64 platforms use their own variant of the common Aarch64 calling convention.
https://developer.apple.com/documentation/xcode/writing_arm64_code_for_apple_platforms
Trait Implementations
sourceimpl Clone for CallingConvention
impl Clone for CallingConvention
sourcefn clone(&self) -> CallingConvention
fn clone(&self) -> CallingConvention
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
sourceimpl Debug for CallingConvention
impl Debug for CallingConvention
sourceimpl Hash for CallingConvention
impl Hash for CallingConvention
impl Copy for CallingConvention
impl Eq for CallingConvention
impl StructuralEq for CallingConvention
impl StructuralPartialEq for CallingConvention
Auto Trait Implementations
impl RefUnwindSafe for CallingConvention
impl Send for CallingConvention
impl Sync for CallingConvention
impl Unpin for CallingConvention
impl UnwindSafe for CallingConvention
Blanket Implementations
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<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