(svexl-node-array-fix x) is an ACL2::fty alist fixing function that follows the fix-keys strategy.
(svexl-node-array-fix x) → fty::newx
Note that in the execution this is just an inline identity function.
Function:
(defun svexl-node-array-fix$inline (x) (declare (xargs :guard (svexl-node-array-p x))) (let ((acl2::__function__ 'svexl-node-array-fix)) (declare (ignorable acl2::__function__)) (mbe :logic (if (atom x) nil (if (consp (car x)) (cons (cons (nfix (caar x)) (svexl-node-fix (cdar x))) (svexl-node-array-fix (cdr x))) (svexl-node-array-fix (cdr x)))) :exec x)))
Theorem:
(defthm svexl-node-array-p-of-svexl-node-array-fix (b* ((fty::newx (svexl-node-array-fix$inline x))) (svexl-node-array-p fty::newx)) :rule-classes :rewrite)
Theorem:
(defthm svexl-node-array-fix-when-svexl-node-array-p (implies (svexl-node-array-p x) (equal (svexl-node-array-fix x) x)))
Function:
(defun svexl-node-array-equiv$inline (acl2::x acl2::y) (declare (xargs :guard (and (svexl-node-array-p acl2::x) (svexl-node-array-p acl2::y)))) (equal (svexl-node-array-fix acl2::x) (svexl-node-array-fix acl2::y)))
Theorem:
(defthm svexl-node-array-equiv-is-an-equivalence (and (booleanp (svexl-node-array-equiv x y)) (svexl-node-array-equiv x x) (implies (svexl-node-array-equiv x y) (svexl-node-array-equiv y x)) (implies (and (svexl-node-array-equiv x y) (svexl-node-array-equiv y z)) (svexl-node-array-equiv x z))) :rule-classes (:equivalence))
Theorem:
(defthm svexl-node-array-equiv-implies-equal-svexl-node-array-fix-1 (implies (svexl-node-array-equiv acl2::x x-equiv) (equal (svexl-node-array-fix acl2::x) (svexl-node-array-fix x-equiv))) :rule-classes (:congruence))
Theorem:
(defthm svexl-node-array-fix-under-svexl-node-array-equiv (svexl-node-array-equiv (svexl-node-array-fix acl2::x) acl2::x) :rule-classes (:rewrite :rewrite-quoted-constant))
Theorem:
(defthm equal-of-svexl-node-array-fix-1-forward-to-svexl-node-array-equiv (implies (equal (svexl-node-array-fix acl2::x) acl2::y) (svexl-node-array-equiv acl2::x acl2::y)) :rule-classes :forward-chaining)
Theorem:
(defthm equal-of-svexl-node-array-fix-2-forward-to-svexl-node-array-equiv (implies (equal acl2::x (svexl-node-array-fix acl2::y)) (svexl-node-array-equiv acl2::x acl2::y)) :rule-classes :forward-chaining)
Theorem:
(defthm svexl-node-array-equiv-of-svexl-node-array-fix-1-forward (implies (svexl-node-array-equiv (svexl-node-array-fix acl2::x) acl2::y) (svexl-node-array-equiv acl2::x acl2::y)) :rule-classes :forward-chaining)
Theorem:
(defthm svexl-node-array-equiv-of-svexl-node-array-fix-2-forward (implies (svexl-node-array-equiv acl2::x (svexl-node-array-fix acl2::y)) (svexl-node-array-equiv acl2::x acl2::y)) :rule-classes :forward-chaining)
Theorem:
(defthm cons-of-nfix-k-under-svexl-node-array-equiv (svexl-node-array-equiv (cons (cons (nfix acl2::k) acl2::v) acl2::x) (cons (cons acl2::k acl2::v) acl2::x)))
Theorem:
(defthm cons-nat-equiv-congruence-on-k-under-svexl-node-array-equiv (implies (acl2::nat-equiv acl2::k k-equiv) (svexl-node-array-equiv (cons (cons acl2::k acl2::v) acl2::x) (cons (cons k-equiv acl2::v) acl2::x))) :rule-classes :congruence)
Theorem:
(defthm cons-of-svexl-node-fix-v-under-svexl-node-array-equiv (svexl-node-array-equiv (cons (cons acl2::k (svexl-node-fix acl2::v)) acl2::x) (cons (cons acl2::k acl2::v) acl2::x)))
Theorem:
(defthm cons-svexl-node-equiv-congruence-on-v-under-svexl-node-array-equiv (implies (svexl-node-equiv acl2::v v-equiv) (svexl-node-array-equiv (cons (cons acl2::k acl2::v) acl2::x) (cons (cons acl2::k v-equiv) acl2::x))) :rule-classes :congruence)
Theorem:
(defthm cons-of-svexl-node-array-fix-y-under-svexl-node-array-equiv (svexl-node-array-equiv (cons acl2::x (svexl-node-array-fix acl2::y)) (cons acl2::x acl2::y)))
Theorem:
(defthm cons-svexl-node-array-equiv-congruence-on-y-under-svexl-node-array-equiv (implies (svexl-node-array-equiv acl2::y y-equiv) (svexl-node-array-equiv (cons acl2::x acl2::y) (cons acl2::x y-equiv))) :rule-classes :congruence)
Theorem:
(defthm svexl-node-array-fix-of-acons (equal (svexl-node-array-fix (cons (cons acl2::a acl2::b) x)) (cons (cons (nfix acl2::a) (svexl-node-fix acl2::b)) (svexl-node-array-fix x))))
Theorem:
(defthm svexl-node-array-fix-of-append (equal (svexl-node-array-fix (append std::a std::b)) (append (svexl-node-array-fix std::a) (svexl-node-array-fix std::b))))
Theorem:
(defthm consp-car-of-svexl-node-array-fix (equal (consp (car (svexl-node-array-fix x))) (consp (svexl-node-array-fix x))))