Function:
(defun vl-expr-add-atts (new-atts x) (declare (xargs :guard (and (vl-atts-p new-atts) (vl-expr-p x)))) (let ((__function__ 'vl-expr-add-atts)) (declare (ignorable __function__)) (vl-expr-case x :atom (change-vl-atom x :atts (append-without-guard new-atts x.atts)) :nonatom (change-vl-nonatom x :atts (append-without-guard new-atts x.atts)))))
Theorem:
(defthm vl-expr-p-of-vl-expr-add-atts (b* ((new-x (vl-expr-add-atts new-atts x))) (vl-expr-p new-x)) :rule-classes :rewrite)
Theorem:
(defthm vl-expr-add-atts-of-vl-atts-fix-new-atts (equal (vl-expr-add-atts (vl-atts-fix new-atts) x) (vl-expr-add-atts new-atts x)))
Theorem:
(defthm vl-expr-add-atts-vl-atts-equiv-congruence-on-new-atts (implies (vl-atts-equiv new-atts new-atts-equiv) (equal (vl-expr-add-atts new-atts x) (vl-expr-add-atts new-atts-equiv x))) :rule-classes :congruence)
Theorem:
(defthm vl-expr-add-atts-of-vl-expr-fix-x (equal (vl-expr-add-atts new-atts (vl-expr-fix x)) (vl-expr-add-atts new-atts x)))
Theorem:
(defthm vl-expr-add-atts-vl-expr-equiv-congruence-on-x (implies (vl-expr-equiv x x-equiv) (equal (vl-expr-add-atts new-atts x) (vl-expr-add-atts new-atts x-equiv))) :rule-classes :congruence)