unlock parameter tests
This commit is contained in:
parent
c44803d238
commit
7da5786ef3
|
@ -364,18 +364,18 @@
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
;; (define radix
|
(define radix
|
||||||
;; (make-parameter
|
(make-parameter
|
||||||
;; 10
|
10
|
||||||
;; (lambda (x)
|
(lambda (x)
|
||||||
;; (if (and (integer? x) (<= 2 x 16))
|
(if (and (integer? x) (<= 2 x 16))
|
||||||
;; x
|
x
|
||||||
;; (error "invalid radix")))))
|
(error "invalid radix")))))
|
||||||
;; (define (f n) (number->string n (radix)))
|
(define (f n) (number->string n (radix)))
|
||||||
;; (test "12" (f 12))
|
(test "12" (f 12))
|
||||||
;; (test "1100" (parameterize ((radix 2))
|
(test "1100" (parameterize ((radix 2))
|
||||||
;; (f 12)))
|
(f 12)))
|
||||||
;; (test "12" (f 12))
|
(test "12" (f 12))
|
||||||
(test '(list 3 4) `(list ,(+ 1 2) 4))
|
(test '(list 3 4) `(list ,(+ 1 2) 4))
|
||||||
(let ((name 'a)) (test '(list a (quote a)) `(list ,name ',name)))
|
(let ((name 'a)) (test '(list a (quote a)) `(list ,name ',name)))
|
||||||
(test '(a 3 4 5 6 b) `(a ,(+ 1 2) ,@(map abs '(4 -5 6)) b))
|
(test '(a 3 4 5 6 b) `(a ,(+ 1 2) ,@(map abs '(4 -5 6)) b))
|
||||||
|
|
Loading…
Reference in New Issue