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