Scopesubstitute into a vl-port-p.
(vl-port-scopesubst x ss) → new-x
Function:
(defun vl-port-scopesubst (x ss) (declare (xargs :guard (and (vl-port-p x) (vl-scopestack-p ss)))) (declare (ignorable x ss)) (let ((__function__ 'vl-port-scopesubst)) (declare (ignorable __function__)) (b* ((x (vl-port-fix x))) (if (eq (tag x) :vl-interfaceport) (vl-interfaceport-scopesubst x ss) (vl-regularport-scopesubst x ss)))))
Theorem:
(defthm vl-port-p-of-vl-port-scopesubst (b* ((new-x (vl-port-scopesubst x ss))) (vl-port-p new-x)) :rule-classes :rewrite)
Theorem:
(defthm vl-port-scopesubst-of-vl-port-fix-x (equal (vl-port-scopesubst (vl-port-fix x) ss) (vl-port-scopesubst x ss)))
Theorem:
(defthm vl-port-scopesubst-vl-port-equiv-congruence-on-x (implies (vl-port-equiv x x-equiv) (equal (vl-port-scopesubst x ss) (vl-port-scopesubst x-equiv ss))) :rule-classes :congruence)
Theorem:
(defthm vl-port-scopesubst-of-vl-scopestack-fix-ss (equal (vl-port-scopesubst x (vl-scopestack-fix ss)) (vl-port-scopesubst x ss)))
Theorem:
(defthm vl-port-scopesubst-vl-scopestack-equiv-congruence-on-ss (implies (vl-scopestack-equiv ss ss-equiv) (equal (vl-port-scopesubst x ss) (vl-port-scopesubst x ss-equiv))) :rule-classes :congruence)