pub struct Posit512(/* private fields */);Implementations§
Source§impl Posit512
impl Posit512
pub const ZERO: Posit512
pub const NAR: Posit512
pub const fn to_u512(&self) -> u512
👎Deprecated since 1.5.3:
use into
pub const fn into_u512(self) -> u512
pub fn is_nar(&self) -> bool
pub fn is_zero(&self) -> bool
pub fn is_negative(&self) -> bool
pub fn is_positive(&self) -> bool
pub fn abs(self) -> Self
pub fn from_bits(bits: u512) -> Self
pub fn decode(&self) -> Result<(bool, i16, u512, u512), PositDecodeError>
pub fn encode(sign: bool, regime: i16, exp: u512, mantissa: u512) -> Self
Trait Implementations§
Source§impl AddAssign for Posit512
impl AddAssign for Posit512
Source§fn add_assign(&mut self, other: Self)
fn add_assign(&mut self, other: Self)
Performs the
+= operation. Read moreSource§impl DivAssign for Posit512
impl DivAssign for Posit512
Source§fn div_assign(&mut self, other: Self)
fn div_assign(&mut self, other: Self)
Performs the
/= operation. Read moreSource§impl MulAssign for Posit512
impl MulAssign for Posit512
Source§fn mul_assign(&mut self, other: Self)
fn mul_assign(&mut self, other: Self)
Performs the
*= operation. Read moreSource§impl Ord for Posit512
impl Ord for Posit512
1.21.0 (const: unstable) · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl PartialOrd for Posit512
impl PartialOrd for Posit512
Source§impl SubAssign for Posit512
impl SubAssign for Posit512
Source§fn sub_assign(&mut self, other: Self)
fn sub_assign(&mut self, other: Self)
Performs the
-= operation. Read moreimpl Copy for Posit512
impl Eq for Posit512
impl StructuralPartialEq for Posit512
Auto Trait Implementations§
impl Freeze for Posit512
impl RefUnwindSafe for Posit512
impl Send for Posit512
impl Sync for Posit512
impl Unpin for Posit512
impl UnsafeUnpin for Posit512
impl UnwindSafe for Posit512
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more