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