Fixing function for vl-gclkdecl structures.
(vl-gclkdecl-fix x) → new-x
Function:
(defun vl-gclkdecl-fix$inline (x) (declare (xargs :guard (vl-gclkdecl-p x))) (let ((__function__ 'vl-gclkdecl-fix)) (declare (ignorable __function__)) (mbe :logic (b* ((name (maybe-string-fix (std::prod-car (std::prod-car (cdr x))))) (event (vl-evatomlist-fix (std::prod-cdr (std::prod-car (cdr x))))) (loc (vl-location-fix (std::prod-car (std::prod-cdr (cdr x))))) (atts (vl-atts-fix (std::prod-cdr (std::prod-cdr (cdr x)))))) (cons :vl-gclkdecl (std::prod-cons (std::prod-cons name event) (std::prod-cons loc atts)))) :exec x)))
Theorem:
(defthm vl-gclkdecl-p-of-vl-gclkdecl-fix (b* ((new-x (vl-gclkdecl-fix$inline x))) (vl-gclkdecl-p new-x)) :rule-classes :rewrite)
Theorem:
(defthm vl-gclkdecl-fix-when-vl-gclkdecl-p (implies (vl-gclkdecl-p x) (equal (vl-gclkdecl-fix x) x)))
Function:
(defun vl-gclkdecl-equiv$inline (acl2::x acl2::y) (declare (xargs :guard (and (vl-gclkdecl-p acl2::x) (vl-gclkdecl-p acl2::y)))) (equal (vl-gclkdecl-fix acl2::x) (vl-gclkdecl-fix acl2::y)))
Theorem:
(defthm vl-gclkdecl-equiv-is-an-equivalence (and (booleanp (vl-gclkdecl-equiv x y)) (vl-gclkdecl-equiv x x) (implies (vl-gclkdecl-equiv x y) (vl-gclkdecl-equiv y x)) (implies (and (vl-gclkdecl-equiv x y) (vl-gclkdecl-equiv y z)) (vl-gclkdecl-equiv x z))) :rule-classes (:equivalence))
Theorem:
(defthm vl-gclkdecl-equiv-implies-equal-vl-gclkdecl-fix-1 (implies (vl-gclkdecl-equiv acl2::x x-equiv) (equal (vl-gclkdecl-fix acl2::x) (vl-gclkdecl-fix x-equiv))) :rule-classes (:congruence))
Theorem:
(defthm vl-gclkdecl-fix-under-vl-gclkdecl-equiv (vl-gclkdecl-equiv (vl-gclkdecl-fix acl2::x) acl2::x) :rule-classes (:rewrite :rewrite-quoted-constant))
Theorem:
(defthm equal-of-vl-gclkdecl-fix-1-forward-to-vl-gclkdecl-equiv (implies (equal (vl-gclkdecl-fix acl2::x) acl2::y) (vl-gclkdecl-equiv acl2::x acl2::y)) :rule-classes :forward-chaining)
Theorem:
(defthm equal-of-vl-gclkdecl-fix-2-forward-to-vl-gclkdecl-equiv (implies (equal acl2::x (vl-gclkdecl-fix acl2::y)) (vl-gclkdecl-equiv acl2::x acl2::y)) :rule-classes :forward-chaining)
Theorem:
(defthm vl-gclkdecl-equiv-of-vl-gclkdecl-fix-1-forward (implies (vl-gclkdecl-equiv (vl-gclkdecl-fix acl2::x) acl2::y) (vl-gclkdecl-equiv acl2::x acl2::y)) :rule-classes :forward-chaining)
Theorem:
(defthm vl-gclkdecl-equiv-of-vl-gclkdecl-fix-2-forward (implies (vl-gclkdecl-equiv acl2::x (vl-gclkdecl-fix acl2::y)) (vl-gclkdecl-equiv acl2::x acl2::y)) :rule-classes :forward-chaining)