Fixing function for pexprs-gout structures.
(pexprs-gout-fix x) → new-x
Function:
(defun pexprs-gout-fix$inline (x) (declare (xargs :guard (pexprs-goutp x))) (let ((__function__ 'pexprs-gout-fix)) (declare (ignorable __function__)) (mbe :logic (b* ((exprs (expr-list-fix (cdr (std::da-nth 0 x)))) (types (type-list-fix (cdr (std::da-nth 1 x)))) (terms (pseudo-term-list-fix (cdr (std::da-nth 2 x)))) (events (acl2::pseudo-event-form-list-fix (cdr (std::da-nth 3 x)))) (thm-names (symbol-list-fix (cdr (std::da-nth 4 x)))) (thm-index (acl2::pos-fix (cdr (std::da-nth 5 x)))) (names-to-avoid (symbol-list-fix (cdr (std::da-nth 6 x))))) (list (cons 'exprs exprs) (cons 'types types) (cons 'terms terms) (cons 'events events) (cons 'thm-names thm-names) (cons 'thm-index thm-index) (cons 'names-to-avoid names-to-avoid))) :exec x)))
Theorem:
(defthm pexprs-goutp-of-pexprs-gout-fix (b* ((new-x (pexprs-gout-fix$inline x))) (pexprs-goutp new-x)) :rule-classes :rewrite)
Theorem:
(defthm pexprs-gout-fix-when-pexprs-goutp (implies (pexprs-goutp x) (equal (pexprs-gout-fix x) x)))
Function:
(defun pexprs-gout-equiv$inline (acl2::x acl2::y) (declare (xargs :guard (and (pexprs-goutp acl2::x) (pexprs-goutp acl2::y)))) (equal (pexprs-gout-fix acl2::x) (pexprs-gout-fix acl2::y)))
Theorem:
(defthm pexprs-gout-equiv-is-an-equivalence (and (booleanp (pexprs-gout-equiv x y)) (pexprs-gout-equiv x x) (implies (pexprs-gout-equiv x y) (pexprs-gout-equiv y x)) (implies (and (pexprs-gout-equiv x y) (pexprs-gout-equiv y z)) (pexprs-gout-equiv x z))) :rule-classes (:equivalence))
Theorem:
(defthm pexprs-gout-equiv-implies-equal-pexprs-gout-fix-1 (implies (pexprs-gout-equiv acl2::x x-equiv) (equal (pexprs-gout-fix acl2::x) (pexprs-gout-fix x-equiv))) :rule-classes (:congruence))
Theorem:
(defthm pexprs-gout-fix-under-pexprs-gout-equiv (pexprs-gout-equiv (pexprs-gout-fix acl2::x) acl2::x) :rule-classes (:rewrite :rewrite-quoted-constant))
Theorem:
(defthm equal-of-pexprs-gout-fix-1-forward-to-pexprs-gout-equiv (implies (equal (pexprs-gout-fix acl2::x) acl2::y) (pexprs-gout-equiv acl2::x acl2::y)) :rule-classes :forward-chaining)
Theorem:
(defthm equal-of-pexprs-gout-fix-2-forward-to-pexprs-gout-equiv (implies (equal acl2::x (pexprs-gout-fix acl2::y)) (pexprs-gout-equiv acl2::x acl2::y)) :rule-classes :forward-chaining)
Theorem:
(defthm pexprs-gout-equiv-of-pexprs-gout-fix-1-forward (implies (pexprs-gout-equiv (pexprs-gout-fix acl2::x) acl2::y) (pexprs-gout-equiv acl2::x acl2::y)) :rule-classes :forward-chaining)
Theorem:
(defthm pexprs-gout-equiv-of-pexprs-gout-fix-2-forward (implies (pexprs-gout-equiv acl2::x (pexprs-gout-fix acl2::y)) (pexprs-gout-equiv acl2::x acl2::y)) :rule-classes :forward-chaining)