parent
bfce3ba665
commit
a68c8eadc6
|
@ -394,6 +394,16 @@
|
|||
(test #t eq? (hasheq) (hash-remove (hasheq 3 4) 3))
|
||||
(test #t eq? (hasheqv) (hash-remove (hasheqv 3 4) 3))
|
||||
|
||||
(err/rt-test (hash 1))
|
||||
(err/rt-test (hasheqv 1))
|
||||
(err/rt-test (hasheq 1))
|
||||
(err/rt-test (make-hash 1))
|
||||
(err/rt-test (make-hasheqv 1))
|
||||
(err/rt-test (make-hasheq 1))
|
||||
(err/rt-test (make-weak-hash 1))
|
||||
(err/rt-test (make-weak-hasheqv 1))
|
||||
(err/rt-test (make-weak-hasheq 1))
|
||||
|
||||
(test #t symbol? 'foo)
|
||||
(test #t symbol? (car '(a b)))
|
||||
(test #f symbol? "bar")
|
||||
|
|
|
@ -73,6 +73,11 @@
|
|||
(let loop ([kvs kvs] [h empty-hash])
|
||||
(cond
|
||||
[(null? kvs) h]
|
||||
[(null? (cdr kvs))
|
||||
(raise-arguments-error
|
||||
'vararg-ctor
|
||||
"key does not have a value (i.e., an odd number of arguments were provided)"
|
||||
"key" (car kvs))]
|
||||
[else (loop (cddr kvs) (intmap-set h (car kvs) (cadr kvs)))]))]))
|
||||
|
||||
(define list-ctor
|
||||
|
|
Loading…
Reference in New Issue
Block a user