On 1/14/24 2:04 PM, Antero Mejr (via srfi-252 list) wrote:
> The intention was to match the generator names to the type predicates,
> so exact? became exact-generator and inexact? became inexact-generator.
OK, that's interesting.
Perhaps the generators should correspond to
exact-integer (and (exact? x) (integer? x))
exact-positive-integer (and (exact? x) (integer? x) (positive? x))
exact-rational (and (exact? x) (rational? x))
exact-real usually the same as exact-rational
exact-integer-complex (and (exact? x) (integer? (real-part x))
(integer? (imag-part x))
exact-complex (and (exact? x) (complex? x))
exact-number usually the same as exact-complex
exact-positive-integer can help generate exact-rational.
exact-integer-complex is useful for some number theory tasks.
inexact-integer (and (inexact? x) (integer? x))
inexact-rational (and (inexact? x) (rational? x)) ;; finite
inexact-real inexact-rational + infinities + nan
inexact-complex (and (inexact? x) (complex? x))
inexact-number usually the same as inexact-complex
then the union of inexact and exact:
integer
rational
real
complex
number
Perhaps.
Brad