Get the flexiblep field from a value-struct.
This is an ordinary field accessor created by fty::defprod.
Function:
(defun value-struct->flexiblep$inline (x) (declare (xargs :guard (valuep x))) (declare (xargs :guard (equal (value-kind x) :struct))) (let ((__function__ 'value-struct->flexiblep)) (declare (ignorable __function__)) (mbe :logic (b* ((x (and (equal (value-kind x) :struct) x))) (acl2::bool-fix (std::da-nth 2 (cdr x)))) :exec (std::da-nth 2 (cdr x)))))
Theorem:
(defthm booleanp-of-value-struct->flexiblep (b* ((flexiblep (value-struct->flexiblep$inline x))) (booleanp flexiblep)) :rule-classes :rewrite)
Theorem:
(defthm value-struct->flexiblep$inline-of-value-fix-x (equal (value-struct->flexiblep$inline (value-fix x)) (value-struct->flexiblep$inline x)))
Theorem:
(defthm value-struct->flexiblep$inline-value-equiv-congruence-on-x (implies (value-equiv x x-equiv) (equal (value-struct->flexiblep$inline x) (value-struct->flexiblep$inline x-equiv))) :rule-classes :congruence)
Theorem:
(defthm value-struct->flexiblep-when-wrong-kind (implies (not (equal (value-kind x) :struct)) (equal (value-struct->flexiblep x) (acl2::bool-fix nil))))