I believe we have `(/)` wrong for `divPositive` and `divNegative`
- Dominant language
- Haskell
- Stars
- 27
- Forks
- 14
- PR merge metrics
- No merged PRs in 30d
Description
This came up when writing `Numeric.Rounded.Interval` in `rounded`.
The right definition probably looks like:
``` haskell
x / y@(I a b)
| 0 `notElem` y = divNonZero x y
| iz && sz = ...
| iz = divPositive x b
| sz = divNegative x a
| otherwise = divZero x
```
Contributor guide
No contributing guide indexed for this repository
Research direction
Read the implementation of divPositive, divNegative, divNonZero, and divZero, then inspect how Numeric.Rounded.Interval in rounded uses interval division. Compare the zero and sign cases with the proposed definition and run the existing test suite; done means the division behavior is corrected and verified without regressing other cases.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- haskell
- Domain
- backend
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100