(vl-unparam-basename-exprstring x) → str
Function:
(defun vl-unparam-basename-exprstring (x) (declare (xargs :guard (vl-maybe-expr-p x))) (let ((__function__ 'vl-unparam-basename-exprstring)) (declare (ignorable __function__)) (if x (if (and (vl-expr-resolved-p x) (b* (((mv & size) (vl-expr-selfsize x nil nil)) ((mv & type) (vl-expr-typedecide x nil nil))) (and (eql size 32) (eq type :vl-signed)))) (b* ((val (vl-resolved->val x))) (cat (if (< val 0) "-" "") (natstr (abs val)))) (common-lisp::substitute #\_ #\Space (vl-pps-expr x))) "NULL")))
Theorem:
(defthm stringp-of-vl-unparam-basename-exprstring (b* ((str (vl-unparam-basename-exprstring x))) (stringp str)) :rule-classes :type-prescription)
Theorem:
(defthm vl-unparam-basename-exprstring-of-vl-maybe-expr-fix-x (equal (vl-unparam-basename-exprstring (vl-maybe-expr-fix x)) (vl-unparam-basename-exprstring x)))
Theorem:
(defthm vl-unparam-basename-exprstring-vl-maybe-expr-equiv-congruence-on-x (implies (vl-maybe-expr-equiv x x-equiv) (equal (vl-unparam-basename-exprstring x) (vl-unparam-basename-exprstring x-equiv))) :rule-classes :congruence)