Łukasz Jan Niemier 9 年之前
父节点
当前提交
72fa7ece48
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      integer/src/lib.rs

+ 1 - 1
integer/src/lib.rs

@@ -275,7 +275,7 @@ macro_rules! impl_integer_for_isize {
             #[inline]
             fn lcm(&self, other: &Self) -> Self {
                 // should not have to recalculate abs
-                ((*self * *other) / self.gcd(other)).abs()
+                (*self * (*other / self.gcd(other))).abs()
             }
 
             /// Deprecated, use `is_multiple_of` instead.