Fixer for ubyte256.
Function:
(defun ubyte256-fix (x) (declare (xargs :guard (ubyte256p x))) (mbe :logic (if (ubyte256p x) x 0) :exec x))
Theorem:
(defthm ubyte256p-of-ubyte256-fix (b* ((fixed-x (ubyte256-fix x))) (ubyte256p fixed-x)) :rule-classes :rewrite)
Theorem:
(defthm ubyte256-fix-when-ubyte256p (implies (ubyte256p x) (equal (ubyte256-fix x) x)))