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