diff --git a/src/ikarus.boot b/src/ikarus.boot index 0dab6ce..e7f3c06 100644 Binary files a/src/ikarus.boot and b/src/ikarus.boot differ diff --git a/src/ikarus.numerics.ss b/src/ikarus.numerics.ss index fc6ebd5..ebe95a3 100644 --- a/src/ikarus.numerics.ss +++ b/src/ikarus.numerics.ss @@ -1002,14 +1002,6 @@ [else (error 'inexact "~s is not a number" x)]))) - (define inexact? - (lambda (x) - (cond - [(fixnum? x) #f] - [(bignum? x) #f] - [(flonum? x) #t] - [else - (error 'inexact? "~s is not a number" x)]))) (define positive-bignum? (lambda (x) diff --git a/src/ikarus.predicates.ss b/src/ikarus.predicates.ss index 963fc09..cc9bd45 100644 --- a/src/ikarus.predicates.ss +++ b/src/ikarus.predicates.ss @@ -2,14 +2,14 @@ (library (ikarus predicates) (export fixnum? flonum? bignum? ratnum? number? complex? real? rational? - integer? exact? eof-object? bwp-object? immediate? + integer? exact? inexact? eof-object? bwp-object? immediate? boolean? char? vector? bytevector? string? procedure? null? pair? symbol? code? not weak-pair? eq? eqv? equal? boolean=? symbol=?) (import (except (ikarus) fixnum? flonum? bignum? ratnum? number? complex? real? - rational? integer? exact? eof-object? bwp-object? + rational? integer? exact? inexact? eof-object? bwp-object? immediate? boolean? char? vector? bytevector? string? procedure? null? pair? weak-pair? symbol? code? not eq? eqv? equal? port? input-port? output-port? boolean=? symbol=?) @@ -99,6 +99,17 @@ [else (error 'exact? "~s is not a number" x)]))) + + (define inexact? + (lambda (x) + (cond + [(sys:flonum? x) #t] + [(sys:fixnum? x) #f] + [(sys:bignum? x) #f] + [(sys:ratnum? x) #f] + [else + (error 'inexact? "~s is not a number" x)]))) + (define eof-object? (lambda (x) (sys:eof-object? x))) (define bwp-object? (lambda (x) (sys:bwp-object? x))) (define immediate? (lambda (x) (sys:immediate? x))) diff --git a/src/makefile.ss b/src/makefile.ss index 27cc54e..d5c8d3b 100755 --- a/src/makefile.ss +++ b/src/makefile.ss @@ -479,6 +479,7 @@ [ratnum? i] [integer? i r] [exact? i r] + [inexact? i r] [rational? i r] [flonum? i] [positive? i r] diff --git a/src/todo-r6rs.ss b/src/todo-r6rs.ss index b1b5235..8e14bc9 100755 --- a/src/todo-r6rs.ss +++ b/src/todo-r6rs.ss @@ -155,7 +155,7 @@ [gcd C ba se] [imag-part D ba se] [inexact C ba] - [inexact? S ba se] + [inexact? C ba se] [infinite? S ba] [integer->char C ba se] [integer-valued? S ba]