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