WithSigned

Trait WithSigned 

Source
pub trait WithSigned {
    type Signed;

    // Required method
    fn to_signed(self) -> Self::Signed;
}
Expand description

Represents a number type with corresponding signed version

Signed number can implement this trait as well, with type Signed = Self.

Required Associated Types§

Required Methods§

Source

fn to_signed(self) -> Self::Signed

Implementations on Foreign Types§

Source§

impl WithSigned for i8

Source§

type Signed = i8

Source§

fn to_signed(self) -> Self

Source§

impl WithSigned for i16

Source§

type Signed = i16

Source§

fn to_signed(self) -> Self

Source§

impl WithSigned for i32

Source§

type Signed = i32

Source§

fn to_signed(self) -> Self

Source§

impl WithSigned for i64

Source§

type Signed = i64

Source§

fn to_signed(self) -> Self

Source§

impl WithSigned for i128

Source§

type Signed = i128

Source§

fn to_signed(self) -> Self

Source§

impl WithSigned for u8

Source§

type Signed = i8

Source§

fn to_signed(self) -> Self::Signed

Source§

impl WithSigned for u16

Source§

type Signed = i16

Source§

fn to_signed(self) -> Self::Signed

Source§

impl WithSigned for u32

Source§

type Signed = i32

Source§

fn to_signed(self) -> Self::Signed

Source§

impl WithSigned for u64

Source§

type Signed = i64

Source§

fn to_signed(self) -> Self::Signed

Source§

impl WithSigned for u128

Source§

impl WithSigned for BigInt

Source§

impl WithSigned for BigUint

Implementors§