Recognizer for congruence-rule structures.
(congruence-rule-p x) → *
Function:
(defun congruence-rule-p (x) (declare (xargs :guard t)) (let ((__function__ 'congruence-rule-p)) (declare (ignorable __function__)) (and (true-listp x) (eql (len x) 4) (b* ((equiv-req (std::da-nth 0 x)) (fn (std::da-nth 1 x)) (arg-contexts (std::da-nth 2 x)) (arity (std::da-nth 3 x))) (and (pseudo-fnsym-p equiv-req) (pseudo-fnsym-p fn) (equiv-contextslist-p arg-contexts) (natp arity))))))
Theorem:
(defthm consp-when-congruence-rule-p (implies (congruence-rule-p x) (consp x)) :rule-classes :compound-recognizer)