Expand
(vl-expand-dotstar-arguments args ss ports warnings inst) → (mv successp warnings new-args)
Function:
(defun vl-expand-dotstar-arguments (args ss ports warnings inst) (declare (xargs :guard (and (vl-namedarglist-p args) (vl-scopestack-p ss) (vl-portlist-p ports) (vl-warninglist-p warnings) (vl-modinst-p inst)))) (let ((__function__ 'vl-expand-dotstar-arguments)) (declare (ignorable __function__)) (b* ((args (vl-namedarglist-fix args)) ((vl-modinst inst) (vl-modinst-fix inst)) (portnames (vl-portlist->names ports)) ((when (member nil portnames)) (mv nil (fatal :type :vl-named-args-for-unnamed-ports :msg "~a0 has named arguments, which is illegal since ~m1 ~ has unnamed ports." :args (list inst inst.modname)) args)) (argnames (vl-namedarglist->names args)) (missing (difference (mergesort portnames) (mergesort argnames))) (warnings (if missing warnings (warn :type :vl-warn-empty-dotstar :msg "~a0 mentions .*, but explicitly connects all of ~ the ports of ~m1, so the .* isn't doing anything." :args (list inst inst.modname)))) ((mv okp warnings inferred-args) (vl-create-namedargs-for-dotstar missing ss warnings inst)) ((unless okp) (mv nil warnings args)) (new-args (append inferred-args args))) (mv t warnings new-args))))
Theorem:
(defthm booleanp-of-vl-expand-dotstar-arguments.successp (b* (((mv ?successp ?warnings ?new-args) (vl-expand-dotstar-arguments args ss ports warnings inst))) (booleanp successp)) :rule-classes :type-prescription)
Theorem:
(defthm vl-warninglist-p-of-vl-expand-dotstar-arguments.warnings (b* (((mv ?successp ?warnings ?new-args) (vl-expand-dotstar-arguments args ss ports warnings inst))) (vl-warninglist-p warnings)) :rule-classes :rewrite)
Theorem:
(defthm vl-namedarglist-p-of-vl-expand-dotstar-arguments.new-args (b* (((mv ?successp ?warnings ?new-args) (vl-expand-dotstar-arguments args ss ports warnings inst))) (vl-namedarglist-p new-args)) :rule-classes :rewrite)
Theorem:
(defthm vl-expand-dotstar-arguments-of-vl-namedarglist-fix-args (equal (vl-expand-dotstar-arguments (vl-namedarglist-fix args) ss ports warnings inst) (vl-expand-dotstar-arguments args ss ports warnings inst)))
Theorem:
(defthm vl-expand-dotstar-arguments-vl-namedarglist-equiv-congruence-on-args (implies (vl-namedarglist-equiv args args-equiv) (equal (vl-expand-dotstar-arguments args ss ports warnings inst) (vl-expand-dotstar-arguments args-equiv ss ports warnings inst))) :rule-classes :congruence)
Theorem:
(defthm vl-expand-dotstar-arguments-of-vl-scopestack-fix-ss (equal (vl-expand-dotstar-arguments args (vl-scopestack-fix ss) ports warnings inst) (vl-expand-dotstar-arguments args ss ports warnings inst)))
Theorem:
(defthm vl-expand-dotstar-arguments-vl-scopestack-equiv-congruence-on-ss (implies (vl-scopestack-equiv ss ss-equiv) (equal (vl-expand-dotstar-arguments args ss ports warnings inst) (vl-expand-dotstar-arguments args ss-equiv ports warnings inst))) :rule-classes :congruence)
Theorem:
(defthm vl-expand-dotstar-arguments-of-vl-portlist-fix-ports (equal (vl-expand-dotstar-arguments args ss (vl-portlist-fix ports) warnings inst) (vl-expand-dotstar-arguments args ss ports warnings inst)))
Theorem:
(defthm vl-expand-dotstar-arguments-vl-portlist-equiv-congruence-on-ports (implies (vl-portlist-equiv ports ports-equiv) (equal (vl-expand-dotstar-arguments args ss ports warnings inst) (vl-expand-dotstar-arguments args ss ports-equiv warnings inst))) :rule-classes :congruence)
Theorem:
(defthm vl-expand-dotstar-arguments-of-vl-warninglist-fix-warnings (equal (vl-expand-dotstar-arguments args ss ports (vl-warninglist-fix warnings) inst) (vl-expand-dotstar-arguments args ss ports warnings inst)))
Theorem:
(defthm vl-expand-dotstar-arguments-vl-warninglist-equiv-congruence-on-warnings (implies (vl-warninglist-equiv warnings warnings-equiv) (equal (vl-expand-dotstar-arguments args ss ports warnings inst) (vl-expand-dotstar-arguments args ss ports warnings-equiv inst))) :rule-classes :congruence)
Theorem:
(defthm vl-expand-dotstar-arguments-of-vl-modinst-fix-inst (equal (vl-expand-dotstar-arguments args ss ports warnings (vl-modinst-fix inst)) (vl-expand-dotstar-arguments args ss ports warnings inst)))
Theorem:
(defthm vl-expand-dotstar-arguments-vl-modinst-equiv-congruence-on-inst (implies (vl-modinst-equiv inst inst-equiv) (equal (vl-expand-dotstar-arguments args ss ports warnings inst) (vl-expand-dotstar-arguments args ss ports warnings inst-equiv))) :rule-classes :congruence)