Matches
(vl-read-any-base echars) → (mv prefix remainder)
Function:
(defun vl-read-any-base (echars) (declare (xargs :guard (vl-echarlist-p echars))) (let ((__function__ 'vl-read-any-base)) (declare (ignorable __function__)) (b* (((mv prefix remainder) (vl-read-hex-base echars)) ((when prefix) (mv prefix remainder)) ((mv prefix remainder) (vl-read-octal-base echars)) ((when prefix) (mv prefix remainder)) ((mv prefix remainder) (vl-read-binary-base echars)) ((when prefix) (mv prefix remainder))) (vl-read-decimal-base echars))))
Theorem:
(defthm prefix-of-vl-read-any-base (and (true-listp (mv-nth 0 (vl-read-any-base echars))) (implies (force (vl-echarlist-p echars)) (vl-echarlist-p (mv-nth 0 (vl-read-any-base echars))))) :rule-classes ((:rewrite) (:type-prescription :corollary (true-listp (mv-nth 0 (vl-read-any-base echars))))))
Theorem:
(defthm remainder-of-vl-read-any-base (and (equal (true-listp (mv-nth 1 (vl-read-any-base echars))) (true-listp echars)) (implies (force (vl-echarlist-p echars)) (vl-echarlist-p (mv-nth 1 (vl-read-any-base echars))))) :rule-classes ((:rewrite) (:type-prescription :corollary (implies (true-listp echars) (true-listp (mv-nth 1 (vl-read-any-base echars)))))))
Theorem:
(defthm append-of-vl-read-any-base (equal (append (mv-nth 0 (vl-read-any-base echars)) (mv-nth 1 (vl-read-any-base echars))) echars))
Theorem:
(defthm no-change-loser-of-vl-read-any-base (implies (not (mv-nth 0 (vl-read-any-base echars))) (equal (mv-nth 1 (vl-read-any-base echars)) echars)))
Theorem:
(defthm acl2-count-of-vl-read-any-base-weak (<= (acl2-count (mv-nth 1 (vl-read-any-base echars))) (acl2-count echars)) :rule-classes ((:rewrite) (:linear)))
Theorem:
(defthm acl2-count-of-vl-read-any-base-strong (implies (mv-nth 0 (vl-read-any-base echars)) (< (acl2-count (mv-nth 1 (vl-read-any-base echars))) (acl2-count echars))) :rule-classes ((:rewrite) (:linear)))