Rewrite operators throughout a vl-namedarglist-p
(vl-namedarglist-oprewrite x warnings) → (mv warnings new-x)
Function:
(defun vl-namedarglist-oprewrite (x warnings) (declare (xargs :guard (and (vl-namedarglist-p x) (vl-warninglist-p warnings)))) (let ((__function__ 'vl-namedarglist-oprewrite)) (declare (ignorable __function__)) (b* (((when (atom x)) (mv (ok) nil)) ((mv warnings car-prime) (vl-namedarg-oprewrite (car x) warnings)) ((mv warnings cdr-prime) (vl-namedarglist-oprewrite (cdr x) warnings))) (mv warnings (cons car-prime cdr-prime)))))
Theorem:
(defthm vl-warninglist-p-of-vl-namedarglist-oprewrite.warnings (b* (((mv ?warnings ?new-x) (vl-namedarglist-oprewrite x warnings))) (vl-warninglist-p warnings)) :rule-classes :rewrite)
Theorem:
(defthm vl-namedarglist-p-of-vl-namedarglist-oprewrite.new-x (b* (((mv ?warnings ?new-x) (vl-namedarglist-oprewrite x warnings))) (vl-namedarglist-p new-x)) :rule-classes :rewrite)
Theorem:
(defthm vl-namedarglist-oprewrite-mvtypes-1 (true-listp (mv-nth 1 (vl-namedarglist-oprewrite x warnings))) :rule-classes :type-prescription)
Theorem:
(defthm vl-namedarglist-oprewrite-of-vl-namedarglist-fix-x (equal (vl-namedarglist-oprewrite (vl-namedarglist-fix x) warnings) (vl-namedarglist-oprewrite x warnings)))
Theorem:
(defthm vl-namedarglist-oprewrite-vl-namedarglist-equiv-congruence-on-x (implies (vl-namedarglist-equiv x x-equiv) (equal (vl-namedarglist-oprewrite x warnings) (vl-namedarglist-oprewrite x-equiv warnings))) :rule-classes :congruence)
Theorem:
(defthm vl-namedarglist-oprewrite-of-vl-warninglist-fix-warnings (equal (vl-namedarglist-oprewrite x (vl-warninglist-fix warnings)) (vl-namedarglist-oprewrite x warnings)))
Theorem:
(defthm vl-namedarglist-oprewrite-vl-warninglist-equiv-congruence-on-warnings (implies (vl-warninglist-equiv warnings warnings-equiv) (equal (vl-namedarglist-oprewrite x warnings) (vl-namedarglist-oprewrite x warnings-equiv))) :rule-classes :congruence)