Get the lhs-size field from a vl-type-error-trunc/extend.
(vl-type-error-trunc/extend->lhs-size x) → lhs-size
This is an ordinary field accessor created by defprod.
Function:
(defun vl-type-error-trunc/extend->lhs-size$inline (x) (declare (xargs :guard (vl-type-error-p x))) (declare (xargs :guard (equal (vl-type-error-kind x) :trunc/extend))) (let ((__function__ 'vl-type-error-trunc/extend->lhs-size)) (declare (ignorable __function__)) (mbe :logic (b* ((x (and (equal (vl-type-error-kind x) :trunc/extend) x))) (nfix (std::da-nth 0 (cdr x)))) :exec (std::da-nth 0 (cdr x)))))
Theorem:
(defthm natp-of-vl-type-error-trunc/extend->lhs-size (b* ((lhs-size (vl-type-error-trunc/extend->lhs-size$inline x))) (natp lhs-size)) :rule-classes :type-prescription)
Theorem:
(defthm vl-type-error-trunc/extend->lhs-size$inline-of-vl-type-error-fix-x (equal (vl-type-error-trunc/extend->lhs-size$inline (vl-type-error-fix x)) (vl-type-error-trunc/extend->lhs-size$inline x)))
Theorem:
(defthm vl-type-error-trunc/extend->lhs-size$inline-vl-type-error-equiv-congruence-on-x (implies (vl-type-error-equiv x x-equiv) (equal (vl-type-error-trunc/extend->lhs-size$inline x) (vl-type-error-trunc/extend->lhs-size$inline x-equiv))) :rule-classes :congruence)
Theorem:
(defthm vl-type-error-trunc/extend->lhs-size-when-wrong-kind (implies (not (equal (vl-type-error-kind x) :trunc/extend)) (equal (vl-type-error-trunc/extend->lhs-size x) (nfix nil))))