(svtv-wires->lhses entries modidx moddb aliases) → (mv errs in-entries)
Function:
(defun svtv-wires->lhses (entries modidx moddb aliases) (declare (xargs :stobjs (moddb aliases))) (declare (xargs :guard (and (true-list-listp entries) (natp modidx) (moddb-ok moddb)))) (declare (xargs :guard (svtv-mod-alias-guard modidx moddb aliases))) (let ((__function__ 'svtv-wires->lhses)) (declare (ignorable __function__)) (b* (((when (atom entries)) (mv nil nil)) (name (caar entries)) ((mv errs lhs) (svtv-wire->lhs name modidx moddb aliases)) (entrylist (llist-fix (cdar entries))) ((mv rest-errs rest) (svtv-wires->lhses (cdr entries) modidx moddb aliases)) ((unless (svtv-entrylist-p entrylist)) (mv (cons (msg "Bad inentrylist: ~x0" entrylist) (append-without-guard errs rest-errs)) rest)) (entry (make-svtv-line :lhs lhs :entries entrylist))) (mv (append-without-guard errs rest-errs) (cons entry rest)))))
Theorem:
(defthm svtv-lines-p-of-svtv-wires->lhses.in-entries (b* (((mv ?errs ?in-entries) (svtv-wires->lhses entries modidx moddb aliases))) (svtv-lines-p in-entries)) :rule-classes :rewrite)
Theorem:
(defthm svtv-wires->lhses-of-true-list-list-fix-entries (equal (svtv-wires->lhses (true-list-list-fix entries) modidx moddb aliases) (svtv-wires->lhses entries modidx moddb aliases)))
Theorem:
(defthm svtv-wires->lhses-true-list-list-equiv-congruence-on-entries (implies (true-list-list-equiv entries entries-equiv) (equal (svtv-wires->lhses entries modidx moddb aliases) (svtv-wires->lhses entries-equiv modidx moddb aliases))) :rule-classes :congruence)
Theorem:
(defthm svtv-wires->lhses-of-nfix-modidx (equal (svtv-wires->lhses entries (nfix modidx) moddb aliases) (svtv-wires->lhses entries modidx moddb aliases)))
Theorem:
(defthm svtv-wires->lhses-nat-equiv-congruence-on-modidx (implies (nat-equiv modidx modidx-equiv) (equal (svtv-wires->lhses entries modidx moddb aliases) (svtv-wires->lhses entries modidx-equiv moddb aliases))) :rule-classes :congruence)
Theorem:
(defthm svtv-wires->lhses-of-moddb-fix-moddb (equal (svtv-wires->lhses entries modidx (moddb-fix moddb) aliases) (svtv-wires->lhses entries modidx moddb aliases)))
Theorem:
(defthm svtv-wires->lhses-moddb-equiv-congruence-on-moddb (implies (moddb-equiv moddb moddb-equiv) (equal (svtv-wires->lhses entries modidx moddb aliases) (svtv-wires->lhses entries modidx moddb-equiv aliases))) :rule-classes :congruence)
Theorem:
(defthm svtv-wires->lhses-of-lhslist-fix-aliases (equal (svtv-wires->lhses entries modidx moddb (lhslist-fix aliases)) (svtv-wires->lhses entries modidx moddb aliases)))
Theorem:
(defthm svtv-wires->lhses-lhslist-equiv-congruence-on-aliases (implies (lhslist-equiv aliases aliases-equiv) (equal (svtv-wires->lhses entries modidx moddb aliases) (svtv-wires->lhses entries modidx moddb aliases-equiv))) :rule-classes :congruence)