Recognizer for backref-alist.
(backref-alist-p x) → *
Function:
(defun backref-alist-p (x) (declare (xargs :guard t)) (let ((__function__ 'backref-alist-p)) (declare (ignorable __function__)) (if (atom x) (eq x nil) (and (consp (car x)) (backref-p (cdar x)) (backref-alist-p (cdr x))))))
Theorem:
(defthm backref-alist-p-of-undup (implies (backref-alist-p x) (backref-alist-p (undup x))) :rule-classes ((:rewrite)))
Theorem:
(defthm backref-alist-p-of-union-equal (equal (backref-alist-p (union-equal acl2::x acl2::y)) (and (backref-alist-p (list-fix acl2::x)) (backref-alist-p (double-rewrite acl2::y)))) :rule-classes ((:rewrite)))
Theorem:
(defthm backref-alist-p-of-intersection-equal-2 (implies (backref-alist-p (double-rewrite acl2::y)) (backref-alist-p (intersection-equal acl2::x acl2::y))) :rule-classes ((:rewrite)))
Theorem:
(defthm backref-alist-p-of-intersection-equal-1 (implies (backref-alist-p (double-rewrite acl2::x)) (backref-alist-p (intersection-equal acl2::x acl2::y))) :rule-classes ((:rewrite)))
Theorem:
(defthm backref-alist-p-of-set-difference-equal (implies (backref-alist-p acl2::x) (backref-alist-p (set-difference-equal acl2::x acl2::y))) :rule-classes ((:rewrite)))
Theorem:
(defthm backref-alist-p-when-subsetp-equal (and (implies (and (subsetp-equal acl2::x acl2::y) (backref-alist-p acl2::y)) (equal (backref-alist-p acl2::x) (true-listp acl2::x))) (implies (and (backref-alist-p acl2::y) (subsetp-equal acl2::x acl2::y)) (equal (backref-alist-p acl2::x) (true-listp acl2::x)))) :rule-classes ((:rewrite)))
Theorem:
(defthm backref-alist-p-of-rcons (iff (backref-alist-p (rcons acl2::a acl2::x)) (and (and (consp acl2::a) (backref-p (cdr acl2::a))) (backref-alist-p (list-fix acl2::x)))) :rule-classes ((:rewrite)))
Theorem:
(defthm backref-alist-p-of-append (equal (backref-alist-p (append acl2::a acl2::b)) (and (backref-alist-p (list-fix acl2::a)) (backref-alist-p acl2::b))) :rule-classes ((:rewrite)))
Theorem:
(defthm backref-alist-p-of-rev (equal (backref-alist-p (rev acl2::x)) (backref-alist-p (list-fix acl2::x))) :rule-classes ((:rewrite)))
Theorem:
(defthm backref-alist-p-of-list-fix (implies (backref-alist-p acl2::x) (backref-alist-p (list-fix acl2::x))) :rule-classes ((:rewrite)))
Theorem:
(defthm true-listp-when-backref-alist-p-compound-recognizer (implies (backref-alist-p acl2::x) (true-listp acl2::x)) :rule-classes :compound-recognizer)
Theorem:
(defthm backref-alist-p-when-not-consp (implies (not (consp acl2::x)) (equal (backref-alist-p acl2::x) (not acl2::x))) :rule-classes ((:rewrite)))
Theorem:
(defthm backref-alist-p-of-cdr-when-backref-alist-p (implies (backref-alist-p (double-rewrite acl2::x)) (backref-alist-p (cdr acl2::x))) :rule-classes ((:rewrite)))
Theorem:
(defthm backref-alist-p-of-cons (equal (backref-alist-p (cons acl2::a acl2::x)) (and (and (consp acl2::a) (backref-p (cdr acl2::a))) (backref-alist-p acl2::x))) :rule-classes ((:rewrite)))
Theorem:
(defthm backref-alist-p-of-remove-assoc (implies (backref-alist-p acl2::x) (backref-alist-p (remove-assoc-equal acl2::name acl2::x))) :rule-classes ((:rewrite)))
Theorem:
(defthm backref-alist-p-of-put-assoc (implies (and (backref-alist-p acl2::x)) (iff (backref-alist-p (put-assoc-equal acl2::name acl2::val acl2::x)) (and t (backref-p acl2::val)))) :rule-classes ((:rewrite)))
Theorem:
(defthm backref-alist-p-of-fast-alist-clean (implies (backref-alist-p acl2::x) (backref-alist-p (fast-alist-clean acl2::x))) :rule-classes ((:rewrite)))
Theorem:
(defthm backref-alist-p-of-hons-shrink-alist (implies (and (backref-alist-p acl2::x) (backref-alist-p acl2::y)) (backref-alist-p (hons-shrink-alist acl2::x acl2::y))) :rule-classes ((:rewrite)))
Theorem:
(defthm backref-alist-p-of-hons-acons (equal (backref-alist-p (hons-acons acl2::a acl2::n acl2::x)) (and t (backref-p acl2::n) (backref-alist-p acl2::x))) :rule-classes ((:rewrite)))
Theorem:
(defthm backref-p-of-cdr-of-hons-assoc-equal-when-backref-alist-p (implies (backref-alist-p acl2::x) (iff (backref-p (cdr (hons-assoc-equal acl2::k acl2::x))) (or (hons-assoc-equal acl2::k acl2::x) (backref-p nil)))) :rule-classes ((:rewrite)))
Theorem:
(defthm alistp-when-backref-alist-p-rewrite (implies (backref-alist-p acl2::x) (alistp acl2::x)) :rule-classes ((:rewrite)))
Theorem:
(defthm alistp-when-backref-alist-p (implies (backref-alist-p acl2::x) (alistp acl2::x)) :rule-classes :tau-system)
Theorem:
(defthm backref-p-of-cdar-when-backref-alist-p (implies (backref-alist-p acl2::x) (iff (backref-p (cdar acl2::x)) (or (consp acl2::x) (backref-p nil)))) :rule-classes ((:rewrite)))