added char-whitespace?

This commit is contained in:
Abdulaziz Ghuloum 2007-01-20 14:40:41 -05:00
parent 679af26761
commit a2692706d4
4 changed files with 8 additions and 5 deletions

Binary file not shown.

View File

@ -696,6 +696,13 @@ reference-implementation:
(err c2)))))
(err c1))])))
(primitive-set! 'char-whitespace?
(lambda (c)
(cond
[(memq c '(#\space #\tab #\newline #\return)) #t]
[(char? c) #f]
[else
(error 'char-whitespace? "~s is not a character" c)])))
(primitive-set! 'cons (lambda (x y) (cons x y)))

View File

@ -3,10 +3,6 @@
;;; 9.0: graph marks/refs
;;;
(let ()
(define char-whitespace?
(lambda (c)
(or ($char= #\space c)
(memq ($char->fixnum c) '(9 10 11 12 13)))))
(define delimiter?
(lambda (c)
(or (char-whitespace? c)

View File

@ -88,7 +88,7 @@
time-it
posix-fork fork waitpid env environ
pretty-print
even? odd? member
even? odd? member char-whitespace?
))
(define system-primitives