Generate the fifth of the specialized matching predicates.
(deftreeops-gen-cst-list-list-alt-match grammar prefix) → (mv events event-alist)
Function:
(defun deftreeops-gen-cst-list-list-alt-match (grammar prefix) (declare (xargs :guard (and (common-lisp::symbolp grammar) (common-lisp::symbolp prefix)))) (let ((__function__ 'deftreeops-gen-cst-list-list-alt-match)) (declare (ignorable __function__)) (b* ((cst-list-list-alt-matchp (deftreeops-alt-match-pred prefix)) (cst-list-list-alt-matchp$ (add-suffix-to-fn cst-list-list-alt-matchp "$")) (cst-list-list-alt-matchp$-event (cons 'define (cons cst-list-list-alt-matchp$ (cons '((treess tree-list-listp) (alt alternationp)) (cons ':returns (cons '(yes/no booleanp) (cons (cons 'and (cons '(tree-list-list-terminatedp treess) (cons (cons 'tree-list-list-match-alternation-p (cons 'treess (cons 'alt (cons grammar 'nil)))) 'nil))) '(:hooks (:fix))))))))) (cst-list-list-alt-matchp-event (cons 'defmacro (cons cst-list-list-alt-matchp (cons '(treess alt) (cons '(declare (xargs :guard (common-lisp::stringp alt))) (cons (cons 'b* (cons (cons '((mv err alt rest) (parse-alternation (string=>nats alt))) (cons (cons '(when err) (cons (cons 'er (cons 'hard (cons (cons 'quote (cons cst-list-list-alt-matchp 'nil)) '("~@0" err)))) 'nil)) (cons (cons '(when (consp rest)) (cons (cons 'er (cons 'hard (cons (cons 'quote (cons cst-list-list-alt-matchp 'nil)) '("Extra: ~s0" (nats=>string rest))))) 'nil)) '((alt (abstract-alternation alt)))))) (cons (cons 'cons (cons (cons 'quote (cons cst-list-list-alt-matchp$ 'nil)) '((cons treess (cons (cons 'quote (cons alt 'nil)) 'nil))))) 'nil))) 'nil)))))) (table-event (cons 'table (cons 'acl2::macro-aliases-table (cons (cons 'quote (cons cst-list-list-alt-matchp 'nil)) (cons (cons 'quote (cons cst-list-list-alt-matchp$ 'nil)) 'nil)))))) (mv (list cst-list-list-alt-matchp$-event cst-list-list-alt-matchp-event table-event) (list (cons cst-list-list-alt-matchp$ cst-list-list-alt-matchp$-event) (cons cst-list-list-alt-matchp cst-list-list-alt-matchp-event))))))
Theorem:
(defthm pseudo-event-form-listp-of-deftreeops-gen-cst-list-list-alt-match.events (b* (((mv ?events ?event-alist) (deftreeops-gen-cst-list-list-alt-match grammar prefix))) (pseudo-event-form-listp events)) :rule-classes :rewrite)
Theorem:
(defthm symbol-pseudoeventform-alistp-of-deftreeops-gen-cst-list-list-alt-match.event-alist (b* (((mv ?events ?event-alist) (deftreeops-gen-cst-list-list-alt-match grammar prefix))) (symbol-pseudoeventform-alistp event-alist)) :rule-classes :rewrite)