Fixing function for jimport structures.
Function:
(defun jimport-fix$inline (x) (declare (xargs :guard (jimportp x))) (let ((__function__ 'jimport-fix)) (declare (ignorable __function__)) (mbe :logic (b* ((static? (acl2::bool-fix (cdr (std::da-nth 0 x)))) (target (str-fix (cdr (std::da-nth 1 x))))) (list (cons 'static? static?) (cons 'target target))) :exec x)))
Theorem:
(defthm jimportp-of-jimport-fix (b* ((new-x (jimport-fix$inline x))) (jimportp new-x)) :rule-classes :rewrite)
Theorem:
(defthm jimport-fix-when-jimportp (implies (jimportp x) (equal (jimport-fix x) x)))
Function:
(defun jimport-equiv$inline (acl2::x acl2::y) (declare (xargs :guard (and (jimportp acl2::x) (jimportp acl2::y)))) (equal (jimport-fix acl2::x) (jimport-fix acl2::y)))
Theorem:
(defthm jimport-equiv-is-an-equivalence (and (booleanp (jimport-equiv x y)) (jimport-equiv x x) (implies (jimport-equiv x y) (jimport-equiv y x)) (implies (and (jimport-equiv x y) (jimport-equiv y z)) (jimport-equiv x z))) :rule-classes (:equivalence))
Theorem:
(defthm jimport-equiv-implies-equal-jimport-fix-1 (implies (jimport-equiv acl2::x x-equiv) (equal (jimport-fix acl2::x) (jimport-fix x-equiv))) :rule-classes (:congruence))
Theorem:
(defthm jimport-fix-under-jimport-equiv (jimport-equiv (jimport-fix acl2::x) acl2::x) :rule-classes (:rewrite :rewrite-quoted-constant))
Theorem:
(defthm equal-of-jimport-fix-1-forward-to-jimport-equiv (implies (equal (jimport-fix acl2::x) acl2::y) (jimport-equiv acl2::x acl2::y)) :rule-classes :forward-chaining)
Theorem:
(defthm equal-of-jimport-fix-2-forward-to-jimport-equiv (implies (equal acl2::x (jimport-fix acl2::y)) (jimport-equiv acl2::x acl2::y)) :rule-classes :forward-chaining)
Theorem:
(defthm jimport-equiv-of-jimport-fix-1-forward (implies (jimport-equiv (jimport-fix acl2::x) acl2::y) (jimport-equiv acl2::x acl2::y)) :rule-classes :forward-chaining)
Theorem:
(defthm jimport-equiv-of-jimport-fix-2-forward (implies (jimport-equiv acl2::x (jimport-fix acl2::y)) (jimport-equiv acl2::x acl2::y)) :rule-classes :forward-chaining)