Scopesubstitute into a vl-fundecl-p.
(vl-fundecl-scopesubst x ss) → new-x
Function:
(defun vl-fundecl-scopesubst (x ss) (declare (xargs :guard (and (vl-fundecl-p x) (vl-scopestack-p ss)))) (declare (ignorable x ss)) (let ((__function__ 'vl-fundecl-scopesubst)) (declare (ignorable __function__)) (b* (((vl-fundecl x) (vl-fundecl-fix x)) (ss (vl-scopestack-push (vl-fundecl->blockscope x) ss))) (change-vl-fundecl x :rettype (vl-datatype-scopesubst x.rettype ss) :vardecls (vl-vardecllist-scopesubst x.vardecls ss) :paramdecls (vl-paramdecllist-scopesubst x.paramdecls ss) :portdecls (vl-portdecllist-scopesubst x.portdecls ss) :body (vl-stmt-scopesubst x.body ss)))))
Theorem:
(defthm vl-fundecl-p-of-vl-fundecl-scopesubst (b* ((new-x (vl-fundecl-scopesubst x ss))) (vl-fundecl-p new-x)) :rule-classes :rewrite)
Theorem:
(defthm vl-fundecl-scopesubst-of-vl-fundecl-fix-x (equal (vl-fundecl-scopesubst (vl-fundecl-fix x) ss) (vl-fundecl-scopesubst x ss)))
Theorem:
(defthm vl-fundecl-scopesubst-vl-fundecl-equiv-congruence-on-x (implies (vl-fundecl-equiv x x-equiv) (equal (vl-fundecl-scopesubst x ss) (vl-fundecl-scopesubst x-equiv ss))) :rule-classes :congruence)
Theorem:
(defthm vl-fundecl-scopesubst-of-vl-scopestack-fix-ss (equal (vl-fundecl-scopesubst x (vl-scopestack-fix ss)) (vl-fundecl-scopesubst x ss)))
Theorem:
(defthm vl-fundecl-scopesubst-vl-scopestack-equiv-congruence-on-ss (implies (vl-scopestack-equiv ss ss-equiv) (equal (vl-fundecl-scopesubst x ss) (vl-fundecl-scopesubst x ss-equiv))) :rule-classes :congruence)