mirror of
https://github.com/justinethier/cyclone.git
synced 2025-05-19 05:39:17 +02:00
add more tests for rounding
r7rs requires (round x) to round to even when x is halfway between two integers, while C requires round(x) to round away from zero.
This commit is contained in:
parent
3b921e7389
commit
7d8f70fb07
1 changed files with 3 additions and 0 deletions
|
@ -91,6 +91,9 @@
|
|||
(test 4.0 (ceiling 3.5))
|
||||
(test 3.0 (truncate 3.5))
|
||||
(test 4.0 (round 3.5))
|
||||
(test 2.0 (round 2.5))
|
||||
(test -4.0 (round -3.5))
|
||||
(test -2.0 (round -2.5))
|
||||
(test 4.0 (round 7/2)) ;; Rationals not supported, so result is inexact
|
||||
(test 7 (round 7))
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue