Skip to main content

MachineInteger

Trait MachineInteger 

Source
pub trait MachineInteger {
    const SIGNED: bool;

    // Required method
    fn bits() -> u32;
}
Expand description

A trait for types that represent machine integers.

Required Associated Constants§

Source

const SIGNED: bool

The signedness of this integer type.

Required Methods§

Source

fn bits() -> u32

The size of this integer type in bits.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementations on Foreign Types§

Source§

impl MachineInteger for i8

Source§

impl MachineInteger for i16

Source§

impl MachineInteger for i32

Source§

impl MachineInteger for i64

Source§

impl MachineInteger for i128

Source§

impl MachineInteger for u8

Source§

impl MachineInteger for u16

Source§

impl MachineInteger for u32

Source§

impl MachineInteger for u64

Source§

impl MachineInteger for u128

Implementors§