Pretty print a
(vl-pp-define x &key (ps 'ps)) → ps
Function:
(defun vl-pp-define-fn (x ps) (declare (xargs :stobjs (ps))) (declare (xargs :guard (vl-define-p x))) (let ((__function__ 'vl-pp-define)) (declare (ignorable __function__)) (b* (((vl-define x))) (vl-ps-seq (vl-print "`define ") (vl-print-str (vl-maybe-escape-identifier x.name)) (vl-print " ") (if (not x.formals) ps (vl-ps-seq (vl-print "(") (vl-pp-define-formals x.formals) (vl-print ") "))) (vl-print-str x.body) (vl-println "")))))
Theorem:
(defthm vl-pp-define-fn-of-vl-define-fix-x (equal (vl-pp-define-fn (vl-define-fix x) ps) (vl-pp-define-fn x ps)))
Theorem:
(defthm vl-pp-define-fn-vl-define-equiv-congruence-on-x (implies (vl-define-equiv x x-equiv) (equal (vl-pp-define-fn x ps) (vl-pp-define-fn x-equiv ps))) :rule-classes :congruence)