Fixing function for var-sinfo structures.
(var-sinfo-fix x) → new-x
Function:
(defun var-sinfo-fix$inline (x) (declare (xargs :guard (var-sinfop x))) (let ((__function__ 'var-sinfo-fix)) (declare (ignorable __function__)) (mbe :logic (b* ((type (type-fix (cdr (std::da-nth 0 x)))) (defstatus (var-defstatus-fix (cdr (std::da-nth 1 x))))) (list (cons 'type type) (cons 'defstatus defstatus))) :exec x)))
Theorem:
(defthm var-sinfop-of-var-sinfo-fix (b* ((new-x (var-sinfo-fix$inline x))) (var-sinfop new-x)) :rule-classes :rewrite)
Theorem:
(defthm var-sinfo-fix-when-var-sinfop (implies (var-sinfop x) (equal (var-sinfo-fix x) x)))
Function:
(defun var-sinfo-equiv$inline (acl2::x acl2::y) (declare (xargs :guard (and (var-sinfop acl2::x) (var-sinfop acl2::y)))) (equal (var-sinfo-fix acl2::x) (var-sinfo-fix acl2::y)))
Theorem:
(defthm var-sinfo-equiv-is-an-equivalence (and (booleanp (var-sinfo-equiv x y)) (var-sinfo-equiv x x) (implies (var-sinfo-equiv x y) (var-sinfo-equiv y x)) (implies (and (var-sinfo-equiv x y) (var-sinfo-equiv y z)) (var-sinfo-equiv x z))) :rule-classes (:equivalence))
Theorem:
(defthm var-sinfo-equiv-implies-equal-var-sinfo-fix-1 (implies (var-sinfo-equiv acl2::x x-equiv) (equal (var-sinfo-fix acl2::x) (var-sinfo-fix x-equiv))) :rule-classes (:congruence))
Theorem:
(defthm var-sinfo-fix-under-var-sinfo-equiv (var-sinfo-equiv (var-sinfo-fix acl2::x) acl2::x) :rule-classes (:rewrite :rewrite-quoted-constant))
Theorem:
(defthm equal-of-var-sinfo-fix-1-forward-to-var-sinfo-equiv (implies (equal (var-sinfo-fix acl2::x) acl2::y) (var-sinfo-equiv acl2::x acl2::y)) :rule-classes :forward-chaining)
Theorem:
(defthm equal-of-var-sinfo-fix-2-forward-to-var-sinfo-equiv (implies (equal acl2::x (var-sinfo-fix acl2::y)) (var-sinfo-equiv acl2::x acl2::y)) :rule-classes :forward-chaining)
Theorem:
(defthm var-sinfo-equiv-of-var-sinfo-fix-1-forward (implies (var-sinfo-equiv (var-sinfo-fix acl2::x) acl2::y) (var-sinfo-equiv acl2::x acl2::y)) :rule-classes :forward-chaining)
Theorem:
(defthm var-sinfo-equiv-of-var-sinfo-fix-2-forward (implies (var-sinfo-equiv acl2::x (var-sinfo-fix acl2::y)) (var-sinfo-equiv acl2::x acl2::y)) :rule-classes :forward-chaining)