summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorcolin <colin@cicadas.surf>2024-04-19 21:19:35 -0700
committercolin <colin@cicadas.surf>2024-04-19 21:19:35 -0700
commitb83e27e66b0032c67072a85bed3c87d948f087f8 (patch)
tree268bbbed720ef9bd60d69583450367fdc66a7e9c
parentbe1df3a9cfaf1f5a4e5bf248b24a2d55836701ab (diff)
hmm
-rw-r--r--obwyn.lisp26
1 files changed, 13 insertions, 13 deletions
diff --git a/obwyn.lisp b/obwyn.lisp
index 03b40f6..70a1772 100644
--- a/obwyn.lisp
+++ b/obwyn.lisp
@@ -124,45 +124,45 @@
(declare (ignore _))
(list := bindings form)))
- (<predicate-binding-clause>
- :match (:seq (:@ var (:item)) (:= :when=) (:@ form (:item)))
- :if variablep
- :then (list :when= var form)
- :note "Bind variable to form, exit early if form evaluated to nil.")
-
(<values-bind>
:match (:item)
:if values-binding-p
:note "Either a symbol or a list suitable for passing to MULTIPLE-VALUE-BIND")
-
+
(<destructuring-clause>
:match (:seq <destructuring-list> (:= :match=) (:item))
:then (destructuring-bind (bindings _ form) <destructuring-clause>
(declare (ignore _))
(list :match= bindings form)))
-
+
(<destructuring-list>
:match (:item)
:if destructuring-bind-list-p
- :note "An list that might be passed as the first argument to DESTRUCTURING-BIND.")
-
+ :note "An list that might be passed as the first argument to DESTRUCTURING-BIND.")
+
(<with-slots-clause>
:match (:seq <slot-value-list> (:= :slots=) (:item))
:then (destructuring-bind (bindings _ form) <with-slots-clause>
(declare (ignore _))
(list :slots= bindings form)))
-
+
(<slot-value-list>
:match (:item)
:if slot-value-list-p
:note "A list that is suitable for passing to with-slots.")
-
+
+ (<predicate-binding-clause>
+ :match (:seq (:@ var (:item)) (:= :when=) (:@ form (:item)))
+ :if (variablep var)
+ :then (list :when= var form)
+ :note "Bind variable to form, exit early if form evaluated to nil.")
+
(<predicate-clause>
:match (:seq (:= :when) (:item))
:then (list :when nil (second <predicate-clause>)))
(<simple-clause>
:match (:@ simple (:item))
- :if (not (member simple '(:when= :match= :when :=) :test #'literals-equal))
+ :if (not (member simple '(:when= :match= :when := :slots=) :test #'literals-equal))
:then (list :simple nil simple)))