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