The carry in signed carrying_mul on integers should be unsigned #90493
Labels
C-bug
Category: This is a bug.
T-libs
Relevant to the library team, which will review and decide on the PR/issue.
T-libs-api
Relevant to the library API team, which will review and decide on the PR/issue.
I tried this code:
I expected to see this happen: I expected the "prod" to be 5.
Instead, this happened: The product is 4 due to the carry in the first calculation being negative (overflowing) causing it to accumulate incorrectly.
Meta
rustc --version --verbose
:The text was updated successfully, but these errors were encountered: