Is there a way to inspect the state of the parser that I am missing?
Specifically, I would like to have access to the string of characters
that constitute a line of input.
Here is what I wrote, but I would like to know if this state is not
already available and I am just missing something obvious.
Leo
(defvar *parse-tyi-sf-fun* (symbol-function 'parse-tyi))
(defvar *parse-stack* '())
(defvar *parse-current-input-line* '())
(defun parse-tyi ()
(declare (special *parse-stack* *parse-tyi* *parse-current-input-line*))
(let ((c (funcall *parse-tyi-sf-fun*)))
(push c *parse-stack*)
(push c *parse-current-input-line*)
;; faulty: ignores quotes
(cond ((member c '(#\; #\$))
(setf (get (makelabel $inchar) '$input) (coerce (reverse *parse-current-input-line*) 'string)
*parse-current-input-line* '()))
(t nil))
c))