Recognizer for register structures.
(registerp x) → *
Function:
(defun registerp (x) (declare (xargs :guard t)) (let ((__function__ 'registerp)) (declare (ignorable __function__)) (and (consp x) (eq (car x) :register) (mbe :logic (and (alistp (cdr x)) (equal (strip-cars (cdr x)) '(number))) :exec (fty::alist-with-carsp (cdr x) '(number))) (b* ((number (cdr (std::da-nth 0 (cdr x))))) (natp number)))))
Theorem:
(defthm consp-when-registerp (implies (registerp x) (consp x)) :rule-classes :compound-recognizer)