Fixing function for fundef-result structures.
(fundef-result-fix acl2::x) → new-x
Function:
(defun fundef-result-fix$inline (acl2::x) (declare (xargs :guard (fundef-resultp acl2::x))) (let ((__function__ 'fundef-result-fix)) (declare (ignorable __function__)) (mbe :logic (case (fundef-result-kind acl2::x) (:ok (b* ((get (fundef-fix acl2::x))) get)) (:err (b* ((get (fty::reserr-fix acl2::x))) get))) :exec acl2::x)))
Theorem:
(defthm fundef-resultp-of-fundef-result-fix (b* ((new-x (fundef-result-fix$inline acl2::x))) (fundef-resultp new-x)) :rule-classes :rewrite)
Theorem:
(defthm fundef-result-fix-when-fundef-resultp (implies (fundef-resultp acl2::x) (equal (fundef-result-fix acl2::x) acl2::x)))
Function:
(defun fundef-result-equiv$inline (acl2::x acl2::y) (declare (xargs :guard (and (fundef-resultp acl2::x) (fundef-resultp acl2::y)))) (equal (fundef-result-fix acl2::x) (fundef-result-fix acl2::y)))
Theorem:
(defthm fundef-result-equiv-is-an-equivalence (and (booleanp (fundef-result-equiv x y)) (fundef-result-equiv x x) (implies (fundef-result-equiv x y) (fundef-result-equiv y x)) (implies (and (fundef-result-equiv x y) (fundef-result-equiv y z)) (fundef-result-equiv x z))) :rule-classes (:equivalence))
Theorem:
(defthm fundef-result-equiv-implies-equal-fundef-result-fix-1 (implies (fundef-result-equiv acl2::x x-equiv) (equal (fundef-result-fix acl2::x) (fundef-result-fix x-equiv))) :rule-classes (:congruence))
Theorem:
(defthm fundef-result-fix-under-fundef-result-equiv (fundef-result-equiv (fundef-result-fix acl2::x) acl2::x) :rule-classes (:rewrite :rewrite-quoted-constant))
Theorem:
(defthm equal-of-fundef-result-fix-1-forward-to-fundef-result-equiv (implies (equal (fundef-result-fix acl2::x) acl2::y) (fundef-result-equiv acl2::x acl2::y)) :rule-classes :forward-chaining)
Theorem:
(defthm equal-of-fundef-result-fix-2-forward-to-fundef-result-equiv (implies (equal acl2::x (fundef-result-fix acl2::y)) (fundef-result-equiv acl2::x acl2::y)) :rule-classes :forward-chaining)
Theorem:
(defthm fundef-result-equiv-of-fundef-result-fix-1-forward (implies (fundef-result-equiv (fundef-result-fix acl2::x) acl2::y) (fundef-result-equiv acl2::x acl2::y)) :rule-classes :forward-chaining)
Theorem:
(defthm fundef-result-equiv-of-fundef-result-fix-2-forward (implies (fundef-result-equiv acl2::x (fundef-result-fix acl2::y)) (fundef-result-equiv acl2::x acl2::y)) :rule-classes :forward-chaining)
Theorem:
(defthm fundef-result-kind$inline-of-fundef-result-fix-x (equal (fundef-result-kind$inline (fundef-result-fix acl2::x)) (fundef-result-kind$inline acl2::x)))
Theorem:
(defthm fundef-result-kind$inline-fundef-result-equiv-congruence-on-x (implies (fundef-result-equiv acl2::x x-equiv) (equal (fundef-result-kind$inline acl2::x) (fundef-result-kind$inline x-equiv))) :rule-classes :congruence)
Theorem:
(defthm consp-of-fundef-result-fix (consp (fundef-result-fix acl2::x)) :rule-classes :type-prescription)