(vl-consteval x ss scopes &key (ctxsize 'nil) (type 'nil) (lhs 'nil)) → (mv warnings new-x)
Function:
(defun vl-consteval-fn (x ss scopes ctxsize type lhs) (declare (xargs :guard (and (vl-expr-p x) (vl-scopestack-p ss) (vl-elabscopes-p scopes) (maybe-natp ctxsize) (vl-maybe-datatype-p type) (vl-maybe-expr-p lhs)))) (let ((__function__ 'vl-consteval)) (declare (ignorable __function__)) (b* (((mv ?ok ?constant warnings new-x ?svex) (vl-elaborated-expr-consteval x ss scopes :ctxsize ctxsize :type type :lhs lhs))) (mv warnings new-x))))
Theorem:
(defthm vl-warninglist-p-of-vl-consteval.warnings (b* (((mv ?warnings ?new-x) (vl-consteval-fn x ss scopes ctxsize type lhs))) (vl-warninglist-p warnings)) :rule-classes :rewrite)
Theorem:
(defthm vl-expr-p-of-vl-consteval.new-x (b* (((mv ?warnings ?new-x) (vl-consteval-fn x ss scopes ctxsize type lhs))) (vl-expr-p new-x)) :rule-classes :rewrite)
Theorem:
(defthm vl-consteval-fn-of-vl-expr-fix-x (equal (vl-consteval-fn (vl-expr-fix x) ss scopes ctxsize type lhs) (vl-consteval-fn x ss scopes ctxsize type lhs)))
Theorem:
(defthm vl-consteval-fn-vl-expr-equiv-congruence-on-x (implies (vl-expr-equiv x x-equiv) (equal (vl-consteval-fn x ss scopes ctxsize type lhs) (vl-consteval-fn x-equiv ss scopes ctxsize type lhs))) :rule-classes :congruence)
Theorem:
(defthm vl-consteval-fn-of-vl-scopestack-fix-ss (equal (vl-consteval-fn x (vl-scopestack-fix ss) scopes ctxsize type lhs) (vl-consteval-fn x ss scopes ctxsize type lhs)))
Theorem:
(defthm vl-consteval-fn-vl-scopestack-equiv-congruence-on-ss (implies (vl-scopestack-equiv ss ss-equiv) (equal (vl-consteval-fn x ss scopes ctxsize type lhs) (vl-consteval-fn x ss-equiv scopes ctxsize type lhs))) :rule-classes :congruence)
Theorem:
(defthm vl-consteval-fn-of-vl-elabscopes-fix-scopes (equal (vl-consteval-fn x ss (vl-elabscopes-fix scopes) ctxsize type lhs) (vl-consteval-fn x ss scopes ctxsize type lhs)))
Theorem:
(defthm vl-consteval-fn-vl-elabscopes-equiv-congruence-on-scopes (implies (vl-elabscopes-equiv scopes scopes-equiv) (equal (vl-consteval-fn x ss scopes ctxsize type lhs) (vl-consteval-fn x ss scopes-equiv ctxsize type lhs))) :rule-classes :congruence)
Theorem:
(defthm vl-consteval-fn-of-maybe-natp-fix-ctxsize (equal (vl-consteval-fn x ss scopes (maybe-natp-fix ctxsize) type lhs) (vl-consteval-fn x ss scopes ctxsize type lhs)))
Theorem:
(defthm vl-consteval-fn-maybe-nat-equiv-congruence-on-ctxsize (implies (acl2::maybe-nat-equiv ctxsize ctxsize-equiv) (equal (vl-consteval-fn x ss scopes ctxsize type lhs) (vl-consteval-fn x ss scopes ctxsize-equiv type lhs))) :rule-classes :congruence)
Theorem:
(defthm vl-consteval-fn-of-vl-maybe-datatype-fix-type (equal (vl-consteval-fn x ss scopes ctxsize (vl-maybe-datatype-fix type) lhs) (vl-consteval-fn x ss scopes ctxsize type lhs)))
Theorem:
(defthm vl-consteval-fn-vl-maybe-datatype-equiv-congruence-on-type (implies (vl-maybe-datatype-equiv type type-equiv) (equal (vl-consteval-fn x ss scopes ctxsize type lhs) (vl-consteval-fn x ss scopes ctxsize type-equiv lhs))) :rule-classes :congruence)
Theorem:
(defthm vl-consteval-fn-of-vl-maybe-expr-fix-lhs (equal (vl-consteval-fn x ss scopes ctxsize type (vl-maybe-expr-fix lhs)) (vl-consteval-fn x ss scopes ctxsize type lhs)))
Theorem:
(defthm vl-consteval-fn-vl-maybe-expr-equiv-congruence-on-lhs (implies (vl-maybe-expr-equiv lhs lhs-equiv) (equal (vl-consteval-fn x ss scopes ctxsize type lhs) (vl-consteval-fn x ss scopes ctxsize type lhs-equiv))) :rule-classes :congruence)