Basic constructor macro for expression-unless structures.
(make-expression-unless [:test <test>] [:then <then>] [:else <else>])
This is the usual way to construct expression-unless structures. It simply conses together a structure with the specified fields.
This macro generates a new expression-unless structure from scratch. See also change-expression-unless, which can "change" an existing structure, instead.
This is an ordinary
Macro:
(defmacro make-expression-unless (&rest args) (std::make-aggregate 'expression-unless args '((:test) (:then) (:else)) 'make-expression-unless nil))
Function:
(defun expression-unless (test then else) (declare (xargs :guard (and (expressionp test) (expressionp then) (expressionp else)))) (declare (xargs :guard t)) (let ((__function__ 'expression-unless)) (declare (ignorable __function__)) (b* ((test (mbe :logic (expression-fix test) :exec test)) (then (mbe :logic (expression-fix then) :exec then)) (else (mbe :logic (expression-fix else) :exec else))) (cons :unless (list test then else)))))