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