Fixer for dec-digit-char.
(dec-digit-char-fix x) → fixed-x
Function:
(defun dec-digit-char-fix (x) (declare (xargs :guard (dec-digit-char-p x))) (mbe :logic (if (dec-digit-char-p x) x #\0) :exec x))
Theorem:
(defthm dec-digit-char-p-of-dec-digit-char-fix (b* ((fixed-x (dec-digit-char-fix x))) (dec-digit-char-p fixed-x)) :rule-classes :rewrite)
Theorem:
(defthm dec-digit-char-fix-when-dec-digit-char-p (implies (dec-digit-char-p x) (equal (dec-digit-char-fix x) x)))