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