Recognizer for expr-sort structures.
(expr-sortp x) → *
Function:
(defun expr-sortp (x) (declare (xargs :guard t)) (let ((__function__ 'expr-sortp)) (declare (ignorable __function__)) (and (consp x) (cond ((or (atom x) (eq (car x) :constant)) (and (true-listp (cdr x)) (eql (len (cdr x)) 0) (b* nil t))) ((eq (car x) :nonconst) (and (true-listp (cdr x)) (eql (len (cdr x)) 0) (b* nil t))) (t (and (eq (car x) :location) (and (true-listp (cdr x)) (eql (len (cdr x)) 0)) (b* nil t)))))))
Theorem:
(defthm consp-when-expr-sortp (implies (expr-sortp x) (consp x)) :rule-classes :compound-recognizer)