cairo_lang_sierra::extensions::modules::int::unsigned

Trait UintTraits

Source
pub trait UintTraits: IntTraits {
    const OVERFLOWING_ADD: &'static str;
    const OVERFLOWING_SUB: &'static str;
    const SQUARE_ROOT: &'static str;
    const SQUARE_ROOT_TYPE_ID: GenericTypeId;
    const DIVMOD: &'static str;
    const BITWISE: &'static str;
}
Expand description

Trait for implementing unsigned integers.

Required Associated Constants§

Source

const OVERFLOWING_ADD: &'static str

The generic libfunc id for addition.

Source

const OVERFLOWING_SUB: &'static str

The generic libfunc id for subtraction.

Source

const SQUARE_ROOT: &'static str

The generic libfunc id for calculating the integer square root.

Source

const SQUARE_ROOT_TYPE_ID: GenericTypeId

The generic type id for the type’s square root.

Source

const DIVMOD: &'static str

The generic libfunc id that divides two integers.

Source

const BITWISE: &'static str

The generic libfunc id that provides bitwise operations on two integers.

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.

Implementors§

Source§

impl UintTraits for Uint128Traits

Source§

const OVERFLOWING_ADD: &'static str = "u128_overflowing_add"

Source§

const OVERFLOWING_SUB: &'static str = "u128_overflowing_sub"

Source§

const SQUARE_ROOT: &'static str = "u128_sqrt"

Source§

const SQUARE_ROOT_TYPE_ID: GenericTypeId = <Uint64Type as NamedType>::ID

Source§

const DIVMOD: &'static str = "u128_safe_divmod"

Source§

const BITWISE: &'static str = "bitwise"

Source§

impl UintTraits for Uint8Traits

Source§

const OVERFLOWING_ADD: &'static str = "u8_overflowing_add"

Source§

const OVERFLOWING_SUB: &'static str = "u8_overflowing_sub"

Source§

const SQUARE_ROOT: &'static str = "u8_sqrt"

Source§

const SQUARE_ROOT_TYPE_ID: GenericTypeId = <Self as IntTraits>::GENERIC_TYPE_ID

Source§

const DIVMOD: &'static str = "u8_safe_divmod"

Source§

const BITWISE: &'static str = "u8_bitwise"

Source§

impl UintTraits for Uint16Traits

Source§

const OVERFLOWING_ADD: &'static str = "u16_overflowing_add"

Source§

const OVERFLOWING_SUB: &'static str = "u16_overflowing_sub"

Source§

const SQUARE_ROOT: &'static str = "u16_sqrt"

Source§

const SQUARE_ROOT_TYPE_ID: GenericTypeId = <Uint8Type as NamedType>::ID

Source§

const DIVMOD: &'static str = "u16_safe_divmod"

Source§

const BITWISE: &'static str = "u16_bitwise"

Source§

impl UintTraits for Uint32Traits

Source§

const OVERFLOWING_ADD: &'static str = "u32_overflowing_add"

Source§

const OVERFLOWING_SUB: &'static str = "u32_overflowing_sub"

Source§

const SQUARE_ROOT: &'static str = "u32_sqrt"

Source§

const SQUARE_ROOT_TYPE_ID: GenericTypeId = <Uint16Type as NamedType>::ID

Source§

const DIVMOD: &'static str = "u32_safe_divmod"

Source§

const BITWISE: &'static str = "u32_bitwise"

Source§

impl UintTraits for Uint64Traits

Source§

const OVERFLOWING_ADD: &'static str = "u64_overflowing_add"

Source§

const OVERFLOWING_SUB: &'static str = "u64_overflowing_sub"

Source§

const SQUARE_ROOT: &'static str = "u64_sqrt"

Source§

const SQUARE_ROOT_TYPE_ID: GenericTypeId = <Uint32Type as NamedType>::ID

Source§

const DIVMOD: &'static str = "u64_safe_divmod"

Source§

const BITWISE: &'static str = "u64_bitwise"