Feedback requested on Shr for negative BigInt

I'm not sure it's a bad decision to use a sign flag; GMP has a kind of sign flag as well. It does cost one branch in many operation, and extra complexity to implement features like this or bitwise manipulation in a similar way to two's-complement, but it has other benefits. For example to negate a large number with two's-complement digits, you'd have to basically complement all digits (similarly if you want to subtract a large-magnitude number from a small-magnitude number).

1 Like

I see a lot of worries here about breaking people, though most people have been debating about whether to bump SemVer or not -- would cargo-crusader help to detect broken reverse dependencies? :slight_smile:

The crusader might find breakages, but only for published crates, and only if they have a test that actually exercises this particular case. We can't really prove a negative, that no one will be broken.

I think I will just bump it. Now that we're past the holidays, I'll try to find some time to do this and a few other breaking changes I've been waiting on.