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