Update the |FGL|::|DONT-EXPAND-DEF| field of a fgl-function-mode bit structure.
(!fgl-function-mode->dont-expand-def dont-expand-def x) → new-x
Function:
(defun !fgl-function-mode->dont-expand-def (dont-expand-def x) (declare (xargs :guard (and (booleanp dont-expand-def) (fgl-function-mode-p x)))) (mbe :logic (b* ((dont-expand-def (bool->bit dont-expand-def)) (x (fgl-function-mode-fix x))) (acl2::part-install dont-expand-def x :width 1 :low 2)) :exec (the (unsigned-byte 6) (logior (the (unsigned-byte 6) (logand (the (unsigned-byte 6) x) (the (signed-byte 4) -5))) (the (unsigned-byte 3) (ash (the (unsigned-byte 1) (bool->bit dont-expand-def)) 2))))))
Theorem:
(defthm fgl-function-mode-p-of-!fgl-function-mode->dont-expand-def (b* ((new-x (!fgl-function-mode->dont-expand-def dont-expand-def x))) (fgl-function-mode-p new-x)) :rule-classes :rewrite)
Theorem:
(defthm !fgl-function-mode->dont-expand-def-of-bool-fix-dont-expand-def (equal (!fgl-function-mode->dont-expand-def (bool-fix dont-expand-def) x) (!fgl-function-mode->dont-expand-def dont-expand-def x)))
Theorem:
(defthm !fgl-function-mode->dont-expand-def-iff-congruence-on-dont-expand-def (implies (iff dont-expand-def dont-expand-def-equiv) (equal (!fgl-function-mode->dont-expand-def dont-expand-def x) (!fgl-function-mode->dont-expand-def dont-expand-def-equiv x))) :rule-classes :congruence)
Theorem:
(defthm !fgl-function-mode->dont-expand-def-of-fgl-function-mode-fix-x (equal (!fgl-function-mode->dont-expand-def dont-expand-def (fgl-function-mode-fix x)) (!fgl-function-mode->dont-expand-def dont-expand-def x)))
Theorem:
(defthm !fgl-function-mode->dont-expand-def-fgl-function-mode-equiv-congruence-on-x (implies (fgl-function-mode-equiv x x-equiv) (equal (!fgl-function-mode->dont-expand-def dont-expand-def x) (!fgl-function-mode->dont-expand-def dont-expand-def x-equiv))) :rule-classes :congruence)
Theorem:
(defthm !fgl-function-mode->dont-expand-def-is-fgl-function-mode (equal (!fgl-function-mode->dont-expand-def dont-expand-def x) (change-fgl-function-mode x :dont-expand-def dont-expand-def)))
Theorem:
(defthm fgl-function-mode->dont-expand-def-of-!fgl-function-mode->dont-expand-def (b* ((?new-x (!fgl-function-mode->dont-expand-def dont-expand-def x))) (equal (fgl-function-mode->dont-expand-def new-x) (bool-fix dont-expand-def))))
Theorem:
(defthm !fgl-function-mode->dont-expand-def-equiv-under-mask (b* ((?new-x (!fgl-function-mode->dont-expand-def dont-expand-def x))) (fgl-function-mode-equiv-under-mask new-x x -5)))