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