Recognizer for escape structures.
(escapep x) → *
Function:
(defun escapep (x) (declare (xargs :guard t)) (and (consp x) (cond ((or (atom x) (eq (car x) :simple)) (and (b* ((escape (cdr x))) (simple-escapep escape)))) ((eq (car x) :oct) (and (b* ((escape (cdr x))) (oct-escapep escape)))) ((eq (car x) :hex) (and (b* ((escape (cdr x))) (hex-digit-char-listp escape)))) (t (and (eq (car x) :univ) (and) (b* ((escape (cdr x))) (univ-char-name-p escape)))))))
Theorem:
(defthm consp-when-escapep (implies (escapep x) (consp x)) :rule-classes :compound-recognizer)