Recognizer for vl-elabinstruction structures.
(vl-elabinstruction-p x) → *
Function:
(defun vl-elabinstruction-p (x) (declare (xargs :guard t)) (let ((__function__ 'vl-elabinstruction-p)) (declare (ignorable __function__)) (and (consp x) (cond ((or (atom x) (eq (car x) :pop)) (and (true-listp (cdr x)) (eql (len (cdr x)) 1) (b* ((levels (std::da-nth 0 (cdr x)))) (natp levels)))) ((eq (car x) :root) (and (true-listp (cdr x)) (eql (len (cdr x)) 0) (b* nil t))) ((eq (car x) :push-named) (and (true-listp (cdr x)) (eql (len (cdr x)) 1) (b* ((key (std::da-nth 0 (cdr x)))) (vl-elabkey-p key)))) (t (and (eq (car x) :push-anon) (and (true-listp (cdr x)) (eql (len (cdr x)) 1)) (b* ((scope (std::da-nth 0 (cdr x)))) (vl-elabscope-p scope))))))))
Theorem:
(defthm consp-when-vl-elabinstruction-p (implies (vl-elabinstruction-p x) (consp x)) :rule-classes :compound-recognizer)