pub enum Rounding {
HalfEven,
TowardZero,
}Expand description
Rounding applied when a result has more than SCALE fractional digits,
or when Decimal::round_to_scale drops digits.
Variants§
HalfEven
Round to nearest; an exact tie goes to the even last digit.
TowardZero
Discard the excess digits (truncate toward zero).
Trait Implementations§
impl Copy for Rounding
impl Eq for Rounding
impl StructuralPartialEq for Rounding
Auto Trait Implementations§
impl Freeze for Rounding
impl RefUnwindSafe for Rounding
impl Send for Rounding
impl Sync for Rounding
impl Unpin for Rounding
impl UnsafeUnpin for Rounding
impl UnwindSafe for Rounding
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