use is_one rather than comparison
This commit is contained in:
parent
6b257fbfe9
commit
7270890e45
@ -55,7 +55,7 @@ impl Number {
|
||||
}
|
||||
|
||||
pub fn is_decimal(&self) -> bool {
|
||||
self.val.denom() != &BigInt::from(1)
|
||||
!self.val.denom().is_one()
|
||||
}
|
||||
|
||||
pub fn clamp<A: Into<Number> + Zero, B: Into<Number>>(self, min: A, max: B) -> Self {
|
||||
|
Loading…
x
Reference in New Issue
Block a user