anchor.diff:     (grammar-string "(")
      (grammar-* parse-token)
      (grammar-string ")")))
  +
  +(defmacro grammar-rule (name &rest body)
  +  `(defun ,name (string &key (start 0))
  +    ,@body))
  +
  +;; Example from ISO EBNF spec, section 5.7
  +(grammar-rule aa
  +  (grammar-string "A"))
  +
  +(grammar-rule bb
  +  (grammar-and
  +   (grammar-n* 3 aa)
  +   (grammar-string "B")))
  +
  +(grammar-rule cc
  +  (grammar-and
  +   (grammar-n* 3 (grammar-optional aa))
  +   (grammar-string "C")))
  +
  +(grammar-rule dd
  +  (grammar-and
  +   (grammar-* aa)
  +   (grammar-string "D")))
  +
  +(grammar-rule ee
  +  (grammar-and
  +   aa
  +   (grammar-* aa)
  +   (grammar-string "E")))
  +
  +(grammar-rule ff
  +  (grammar-and
  +   (grammar-n* 3 aa)
  +   (grammar-n* 3 (grammar-optional aa))
  +   (grammar-string "F")))
  +
  +(grammar-rule gg
  +  (grammar-and
  +   (grammar-n* 3 (grammar-* aa))
  +   (grammar-string "D")))
   
   ;; Example from ISO EBNF spec, section 5.8
   (defun letter (string &key (start 0))
  
positive.code:             (values end value)
              (grammar-or ,@rest)))))
  
  
  (defmacro grammar-* (x)
    (cond
  
negative.code: 
  ;; return a list of the children
  ;; return the end of the last child
  (defun match-n (n f string &key (start 0))
    (if (> n 0)
        (multiple-value-bind (end value) (funcall f string :start start)
          (when end
            (multiple-value-bind (e v) (match-n (1- n) f string :start end)
              (when e
                (if (car v)
                    (values e (cons value v))
                    (values e (list value)))))))
        start))
  
  (defun kleene* (f string &key (start 0))
    (multiple-value-bind (end value) (funcall f string :start start)
      (if end
          (multiple-value-bind (e v) (kleene* f string :start end)
            (values e (cons value v)))
          start)))
  
  (defun kleene+ (f string &key (start 0))
    "<rule>+ == <rule> <rule>*"
  