Parser


(defun parse (sent)
 (let ()
   (init-sent sent)
   (if (eq *word* 'what) (next))
   (cond ((eq *word* 'customers)
           (next)
           (addretrieve
             (dbaccess 'customer))
           (loc)
           (if (eq *word* 'ordered)
                 (next))
           (part) (supplier) (datespec))
         ((eq *word* 'who)
           (next)
           (addretrieve
             (dbaccess 'customer))
           (loc)
           (if (eq *word* 'ordered)
               (next))
           (part) (supplier) (datespec)))
;  (prin1 *retrieve*) (terpri) ; for trace
;  (prin1 *restrict*) (terpri) ; for trace
   (if *sent* (error `words left over'))))

Contents    Page-10    Prev    Next    Page+10    Index