Optimize the implementation of minusInteger in the integer-gmp package
As mentioned in https://www.fpcomplete.com/blog/2016/05/weigh-package, the current implementation of minusInteger is
minusInteger x y = inline plusInteger x (inline negateInteger y)
which always allocates an additional integer. This could be improved by not always calling negateInteger and instead having an implementation more like plusInteger's.
Trac metadata
| Trac field | Value |
|---|---|
| Version | 8.0.1 |
| Type | Task |
| TypeOfFailure | OtherFailure |
| Priority | normal |
| Resolution | Unresolved |
| Component | libraries (other) |
| Test case | |
| Differential revisions | |
| BlockedBy | |
| Related | |
| Blocking | |
| CC | |
| Operating system | |
| Architecture |