Extend vl-module-make-esim across a list of modules.
(vl-modulelist-make-esims x mods modalist eal) → (mv new-x eal)
Function:
(defun vl-modulelist-make-esims (x mods modalist eal) (declare (xargs :guard (and (vl-modulelist-p x) (vl-modulelist-p mods) (vl-ealist-p eal) (equal modalist (vl-modalist mods))))) (let ((__function__ 'vl-modulelist-make-esims)) (declare (ignorable __function__)) (b* (((when (atom x)) (mv nil eal)) ((mv car eal) (vl-module-make-esim (car x) mods modalist eal)) ((mv cdr eal) (vl-modulelist-make-esims (cdr x) mods modalist eal))) (mv (cons car cdr) eal))))
Theorem:
(defthm vl-modulelist-p-of-vl-modulelist-make-esims.new-x (implies (force (vl-modulelist-p x)) (b* (((mv ?new-x ?eal) (vl-modulelist-make-esims x mods modalist eal))) (vl-modulelist-p new-x))) :rule-classes :rewrite)
Theorem:
(defthm vl-ealist-p-of-vl-modulelist-make-esims.eal (implies (and (vl-modulelist-p x) (vl-ealist-p eal)) (b* (((mv ?new-x ?eal) (vl-modulelist-make-esims x mods modalist eal))) (vl-ealist-p eal))) :rule-classes :rewrite)
Theorem:
(defthm vl-modulelist-make-esims-mvtypes-0 (true-listp (mv-nth 0 (vl-modulelist-make-esims x mods modalist eal))) :rule-classes :type-prescription)
Theorem:
(defthm vl-modulelist->names-of-vl-modulelist-make-esims (let ((ret (vl-modulelist-make-esims x mods modalist eal))) (equal (vl-modulelist->names (mv-nth 0 ret)) (vl-modulelist->names x))))