#| -*-Scheme-*-
-$Id: char.scm,v 14.25 2004/02/25 20:59:02 cph Exp $
+$Id: char.scm,v 14.26 2005/06/03 13:32:16 cph Exp $
Copyright 1986,1987,1988,1991,1995,1997 Massachusetts Institute of Technology
-Copyright 1998,2001,2003,2004 Massachusetts Institute of Technology
+Copyright 1998,2001,2003,2004,2005 Massachusetts Institute of Technology
This file is part of MIT/GNU Scheme.
(define-integrable (%char-bits char)
(fix:lsh (char->integer char) -21))
-(define-integrable (guarantee-char char procedure)
- (if (not (char? char))
- (error:wrong-type-argument char "character" procedure)))
+(define-guarantee char "character")
(define (make-char code bits)
(guarantee-limited-index-fixnum code char-code-limit 'MAKE-CHAR)
(fix:<= 2 object)
(fix:<= object 36)))
-(define (guarantee-radix object caller)
- (if (not (radix? object))
- (error:wrong-type-argument object "radix" caller)))
+(define-guarantee radix "radix")
(define (digit->char digit #!optional radix)
(guarantee-limited-index-fixnum digit
(guarantee-radix radix 'DIGIT->CHAR)
radix))
'DIGIT->CHAR)
- (string-ref "0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ" digit))
+ (string-ref "0123456789abcdefghijklmnopqrstuvwxyz" digit))
(define (char->digit char #!optional radix)
(guarantee-char char 'CHAR->DIGIT)
#| -*-Scheme-*-
-$Id: runtime.pkg,v 14.553 2005/06/01 05:00:07 cph Exp $
+$Id: runtime.pkg,v 14.554 2005/06/03 13:32:27 cph Exp $
Copyright 1988,1989,1990,1991,1992,1993 Massachusetts Institute of Technology
Copyright 1994,1995,1996,1997,1998,1999 Massachusetts Institute of Technology
chars->ascii
code->char
digit->char
+ error:not-char
+ error:not-radix
guarantee-char
guarantee-radix
integer->char
>
>=
atan
+ error:not-complex
+ error:not-exact
+ error:not-exact-integer
+ error:not-exact-nonnegative-integer
+ error:not-exact-positive-integer
+ error:not-exact-rational
+ error:not-inexact
+ error:not-integer
+ error:not-number
+ error:not-rational
+ error:not-real
exact-nonnegative-integer?
exact-positive-integer?
flo:significand-digits-base-10