From ... Path: archiver1.google.com!news1.google.com!newsfeed.stanford.edu!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!newsfeed.icl.net!newsfeed.fjserv.net!news.algonet.se!algonet!newsfeed1.bredband.com!bredband!uio.no!Norway.EU.net!newsfeed1.ulv.nextra.no!nextra.com!news-feed.ifi.uio.no!ifi.uio.no!not-for-mail From: Erik Naggum Newsgroups: comp.lang.lisp Subject: Re: READ-DELIMITED-FORM Date: 05 Sep 2002 10:32:01 +0000 Organization: Naggum Software, Oslo, Norway Lines: 28 Message-ID: <3240210721844260@naggum.no> References: <3240164830618395@naggum.no> <3240206449214856@naggum.no> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: maud.ifi.uio.no 1031221922 1478 129.240.64.16 (5 Sep 2002 10:32:02 GMT) X-Complaints-To: abuse@ifi.uio.no NNTP-Posting-Date: 5 Sep 2002 10:32:02 GMT Mail-Copies-To: never User-Agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.2 Xref: archiver1.google.com comp.lang.lisp:39689 * Tim Bradshaw | But don't I need to know if there *was* any whitespace? No. Why do you think you need it? | I think that (peek-char t) fails to distinguish between the first and second | of these cases. We have the following situation. After a token has been read, you are either looking at a terminating macro character or a non-constituent character such as whitespace. This is an invariant. Before you read a token, you skip any whitespace. This is an invariant. So you read the token. If that token is the consing dot, you read the next token and should now look at the closing paren. You interpret and add the last read token to your list in the appropriate manner and continue or return as appropriate. | But I am now quite confused about the whole thing. I completely fail to understand what can be confusing here. The reader algorithm is described in detail in the standard and in CLtL2. I think you may have confused yourself by trying to see the consing dot after you have interpreted the tokens. -- Erik Naggum, Oslo, Norway Act from reason, and failure makes you rethink and study harder. Act from faith, and failure makes you blame someone and push harder.