use hash-ref!
svn: r14438
This commit is contained in:
parent
c4e2e9af6d
commit
df56a8e3c1
|
@ -35,3 +35,8 @@
|
|||
(cache-table-lookup! ct 'foo (lambda () #t))
|
||||
(cache-table-clear! ct)
|
||||
(cache-table-lookup! ct 'foo (lambda () #f)))))))
|
||||
|
||||
#|
|
||||
(require (planet schematics/schemeunit:3/text-ui))
|
||||
(run-tests cache-table-tests)
|
||||
|#
|
|
@ -25,12 +25,7 @@
|
|||
(call-with-semaphore
|
||||
sema
|
||||
(lambda ()
|
||||
(hash-ref
|
||||
ht entry-id
|
||||
(lambda ()
|
||||
(define entry (entry-thunk))
|
||||
(hash-set! ht entry-id entry)
|
||||
entry)))))))
|
||||
(hash-ref! ht entry-id entry-thunk))))))
|
||||
|
||||
(provide/contract
|
||||
[rename new-cache-table make-cache-table
|
||||
|
|
Loading…
Reference in New Issue
Block a user