Recognizer for sinteger-bit-role structures.
(sinteger-bit-rolep x) → *
Function:
(defun sinteger-bit-rolep (x) (declare (xargs :guard t)) (let ((__function__ 'sinteger-bit-rolep)) (declare (ignorable __function__)) (and (consp x) (cond ((or (atom x) (eq (car x) :sign)) (and (true-listp (cdr x)) (eql (len (cdr x)) 0) (b* nil t))) ((eq (car x) :value) (and (true-listp (cdr x)) (eql (len (cdr x)) 1) (b* ((exp (std::da-nth 0 (cdr x)))) (natp exp)))) (t (and (eq (car x) :padding) (and (true-listp (cdr x)) (eql (len (cdr x)) 0)) (b* nil t)))))))
Theorem:
(defthm consp-when-sinteger-bit-rolep (implies (sinteger-bit-rolep x) (consp x)) :rule-classes :compound-recognizer)