feat: add • compose operator

This commit is contained in:
Ed Langley
2020-09-30 15:48:03 -07:00
parent 32b8a0bb7f
commit 800a03e0c6
2 changed files with 60 additions and 4 deletions

View File

@ -93,10 +93,10 @@ operator):
(== (view lens (set lens value rec))
value)
(== (set lens (view lens rec) rec)
rec)
(== (set lens value2 (set lens value1 rec))
(set lens value2 rec))
@ -234,11 +234,12 @@ contain the new value at the location focused by the lens."
#:compress-runs #:combine-matching-lists #:sorted #:applicable-when
#:of-length #:of-min-length #:of-max-length #:transform-head
#:maximizing #:zipping #:applying #:splice-elt #:transform-elt #:denest
#:op #:defalias #:<> #:<>1))
#:op #:defalias #:<> #:<>1
#:))
(in-package :data-lens)
(declaim
(declaim
(inline data-lens:over data-lens:transform-tail
data-lens:applicable-when data-lens:of-min-length
data-lens:on data-lens:over data-lens:slice
@ -524,3 +525,5 @@ contain the new value at the location focused by the lens."
(defmacro <>1 (&rest funs)
`(alexandria:compose ,@funs))
(defmacro (&rest funs)
`(alexandria:compose ,@funs))