Recognizer for macro-info structures.
(macro-infop x) → *
Function:
(defun macro-infop (x) (declare (xargs :guard t)) (and (consp x) (cond ((or (atom x) (eq (car x) :object)) (and (true-listp (cdr x)) (eql (len (cdr x)) 1) (b* ((replace (std::da-nth 0 (cdr x)))) (and (plexeme-listp replace) (plexeme-list-token/space-p replace))))) (t (and (eq (car x) :function) (and (true-listp (cdr x)) (eql (len (cdr x)) 3)) (b* ((params (std::da-nth 0 (cdr x))) (ellipsis (std::da-nth 1 (cdr x))) (replace (std::da-nth 2 (cdr x)))) (and (ident-listp params) (booleanp ellipsis) (plexeme-listp replace) (plexeme-list-token/space-p replace))))))))
Theorem:
(defthm consp-when-macro-infop (implies (macro-infop x) (consp x)) :rule-classes :compound-recognizer)