Check if a value is a signed integer [C:6.2.5/4].
Function:
(defun value-signed-integerp (val) (declare (xargs :guard (valuep val))) (let ((__function__ 'value-signed-integerp)) (declare (ignorable __function__)) (or (value-case val :schar) (value-case val :sshort) (value-case val :sint) (value-case val :slong) (value-case val :sllong))))
Theorem:
(defthm booleanp-of-value-signed-integerp (b* ((yes/no (value-signed-integerp val))) (booleanp yes/no)) :rule-classes :rewrite)
Theorem:
(defthm value-signed-integerp-of-value-fix-val (equal (value-signed-integerp (value-fix val)) (value-signed-integerp val)))
Theorem:
(defthm value-signed-integerp-value-equiv-congruence-on-val (implies (value-equiv val val-equiv) (equal (value-signed-integerp val) (value-signed-integerp val-equiv))) :rule-classes :congruence)