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!feed.news.nacamar.de!uio.no!nntp.uio.no!ifi.uio.no!not-for-mail From: Erik Naggum Newsgroups: comp.lang.lisp Subject: Re: READ-DELIMITED-FORM Date: 04 Sep 2002 21:43:53 +0000 Organization: Naggum Software, Oslo, Norway Lines: 44 Message-ID: <3240164633704542@naggum.no> References: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: maud.ifi.uio.no 1031175834 27955 129.240.64.16 (4 Sep 2002 21:43:54 GMT) X-Complaints-To: abuse@ifi.uio.no NNTP-Posting-Date: 4 Sep 2002 21:43:54 GMT Mail-Copies-To: never User-Agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.2 Xref: archiver1.google.com comp.lang.lisp:39624 * Tim Bradshaw | I've been thinking about how to implement this function, and I've convinced | myself that it's very hard indeed. You have asked for hooks into the reader previously, as well, and it is something I have wanted for a long time, too. In particular, I would like to stop the reader before it interns a symbol and instead use find-symbol on the string to avoid creating a new symbol. I also think it would be nice to make , a non-terminating macro character so you can read back integers like 1,073,741,824. | So, here's what I don't know how to do. You do this at too high a level. You must read a token and intervene before it is interpreted as an integer, floating-point number, or symbol. You will find a function that does this in all available Common Lisp implementations. I would think that a portable implementation of the reader that is way more programmable than the one we have today would be a worthwhile project. I am certainly interested in spending time on it as I want it for my own needs. | `look for a consing dot' is the hard bit. Not at all, but it is hard to do it after the token has been interpreted and the information upon which you have to make this decision has been destroyed. | So I think this is actually very hard. But I'd be delighted to be | proved wrong. Does anyone have any ideas? I think the above should remove all the problems you have tried to solve. | I obviously haven't thought this through very far, and the sketched interface | above is junk, I think, because it would probably be very hard to implement | for lots of readers (and also it's just junk anyway), but what I really want | to have is some way of getting at the reader *before* it does things like | intern symbols and so on. That would be such a nice thing to have. Very much so. -- 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.