|Subject:||bug#29387: Guile-2.2.2 complex numbers edge case|
|Date:||Wed, 22 Nov 2017 16:53:00 +0100|
In Guile 0+i and (* 0+i 0+i) are inexact numbers, but -1 is exact. That's why equal? fails.
You can check that either of
(equal? -1.+0. (* 0+i 0+i))
(= -1 (* 0+i 0+i))
return true, as expected.
I don't know if the fact that Guile doesn't have exact complex numbers could be considered a bug. AFAIR none of the standards require them to be implemented. On the other hand I just checked and both Racket and Chez seem to have them, so...
|[Prev in Thread]||Current Thread||[Next in Thread]|