[EMAIL PROTECTED] reports the following problem.

Version:       1.4 "Ported to Macintosh by Hans Aberg, compiled Jan 19 1998" 
OS:            Mac OS 8.1 on a PowerPC 8500/120 with 256Mb 
compiler:       
configuration:  
Expected behaviour:
In Complex,  sqrt (-1::Complex Float) should be 0:+1
Observed behaviour:
Instead, it's 0:+sqrt 0.5 .

The cause seems to be that the significand of negative floats
is bogus.
Transcript:
Prelude> :l Complex
Reading file ":lib:Complex.hs":

Hugs session for:
:lib:Prelude.hs
:lib:Complex.hs
Complex> sqrt (-1::Complex Float)
0.0 :+ 0.707107
Complex> significand (-2)
-0.0


Code:



Reply via email to