(svex-envlist-fix x) is a usual fty list fixing function.
(svex-envlist-fix x) → fty::newx
In the logic, we apply svex-env-fix to each member of the x. In the execution, none of that is actually necessary and this is just an inlined identity function.
Function:
(defun svex-envlist-fix$inline (x) (declare (xargs :guard (svex-envlist-p x))) (let ((__function__ 'svex-envlist-fix)) (declare (ignorable __function__)) (mbe :logic (if (atom x) nil (cons (svex-env-fix (car x)) (svex-envlist-fix (cdr x)))) :exec x)))
Theorem:
(defthm svex-envlist-p-of-svex-envlist-fix (b* ((fty::newx (svex-envlist-fix$inline x))) (svex-envlist-p fty::newx)) :rule-classes :rewrite)
Theorem:
(defthm svex-envlist-fix-when-svex-envlist-p (implies (svex-envlist-p x) (equal (svex-envlist-fix x) x)))
Function:
(defun svex-envlist-equiv$inline (x y) (declare (xargs :guard (and (svex-envlist-p x) (svex-envlist-p y)))) (equal (svex-envlist-fix x) (svex-envlist-fix y)))
Theorem:
(defthm svex-envlist-equiv-is-an-equivalence (and (booleanp (svex-envlist-equiv x y)) (svex-envlist-equiv x x) (implies (svex-envlist-equiv x y) (svex-envlist-equiv y x)) (implies (and (svex-envlist-equiv x y) (svex-envlist-equiv y z)) (svex-envlist-equiv x z))) :rule-classes (:equivalence))
Theorem:
(defthm svex-envlist-equiv-implies-equal-svex-envlist-fix-1 (implies (svex-envlist-equiv x x-equiv) (equal (svex-envlist-fix x) (svex-envlist-fix x-equiv))) :rule-classes (:congruence))
Theorem:
(defthm svex-envlist-fix-under-svex-envlist-equiv (svex-envlist-equiv (svex-envlist-fix x) x) :rule-classes (:rewrite :rewrite-quoted-constant))
Theorem:
(defthm equal-of-svex-envlist-fix-1-forward-to-svex-envlist-equiv (implies (equal (svex-envlist-fix x) y) (svex-envlist-equiv x y)) :rule-classes :forward-chaining)
Theorem:
(defthm equal-of-svex-envlist-fix-2-forward-to-svex-envlist-equiv (implies (equal x (svex-envlist-fix y)) (svex-envlist-equiv x y)) :rule-classes :forward-chaining)
Theorem:
(defthm svex-envlist-equiv-of-svex-envlist-fix-1-forward (implies (svex-envlist-equiv (svex-envlist-fix x) y) (svex-envlist-equiv x y)) :rule-classes :forward-chaining)
Theorem:
(defthm svex-envlist-equiv-of-svex-envlist-fix-2-forward (implies (svex-envlist-equiv x (svex-envlist-fix y)) (svex-envlist-equiv x y)) :rule-classes :forward-chaining)
Theorem:
(defthm car-of-svex-envlist-fix-x-under-svex-env-equiv (svex-env-equiv (car (svex-envlist-fix x)) (car x)))
Theorem:
(defthm car-svex-envlist-equiv-congruence-on-x-under-svex-env-equiv (implies (svex-envlist-equiv x x-equiv) (svex-env-equiv (car x) (car x-equiv))) :rule-classes :congruence)
Theorem:
(defthm cdr-of-svex-envlist-fix-x-under-svex-envlist-equiv (svex-envlist-equiv (cdr (svex-envlist-fix x)) (cdr x)))
Theorem:
(defthm cdr-svex-envlist-equiv-congruence-on-x-under-svex-envlist-equiv (implies (svex-envlist-equiv x x-equiv) (svex-envlist-equiv (cdr x) (cdr x-equiv))) :rule-classes :congruence)
Theorem:
(defthm cons-of-svex-env-fix-x-under-svex-envlist-equiv (svex-envlist-equiv (cons (svex-env-fix x) y) (cons x y)))
Theorem:
(defthm cons-svex-env-equiv-congruence-on-x-under-svex-envlist-equiv (implies (svex-env-equiv x x-equiv) (svex-envlist-equiv (cons x y) (cons x-equiv y))) :rule-classes :congruence)
Theorem:
(defthm cons-of-svex-envlist-fix-y-under-svex-envlist-equiv (svex-envlist-equiv (cons x (svex-envlist-fix y)) (cons x y)))
Theorem:
(defthm cons-svex-envlist-equiv-congruence-on-y-under-svex-envlist-equiv (implies (svex-envlist-equiv y y-equiv) (svex-envlist-equiv (cons x y) (cons x y-equiv))) :rule-classes :congruence)
Theorem:
(defthm consp-of-svex-envlist-fix (equal (consp (svex-envlist-fix x)) (consp x)))
Theorem:
(defthm svex-envlist-fix-under-iff (iff (svex-envlist-fix x) (consp x)))
Theorem:
(defthm svex-envlist-fix-of-cons (equal (svex-envlist-fix (cons a x)) (cons (svex-env-fix a) (svex-envlist-fix x))))
Theorem:
(defthm len-of-svex-envlist-fix (equal (len (svex-envlist-fix x)) (len x)))
Theorem:
(defthm svex-envlist-fix-of-append (equal (svex-envlist-fix (append std::a std::b)) (append (svex-envlist-fix std::a) (svex-envlist-fix std::b))))
Theorem:
(defthm svex-envlist-fix-of-repeat (equal (svex-envlist-fix (repeat acl2::n x)) (repeat acl2::n (svex-env-fix x))))
Theorem:
(defthm list-equiv-refines-svex-envlist-equiv (implies (list-equiv x y) (svex-envlist-equiv x y)) :rule-classes :refinement)
Theorem:
(defthm nth-of-svex-envlist-fix (equal (nth acl2::n (svex-envlist-fix x)) (if (< (nfix acl2::n) (len x)) (svex-env-fix (nth acl2::n x)) nil)))
Theorem:
(defthm svex-envlist-equiv-implies-svex-envlist-equiv-append-1 (implies (svex-envlist-equiv x fty::x-equiv) (svex-envlist-equiv (append x y) (append fty::x-equiv y))) :rule-classes (:congruence))
Theorem:
(defthm svex-envlist-equiv-implies-svex-envlist-equiv-append-2 (implies (svex-envlist-equiv y fty::y-equiv) (svex-envlist-equiv (append x y) (append x fty::y-equiv))) :rule-classes (:congruence))
Theorem:
(defthm svex-envlist-equiv-implies-svex-envlist-equiv-nthcdr-2 (implies (svex-envlist-equiv acl2::l l-equiv) (svex-envlist-equiv (nthcdr acl2::n acl2::l) (nthcdr acl2::n l-equiv))) :rule-classes (:congruence))
Theorem:
(defthm svex-envlist-equiv-implies-svex-envlist-equiv-take-2 (implies (svex-envlist-equiv acl2::l l-equiv) (svex-envlist-equiv (take acl2::n acl2::l) (take acl2::n l-equiv))) :rule-classes (:congruence))