* moved "not" to ikarus.predicates
(rationale: (not x) == (false? x))
This commit is contained in:
parent
828df98fa8
commit
4ada254c44
BIN
src/ikarus.boot
BIN
src/ikarus.boot
Binary file not shown.
|
@ -27,23 +27,6 @@
|
||||||
($char->fixnum x)))
|
($char->fixnum x)))
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
(primitive-set! 'vector-length
|
|
||||||
(lambda (x)
|
|
||||||
(unless (vector? x)
|
|
||||||
(error 'vector-length "~s is not a vector" x))
|
|
||||||
($vector-length x)))
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
(primitive-set! 'not
|
|
||||||
(lambda (x) (if x #f #t)))
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -3,14 +3,14 @@
|
||||||
|
|
||||||
(export fixnum? flonum? bignum? number? complex? real? rational?
|
(export fixnum? flonum? bignum? number? complex? real? rational?
|
||||||
integer? exact? eof-object? immediate? boolean? char?
|
integer? exact? eof-object? immediate? boolean? char?
|
||||||
vector? string? procedure? null? pair? symbol?)
|
vector? string? procedure? null? pair? symbol? not)
|
||||||
|
|
||||||
(import
|
(import
|
||||||
|
|
||||||
(except (ikarus) fixnum? flonum? bignum? number? complex? real?
|
(except (ikarus) fixnum? flonum? bignum? number? complex? real?
|
||||||
rational? integer? exact? eof-object? immediate?
|
rational? integer? exact? eof-object? immediate?
|
||||||
boolean? char? vector? string? procedure? null?
|
boolean? char? vector? string? procedure? null?
|
||||||
pair? symbol?)
|
pair? symbol? not)
|
||||||
|
|
||||||
(rename (only (ikarus) fixnum? flonum? bignum? eof-object?
|
(rename (only (ikarus) fixnum? flonum? bignum? eof-object?
|
||||||
immediate? boolean? char? vector? string? procedure?
|
immediate? boolean? char? vector? string? procedure?
|
||||||
|
@ -86,4 +86,5 @@
|
||||||
(define pair? (lambda (x) (sys:pair? x)))
|
(define pair? (lambda (x) (sys:pair? x)))
|
||||||
(define symbol? (lambda (x) (sys:symbol? x)))
|
(define symbol? (lambda (x) (sys:symbol? x)))
|
||||||
|
|
||||||
|
(define not (lambda (x) (if x #f #t)))
|
||||||
)
|
)
|
||||||
|
|
|
@ -1,11 +1,18 @@
|
||||||
|
|
||||||
(library (ikarus vectors)
|
(library (ikarus vectors)
|
||||||
(export make-vector)
|
(export make-vector vector-length)
|
||||||
(import
|
(import
|
||||||
(except (ikarus) make-vector)
|
(except (ikarus) make-vector vector-length)
|
||||||
(only (scheme)
|
(only (scheme)
|
||||||
$fx= $fx>= $fx+ $vector-set!
|
$fx= $fx>= $fx+ $vector-set!
|
||||||
$make-vector))
|
$make-vector $vector-length))
|
||||||
|
|
||||||
|
|
||||||
|
(define vector-length
|
||||||
|
(lambda (x)
|
||||||
|
(unless (vector? x)
|
||||||
|
(error 'vector-length "~s is not a vector" x))
|
||||||
|
($vector-length x)))
|
||||||
|
|
||||||
(module (make-vector)
|
(module (make-vector)
|
||||||
(define fill!
|
(define fill!
|
||||||
|
|
Loading…
Reference in New Issue