Commit 5b0d86a
committed
Apply filter to float_with_bounds
Computing floats when given bounds such as min -9.9e15 and max -1 will result in
the computation `-1.0 - -9.9e15` yielding 9900000000000000.0 instead of
9899999999999999.0, which makes the generator return 0. This is a classic
floating point loss of significance error.
Fixes #2031 parent 1f220e8 commit 5b0d86a
2 files changed
Lines changed: 11 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1756 | 1756 | | |
1757 | 1757 | | |
1758 | 1758 | | |
| 1759 | + | |
| 1760 | + | |
| 1761 | + | |
1759 | 1762 | | |
1760 | 1763 | | |
1761 | 1764 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
330 | 330 | | |
331 | 331 | | |
332 | 332 | | |
| 333 | + | |
| 334 | + | |
| 335 | + | |
| 336 | + | |
| 337 | + | |
| 338 | + | |
| 339 | + | |
| 340 | + | |
333 | 341 | | |
334 | 342 | | |
335 | 343 | | |
| |||
0 commit comments