(cst-whitespace-conc? abnf::cst) → number
Function:
(defun cst-whitespace-conc? (abnf::cst) (declare (xargs :guard (abnf::treep abnf::cst))) (declare (xargs :guard (cst-matchp abnf::cst "whitespace"))) (let ((__function__ 'cst-whitespace-conc?)) (declare (ignorable __function__)) (cond ((equal (abnf::tree-nonleaf->rulename? (nth 0 (nth 0 (abnf::tree-nonleaf->branches abnf::cst)))) (abnf::rulename "space")) 1) ((equal (abnf::tree-nonleaf->rulename? (nth 0 (nth 0 (abnf::tree-nonleaf->branches abnf::cst)))) (abnf::rulename "horizontal-tab")) 2) ((equal (abnf::tree-nonleaf->rulename? (nth 0 (nth 0 (abnf::tree-nonleaf->branches abnf::cst)))) (abnf::rulename "form-feed")) 3) ((equal (abnf::tree-nonleaf->rulename? (nth 0 (nth 0 (abnf::tree-nonleaf->branches abnf::cst)))) (abnf::rulename "line-terminator")) 4) ((equal (abnf::tree-nonleaf->rulename? (nth 0 (nth 0 (abnf::tree-nonleaf->branches abnf::cst)))) (abnf::rulename "carriage-return")) 5) (t (prog2$ (impossible) 1)))))
Theorem:
(defthm posp-of-cst-whitespace-conc? (b* ((number (cst-whitespace-conc? abnf::cst))) (posp number)) :rule-classes :rewrite)
Theorem:
(defthm cst-whitespace-conc?-possibilities (b* ((number (cst-whitespace-conc? abnf::cst))) (or (equal number 1) (equal number 2) (equal number 3) (equal number 4) (equal number 5))) :rule-classes ((:forward-chaining :trigger-terms ((cst-whitespace-conc? abnf::cst)))))
Theorem:
(defthm cst-whitespace-conc?-of-tree-fix-cst (equal (cst-whitespace-conc? (abnf::tree-fix abnf::cst)) (cst-whitespace-conc? abnf::cst)))
Theorem:
(defthm cst-whitespace-conc?-tree-equiv-congruence-on-cst (implies (abnf::tree-equiv abnf::cst cst-equiv) (equal (cst-whitespace-conc? abnf::cst) (cst-whitespace-conc? cst-equiv))) :rule-classes :congruence)
Theorem:
(defthm cst-whitespace-conc?-1-iff-match-conc (implies (cst-matchp abnf::cst "whitespace") (iff (equal (cst-whitespace-conc? abnf::cst) 1) (cst-list-list-conc-matchp (abnf::tree-nonleaf->branches abnf::cst) "space"))))
Theorem:
(defthm cst-whitespace-conc?-2-iff-match-conc (implies (cst-matchp abnf::cst "whitespace") (iff (equal (cst-whitespace-conc? abnf::cst) 2) (cst-list-list-conc-matchp (abnf::tree-nonleaf->branches abnf::cst) "horizontal-tab"))))
Theorem:
(defthm cst-whitespace-conc?-3-iff-match-conc (implies (cst-matchp abnf::cst "whitespace") (iff (equal (cst-whitespace-conc? abnf::cst) 3) (cst-list-list-conc-matchp (abnf::tree-nonleaf->branches abnf::cst) "form-feed"))))
Theorem:
(defthm cst-whitespace-conc?-4-iff-match-conc (implies (cst-matchp abnf::cst "whitespace") (iff (equal (cst-whitespace-conc? abnf::cst) 4) (cst-list-list-conc-matchp (abnf::tree-nonleaf->branches abnf::cst) "line-terminator"))))
Theorem:
(defthm cst-whitespace-conc?-5-iff-match-conc (implies (cst-matchp abnf::cst "whitespace") (iff (equal (cst-whitespace-conc? abnf::cst) 5) (cst-list-list-conc-matchp (abnf::tree-nonleaf->branches abnf::cst) "carriage-return"))))