Collect strings representing (approximately) the individual bits of wires involved in an expression.
(vl-expr-approx-bits x mod ialist) → approx-bits
We try to return a list of strings like
This is mostly similar to the vl-wirealist-p facilities, but we trade some accuracy to be especially forgiving. We don't really try to avoid name clashes that could be caused by using escaped identifiers. We also correct for other errors in some questionable ways:
It is somewhat wrong to fudge like this, but these cases won't be hit in well-formed modules, and they allow us to handle expressions even in malformed modules in a mostly correct way without having to consider how to handle problems with collecting bits.
Theorem:
(defthm return-type-of-vl-expr-approx-bits.approx-bits (b* ((?approx-bits (vl-expr-approx-bits x mod ialist))) (string-listp approx-bits)) :rule-classes :rewrite)
Theorem:
(defthm return-type-of-vl-exprlist-approx-bits.bits (b* ((?bits (vl-exprlist-approx-bits x mod ialist))) (string-listp bits)) :rule-classes :rewrite)