Recognizer for assigns.
(assigns-p x) → *
Function:
(defun assigns-p (x) (declare (xargs :guard t)) (let ((__function__ 'assigns-p)) (declare (ignorable __function__)) (if (atom x) t (and (consp (car x)) (lhs-p (caar x)) (driver-p (cdar x)) (assigns-p (cdr x))))))
Theorem:
(defthm assigns-p-of-butlast (implies (assigns-p (double-rewrite x)) (assigns-p (butlast x acl2::n))) :rule-classes ((:rewrite)))
Theorem:
(defthm assigns-p-of-update-nth (implies (assigns-p (double-rewrite x)) (iff (assigns-p (update-nth acl2::n y x)) (and (and (consp y) (lhs-p (car y)) (driver-p (cdr y))) (or (<= (nfix acl2::n) (len x)) (and (consp nil) (lhs-p (car nil)) (driver-p (cdr nil))))))) :rule-classes ((:rewrite)))
Theorem:
(defthm assigns-p-of-union-equal (equal (assigns-p (union-equal x y)) (and (assigns-p (list-fix x)) (assigns-p (double-rewrite y)))) :rule-classes ((:rewrite)))
Theorem:
(defthm assigns-p-of-intersection-equal-2 (implies (assigns-p (double-rewrite y)) (assigns-p (intersection-equal x y))) :rule-classes ((:rewrite)))
Theorem:
(defthm assigns-p-of-intersection-equal-1 (implies (assigns-p (double-rewrite x)) (assigns-p (intersection-equal x y))) :rule-classes ((:rewrite)))
Theorem:
(defthm assigns-p-of-set-difference-equal (implies (assigns-p x) (assigns-p (set-difference-equal x y))) :rule-classes ((:rewrite)))
Theorem:
(defthm assigns-p-set-equiv-congruence (implies (set-equiv x y) (equal (assigns-p x) (assigns-p y))) :rule-classes :congruence)
Theorem:
(defthm assigns-p-when-subsetp-equal (and (implies (and (subsetp-equal x y) (assigns-p y)) (assigns-p x)) (implies (and (assigns-p y) (subsetp-equal x y)) (assigns-p x))) :rule-classes ((:rewrite)))
Theorem:
(defthm assigns-p-of-rcons (iff (assigns-p (acl2::rcons acl2::a x)) (and (and (consp acl2::a) (lhs-p (car acl2::a)) (driver-p (cdr acl2::a))) (assigns-p (list-fix x)))) :rule-classes ((:rewrite)))
Theorem:
(defthm assigns-p-of-repeat (iff (assigns-p (repeat acl2::n x)) (or (and (consp x) (lhs-p (car x)) (driver-p (cdr x))) (zp acl2::n))) :rule-classes ((:rewrite)))
Theorem:
(defthm assigns-p-of-rev (equal (assigns-p (rev x)) (assigns-p (list-fix x))) :rule-classes ((:rewrite)))
Theorem:
(defthm assigns-p-of-list-fix (equal (assigns-p (list-fix x)) (assigns-p x)) :rule-classes ((:rewrite)))
Theorem:
(defthm assigns-p-of-append (equal (assigns-p (append acl2::a acl2::b)) (and (assigns-p acl2::a) (assigns-p acl2::b))) :rule-classes ((:rewrite)))
Theorem:
(defthm assigns-p-when-not-consp (implies (not (consp x)) (assigns-p x)) :rule-classes ((:rewrite)))
Theorem:
(defthm assigns-p-of-cdr-when-assigns-p (implies (assigns-p (double-rewrite x)) (assigns-p (cdr x))) :rule-classes ((:rewrite)))
Theorem:
(defthm assigns-p-of-cons (equal (assigns-p (cons acl2::a x)) (and (and (consp acl2::a) (lhs-p (car acl2::a)) (driver-p (cdr acl2::a))) (assigns-p x))) :rule-classes ((:rewrite)))
Theorem:
(defthm assigns-p-of-fast-alist-clean (implies (assigns-p x) (assigns-p (fast-alist-clean x))) :rule-classes ((:rewrite)))
Theorem:
(defthm assigns-p-of-hons-shrink-alist (implies (and (assigns-p x) (assigns-p y)) (assigns-p (hons-shrink-alist x y))) :rule-classes ((:rewrite)))
Theorem:
(defthm assigns-p-of-hons-acons (equal (assigns-p (hons-acons acl2::a acl2::n x)) (and (lhs-p acl2::a) (driver-p acl2::n) (assigns-p x))) :rule-classes ((:rewrite)))
Theorem:
(defthm driver-p-of-cdr-of-hons-assoc-equal-when-assigns-p (implies (assigns-p x) (iff (driver-p (cdr (hons-assoc-equal acl2::k x))) (or (hons-assoc-equal acl2::k x) (driver-p nil)))) :rule-classes ((:rewrite)))
Theorem:
(defthm driver-p-of-cdar-when-assigns-p (implies (assigns-p x) (iff (driver-p (cdar x)) (or (consp x) (driver-p nil)))) :rule-classes ((:rewrite)))
Theorem:
(defthm lhs-p-of-caar-when-assigns-p (implies (assigns-p x) (iff (lhs-p (caar x)) (or (consp x) (lhs-p nil)))) :rule-classes ((:rewrite)))