Subject: Re: struggling with READ-CHAR and LOOP (accumulating digits)
From: Erik Naggum <erik@naggum.net>
Date: 30 Oct 2000 09:04:20 +0000
Newsgroups: comp.lang.lisp
Message-ID: <3181885460303559@naggum.net>

* Kent M Pitman <pitman@world.std.com>
| (defun whitespace-p (char) 
|   (or (eql char #\Space) (not (graphic-char-p char))))
| 
| (defun gobble-whitespace (&optional (stream *standard-input*))
|   (loop for c = (read-char stream nil nil)
|         until (or (not c) ;eof
|                   (not (whitespace-p c)))))

  I use (peek-char t <stream>) for this.  Several older Lispers have
  been surprised that this functionality is in there, but it has been
  since CLtL1.

#:Erik
-- 
  Does anyone remember where I parked Air Force One?
                                   -- George W. Bush