File tree Expand file tree Collapse file tree 3 files changed +4
-4
lines changed Expand file tree Collapse file tree 3 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -21,8 +21,8 @@ impl<const LIMBS: usize> Int<LIMBS> {
2121
2222 // Step 2. determine whether overflow happened.
2323 // Note:
24- // - overflow can only happen when the inputs have the same sign, and then
25- // - overflow occurs if and only if the result has the opposite sign of both inputs.
24+ // - overflow can only happen when the inputs have the same sign, and
25+ // - overflow occurs if and only if the result has the opposite sign from both inputs.
2626 //
2727 // We can thus express the overflow flag as: (self.msb == rhs.msb) & (self.msb != res.msb)
2828 let self_msb = self . is_negative ( ) ;
Original file line number Diff line number Diff line change @@ -3,7 +3,7 @@ use num_traits::ConstZero;
33
44impl < const LIMBS : usize > Int < LIMBS > {
55 /// Returns the word of most significant [`Limb`].
6- /// For the generative case where the number of limbs is zero,
6+ /// For the degenerate case where the number of limbs is zero,
77 /// zeroed word is returned (which is semantically correct).
88 /// This method leaks the limb length of the value, which is also OK.
99 const fn most_significant_word ( & self ) -> Word {
Original file line number Diff line number Diff line change @@ -16,7 +16,7 @@ impl<const LIMBS: usize> Int<LIMBS> {
1616
1717 // Step 2. check whether underflow happened.
1818 // Note:
19- // - underflow can only happen when the inputs have opposing signs, and then
19+ // - underflow can only happen when the inputs have opposing signs, and
2020 // - underflow occurs if and only if the result and the lhs have opposing signs.
2121 //
2222 // We can thus express the overflow flag as: (self.msb != rhs.msb) & (self.msb != res.msb)
You can’t perform that action at this time.
0 commit comments