dtoa::diyfp

Struct DiyFp

Source
pub struct DiyFp<F, E> {
    pub f: F,
    pub e: E,
}

Fields§

§f: F§e: E

Implementations§

Source§

impl<F, E> DiyFp<F, E>

Source

pub fn new(f: F, e: E) -> Self

Source§

impl DiyFp<u32, i32>

Source

pub(crate) unsafe fn from(d: f32) -> Self

Source

pub(crate) fn normalize(self) -> DiyFp<u32, i32>

Source

pub(crate) fn normalize_boundary(self) -> DiyFp<u32, i32>

Source

pub(crate) fn normalized_boundaries(self) -> (DiyFp<u32, i32>, DiyFp<u32, i32>)

Source§

impl DiyFp<u64, isize>

Source

pub(crate) unsafe fn from(d: f64) -> Self

Source

pub(crate) fn normalize(self) -> DiyFp<u64, isize>

Source

pub(crate) fn normalize_boundary(self) -> DiyFp<u64, isize>

Source

pub(crate) fn normalized_boundaries( self, ) -> (DiyFp<u64, isize>, DiyFp<u64, isize>)

Trait Implementations§

Source§

impl<F: Clone, E: Clone> Clone for DiyFp<F, E>

Source§

fn clone(&self) -> DiyFp<F, E>

Returns a copy of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl<F: Debug, E: Debug> Debug for DiyFp<F, E>

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Mul for DiyFp<u32, i32>

Source§

type Output = DiyFp<u32, i32>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: Self) -> Self

Performs the * operation. Read more
Source§

impl Mul for DiyFp<u64, isize>

Source§

type Output = DiyFp<u64, isize>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: Self) -> Self

Performs the * operation. Read more
Source§

impl<F, E> Sub for DiyFp<F, E>
where F: Sub<F, Output = F>,

Source§

type Output = DiyFp<F, E>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: Self) -> Self

Performs the - operation. Read more
Source§

impl<F: Copy, E: Copy> Copy for DiyFp<F, E>

Auto Trait Implementations§

§

impl<F, E> Freeze for DiyFp<F, E>
where F: Freeze, E: Freeze,

§

impl<F, E> RefUnwindSafe for DiyFp<F, E>

§

impl<F, E> Send for DiyFp<F, E>
where F: Send, E: Send,

§

impl<F, E> Sync for DiyFp<F, E>
where F: Sync, E: Sync,

§

impl<F, E> Unpin for DiyFp<F, E>
where F: Unpin, E: Unpin,

§

impl<F, E> UnwindSafe for DiyFp<F, E>
where F: UnwindSafe, E: UnwindSafe,

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dst: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dst. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.