Basic constructor macro for types+vartab structures.
(make-types+vartab [:return-types <return-types>] [:variables <variables>])
This is the usual way to construct types+vartab structures. It simply conses together a structure with the specified fields.
This macro generates a new types+vartab structure from scratch. See also change-types+vartab, which can "change" an existing structure, instead.
This is an ordinary
Macro:
(defmacro make-types+vartab (&rest args) (std::make-aggregate 'types+vartab args '((:return-types) (:variables)) 'make-types+vartab nil))
Function:
(defun types+vartab (return-types variables) (declare (xargs :guard (and (type-setp return-types) (var-tablep variables)))) (declare (xargs :guard (not (emptyp return-types)))) (let ((__function__ 'types+vartab)) (declare (ignorable __function__)) (b* ((return-types (mbe :logic (type-set-fix return-types) :exec return-types)) (variables (mbe :logic (var-table-fix variables) :exec variables))) (let ((return-types (mbe :logic (if (emptyp return-types) (insert (type-void) nil) return-types) :exec return-types))) (list (cons 'return-types return-types) (cons 'variables variables))))))