[r6rs-discuss] R5.95 questions

R. Kent Dybvig dyb at cs.indiana.edu
Wed Jun 27 00:05:07 EDT 2007


> > > The wisdom of this move is also open to question.
> > > Inasmuch as the second argument is inexact, its
> > > integer object-ness is likely to be accidental.
> > 
> > This is precisely why I have always believed that integer? should return
> > false for all inexact values.
>
> So this is your revenge?

Not at all.  We're just removing a restriction on flexpt that makes sense
only if flonums can't be integers.  By removing the restriction, we gain
some useful generality, for now we can write, e.g., (flexpt x 3.0) to cube
an arbitrary flonum.  It shouldn't be a hardship to implement, since the
POSIX power functions, which I suspect most Scheme implementations already
use, directly or indirectly, support negative bases with integer powers. 
The POSIX power functions also serve as a precedent, and no one has
provided a rationale for why we shouldn't follow it.

Kent



More information about the r6rs-discuss mailing list