Narrowing conversion from
(int-to-char operand) → result
Function:
(defun int-to-char (operand) (declare (xargs :guard (int-valuep operand))) (b* ((x (int-value->int operand))) (char-value (loghead 16 x))))
Theorem:
(defthm char-valuep-of-int-to-char (b* ((result (int-to-char operand))) (char-valuep result)) :rule-classes :rewrite)
Theorem:
(defthm int-to-char-of-int-value-fix-operand (equal (int-to-char (int-value-fix operand)) (int-to-char operand)))
Theorem:
(defthm int-to-char-int-value-equiv-congruence-on-operand (implies (int-value-equiv operand operand-equiv) (equal (int-to-char operand) (int-to-char operand-equiv))) :rule-classes :congruence)