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