Basic equivalence relation for vl-enumitemlist structures.
Function:
(defun vl-enumitemlist-equiv$inline (acl2::x acl2::y) (declare (xargs :guard (and (vl-enumitemlist-p acl2::x) (vl-enumitemlist-p acl2::y)))) (equal (vl-enumitemlist-fix acl2::x) (vl-enumitemlist-fix acl2::y)))
Theorem:
(defthm vl-enumitemlist-equiv-is-an-equivalence (and (booleanp (vl-enumitemlist-equiv x y)) (vl-enumitemlist-equiv x x) (implies (vl-enumitemlist-equiv x y) (vl-enumitemlist-equiv y x)) (implies (and (vl-enumitemlist-equiv x y) (vl-enumitemlist-equiv y z)) (vl-enumitemlist-equiv x z))) :rule-classes (:equivalence))
Theorem:
(defthm vl-enumitemlist-equiv-implies-equal-vl-enumitemlist-fix-1 (implies (vl-enumitemlist-equiv acl2::x x-equiv) (equal (vl-enumitemlist-fix acl2::x) (vl-enumitemlist-fix x-equiv))) :rule-classes (:congruence))
Theorem:
(defthm vl-enumitemlist-fix-under-vl-enumitemlist-equiv (vl-enumitemlist-equiv (vl-enumitemlist-fix acl2::x) acl2::x) :rule-classes (:rewrite :rewrite-quoted-constant))
Theorem:
(defthm equal-of-vl-enumitemlist-fix-1-forward-to-vl-enumitemlist-equiv (implies (equal (vl-enumitemlist-fix acl2::x) acl2::y) (vl-enumitemlist-equiv acl2::x acl2::y)) :rule-classes :forward-chaining)
Theorem:
(defthm equal-of-vl-enumitemlist-fix-2-forward-to-vl-enumitemlist-equiv (implies (equal acl2::x (vl-enumitemlist-fix acl2::y)) (vl-enumitemlist-equiv acl2::x acl2::y)) :rule-classes :forward-chaining)
Theorem:
(defthm vl-enumitemlist-equiv-of-vl-enumitemlist-fix-1-forward (implies (vl-enumitemlist-equiv (vl-enumitemlist-fix acl2::x) acl2::y) (vl-enumitemlist-equiv acl2::x acl2::y)) :rule-classes :forward-chaining)
Theorem:
(defthm vl-enumitemlist-equiv-of-vl-enumitemlist-fix-2-forward (implies (vl-enumitemlist-equiv acl2::x (vl-enumitemlist-fix acl2::y)) (vl-enumitemlist-equiv acl2::x acl2::y)) :rule-classes :forward-chaining)