Guile Mailing List Archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: guile & r5rs



Jim Blandy <jimb@red-bean.com> writes:

 > > However, all numerical fcns are supposed to produce either exact or
 > > inexact numbers or signal an exception.  Since +#.# is neither exact
 > > nor inexact, I wouldn't call this conforming.
 > 
 > It's inexact, as it should be.
 > 
 > guile> (inexact? (sqrt (expt 10 400)))
 > #t

My mistake.  I thought it returned #f when I checkked.  But, then what
about:

guile> (define b (/ 1 0))
guile> b
+#.#
guile> (inexact? b)
#t
guile> (inexact->exact b)
ERROR: In procedure inexact->exact in expression (inexact->exact b):
ERROR: Wrong type argument in position 1: +#.#
ABORT: (wrong-type-arg)


-- 
Harvey J. Stein
BFM Financial Research
hjstein@bfr.co.il

Guile Home | Main Index | Thread Index