Extract the MSB (left) index from a resolved vl-range.
(vl-range-msbidx x) → msb
Function:
(defun vl-range-msbidx (x) (declare (xargs :guard (and (vl-range-p x) (vl-range-resolved-p x)))) (let ((__function__ 'vl-range-msbidx)) (declare (ignorable __function__)) (b* (((vl-range x) x)) (vl-resolved->val x.msb))))
Theorem:
(defthm integerp-of-vl-range-msbidx (b* ((msb (vl-range-msbidx x))) (integerp msb)) :rule-classes :type-prescription)