(vl-description-fix x) is a fty fixing function.
(vl-description-fix x) → fty::newx
Note that in the execution this is just an inline identity function.
Function:
(defun vl-description-fix$inline (x) (declare (xargs :guard (vl-description-p x))) (let ((__function__ 'vl-description-fix)) (declare (ignorable __function__)) (mbe :logic (common-lisp::case (tag x) ((:vl-module) (vl-module-fix x)) ((:vl-udp) (vl-udp-fix x)) ((:vl-interface) (vl-interface-fix x)) ((:vl-package) (vl-package-fix x)) ((:vl-program) (vl-program-fix x)) ((:vl-class) (vl-class-fix x)) ((:vl-config) (vl-config-fix x)) ((:vl-bind) (vl-bind-fix x)) ((:vl-property) (vl-property-fix x)) ((:vl-sequence) (vl-sequence-fix x)) ((:vl-vardecl) (vl-vardecl-fix x)) ((:vl-taskdecl) (vl-taskdecl-fix x)) ((:vl-fundecl) (vl-fundecl-fix x)) ((:vl-paramdecl) (vl-paramdecl-fix x)) ((:vl-import) (vl-import-fix x)) ((:vl-fwdtypedef) (vl-fwdtypedef-fix x)) ((:vl-typedef) (vl-typedef-fix x)) ((:vl-dpiimport) (vl-dpiimport-fix x)) (otherwise (vl-dpiexport-fix x))) :exec x)))
Theorem:
(defthm vl-description-p-of-vl-description-fix (b* ((fty::newx (vl-description-fix$inline x))) (vl-description-p fty::newx)) :rule-classes :rewrite)
Theorem:
(defthm vl-description-fix-when-vl-description-p (implies (vl-description-p x) (equal (vl-description-fix x) x)))
Function:
(defun vl-description-equiv$inline (acl2::x acl2::y) (declare (xargs :guard (and (vl-description-p acl2::x) (vl-description-p acl2::y)))) (equal (vl-description-fix acl2::x) (vl-description-fix acl2::y)))
Theorem:
(defthm vl-description-equiv-is-an-equivalence (and (booleanp (vl-description-equiv x y)) (vl-description-equiv x x) (implies (vl-description-equiv x y) (vl-description-equiv y x)) (implies (and (vl-description-equiv x y) (vl-description-equiv y z)) (vl-description-equiv x z))) :rule-classes (:equivalence))
Theorem:
(defthm vl-description-equiv-implies-equal-vl-description-fix-1 (implies (vl-description-equiv acl2::x x-equiv) (equal (vl-description-fix acl2::x) (vl-description-fix x-equiv))) :rule-classes (:congruence))
Theorem:
(defthm vl-description-fix-under-vl-description-equiv (vl-description-equiv (vl-description-fix acl2::x) acl2::x) :rule-classes (:rewrite :rewrite-quoted-constant))
Theorem:
(defthm equal-of-vl-description-fix-1-forward-to-vl-description-equiv (implies (equal (vl-description-fix acl2::x) acl2::y) (vl-description-equiv acl2::x acl2::y)) :rule-classes :forward-chaining)
Theorem:
(defthm equal-of-vl-description-fix-2-forward-to-vl-description-equiv (implies (equal acl2::x (vl-description-fix acl2::y)) (vl-description-equiv acl2::x acl2::y)) :rule-classes :forward-chaining)
Theorem:
(defthm vl-description-equiv-of-vl-description-fix-1-forward (implies (vl-description-equiv (vl-description-fix acl2::x) acl2::y) (vl-description-equiv acl2::x acl2::y)) :rule-classes :forward-chaining)
Theorem:
(defthm vl-description-equiv-of-vl-description-fix-2-forward (implies (vl-description-equiv acl2::x (vl-description-fix acl2::y)) (vl-description-equiv acl2::x acl2::y)) :rule-classes :forward-chaining)
Theorem:
(defthm tag-of-vl-description-fix-forward (or (equal (tag (vl-description-fix x)) :vl-module) (equal (tag (vl-description-fix x)) :vl-udp) (equal (tag (vl-description-fix x)) :vl-interface) (equal (tag (vl-description-fix x)) :vl-package) (equal (tag (vl-description-fix x)) :vl-program) (equal (tag (vl-description-fix x)) :vl-class) (equal (tag (vl-description-fix x)) :vl-config) (equal (tag (vl-description-fix x)) :vl-bind) (equal (tag (vl-description-fix x)) :vl-property) (equal (tag (vl-description-fix x)) :vl-sequence) (equal (tag (vl-description-fix x)) :vl-vardecl) (equal (tag (vl-description-fix x)) :vl-taskdecl) (equal (tag (vl-description-fix x)) :vl-fundecl) (equal (tag (vl-description-fix x)) :vl-paramdecl) (equal (tag (vl-description-fix x)) :vl-import) (equal (tag (vl-description-fix x)) :vl-fwdtypedef) (equal (tag (vl-description-fix x)) :vl-typedef) (equal (tag (vl-description-fix x)) :vl-dpiimport) (equal (tag (vl-description-fix x)) :vl-dpiexport)) :rule-classes ((:forward-chaining :trigger-terms ((tag (vl-description-fix x))))))