Details
-
Bug
-
Status: Resolved
-
Major
-
Resolution: Fixed
-
None
Description
BasicDecimal128 one(5); // 0.5 one.ReduceScaleBy(1, true); // expected 1, but result is -1
BasicDecimal128 BasicDecimal128::ReduceScaleBy(int32_t reduce_by, bool round) const { ... if (remainder.Abs() >= divisor_half) { if (result > 0) { // should be >= result += 1; } else { result -= 1; } }
Attachments
Issue Links
- links to