Remove implicit dependencies

This commit is contained in:
Ed Langley
2019-04-29 23:13:08 -07:00
parent cbd367763e
commit 1f0a4f7b06

View File

@ -182,9 +182,10 @@ contain the new value at the location focused by the lens."
(lambda (cb) (lambda (cb)
(lambda (old-hash) (lambda (old-hash)
(fmap (lambda (new) (fmap (lambda (new)
(fw.lu:prog1-bind (new-hash (alexandria:copy-hash-table old-hash)) (let ((new-hash (alexandria:copy-hash-table old-hash)))
(prog1 new-hash
(setf (gethash key new-hash) (setf (gethash key new-hash)
new))) new))))
(funcall cb (gethash key old-hash)))))) (funcall cb (gethash key old-hash))))))
;; imagine a lens here that uses the MOP to immutably update a class... ;; imagine a lens here that uses the MOP to immutably update a class...
@ -498,6 +499,7 @@ contain the new value at the location focused by the lens."
it it
(alexandria:iota it-length)))))))) (alexandria:iota it-length))))))))
#+nil
(defmacro <> (arity &rest funs) (defmacro <> (arity &rest funs)
(let ((arg-syms (loop repeat arity collect (gensym)))) (let ((arg-syms (loop repeat arity collect (gensym))))
`(lambda (,@arg-syms) `(lambda (,@arg-syms)
@ -510,4 +512,4 @@ contain the new value at the location focused by the lens."
arg-syms)))) arg-syms))))
(defmacro <>1 (&rest funs) (defmacro <>1 (&rest funs)
`(<> 1 ,@funs)) `(alexandria:compose ,@funs))