Recognizer for hex-string structures.
(hex-stringp x) → *
Function:
(defun hex-stringp (x) (declare (xargs :guard t)) (let ((__function__ 'hex-stringp)) (declare (ignorable __function__)) (and (consp x) (eq (car x) :hex-string) (mbe :logic (and (alistp (cdr x)) (equal (strip-cars (cdr x)) '(content double-quote-p))) :exec (fty::alist-with-carsp (cdr x) '(content double-quote-p))) (b* ((content (cdr (std::da-nth 0 (cdr x)))) (double-quote-p (cdr (std::da-nth 1 (cdr x))))) (and (hex-pair-listp content) (booleanp double-quote-p))))))
Theorem:
(defthm consp-when-hex-stringp (implies (hex-stringp x) (consp x)) :rule-classes :compound-recognizer)