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