Recognizer for ctrex-rule structures.
(ctrex-rule-p x) → *
Function:
(defun ctrex-rule-p (x) (declare (xargs :guard t)) (let ((__function__ 'ctrex-rule-p)) (declare (ignorable __function__)) (and (mbe :logic (and (alistp x) (equal (strip-cars x) '(name match unify-subst target deps dep-success-vars success priority value order ruletype))) :exec (fty::alist-with-carsp x '(name match unify-subst target deps dep-success-vars success priority value order ruletype))) (b* ((name (cdr (std::da-nth 0 x))) (match (cdr (std::da-nth 1 x))) (unify-subst (cdr (std::da-nth 2 x))) (target (cdr (std::da-nth 3 x))) (deps (cdr (std::da-nth 4 x))) (dep-success-vars (cdr (std::da-nth 5 x))) (success (cdr (std::da-nth 6 x))) (priority (cdr (std::da-nth 7 x))) (value (cdr (std::da-nth 8 x))) (order (cdr (std::da-nth 9 x))) (ruletype (cdr (std::da-nth 10 x)))) (and (symbolp name) (pseudo-termp match) (fgl-object-bindings-p unify-subst) (pseudo-termp target) (pseudo-term-subst-p deps) (pseudo-term-subst-p dep-success-vars) (pseudo-termp success) (pseudo-termp priority) (pseudo-termp value) (natp order) (ctrex-ruletype-p ruletype))))))
Theorem:
(defthm consp-when-ctrex-rule-p (implies (ctrex-rule-p x) (consp x)) :rule-classes :compound-recognizer)