Recognizer for program structures.
(programp x) → *
Function:
(defun programp (x) (declare (xargs :guard t)) (let ((__function__ 'programp)) (declare (ignorable __function__)) (and (mbe :logic (and (alistp x) (equal (strip-cars x) '(tops))) :exec (fty::alist-with-carsp x '(tops))) (b* ((tops (cdr (std::da-nth 0 x)))) (toplevel-listp tops)))))
Theorem:
(defthm consp-when-programp (implies (programp x) (consp x)) :rule-classes :compound-recognizer)