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