aboutsummaryrefslogtreecommitdiff
path: root/gn/cache/memoize.scm
diff options
context:
space:
mode:
authorPjotr Prins2023-08-22 10:37:41 +0200
committerPjotr Prins2023-08-22 10:37:41 +0200
commitb1c309e3ca19f7557a3917f26f933d864c926c33 (patch)
tree4d3ffd54bd865b8fbcd492c441c08684006f09d0 /gn/cache/memoize.scm
parentd06d732625fdc48677ea32b129da905ebd527c38 (diff)
downloadgn-guile-b1c309e3ca19f7557a3917f26f933d864c926c33.tar.gz
Remove pk statements
Diffstat (limited to 'gn/cache/memoize.scm')
-rw-r--r--gn/cache/memoize.scm8
1 files changed, 4 insertions, 4 deletions
diff --git a/gn/cache/memoize.scm b/gn/cache/memoize.scm
index 42b2163..b79e026 100644
--- a/gn/cache/memoize.scm
+++ b/gn/cache/memoize.scm
@@ -18,8 +18,8 @@
"Simple memoize just uses alists at this point and does not expire"
(let ((result-table '()))
(lambda (. args)
- (let ((cache-value (assoc args (pk result-table))))
- (if (pk cache-value)
+ (let ((cache-value (assoc args result-table)))
+ (if cache-value
(cdr cache-value)
(let ((result (apply f args)))
(set! result-table
@@ -29,8 +29,8 @@
"Simple memoize functions that returns values pair and uses alists at this point and does not expire"
(let ((result-table '()))
(lambda (. args)
- (let ((c (assoc args (pk result-table))))
- (if (pk c)
+ (let ((c (assoc args result-table)))
+ (if c
(values (car (cdr c)) (car (cdr (cdr c))))
(let-values (((r1 r2) (apply f args)))
(set! result-table