home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.lang.lisp
- Path: sparky!uunet!ornl!rsg1.er.usgs.gov!darwin.sura.net!spool.mu.edu!mixcom.com!wstar.mixcom.com!jpf
- From: jpf@wstar.mixcom.com (John P. Flanagan)
- Subject: Re: *READ-SUPPRESS* and #P syntax
- Message-ID: <1992Nov19.170212.370@wstar.mixcom.com>
- Date: Thu, 19 Nov 1992 17:02:12 GMT
- References: <1992Nov15.210151.1062@wstar.mixcom.com> <1e934iINNaod@early-bird.think.com> <1992Nov18.000646.1180@wstar.mixcom.com> <1ee4m8INNbmt@early-bird.think.com>
- Organization: WaveStar Technology
- Lines: 62
-
- barmar@think.com (Barry Margolin) writes:
-
- >In article <1992Nov18.000646.1180@wstar.mixcom.com> jpf@wstar.mixcom.com (John P. Flanagan) writes:
- >>barmar@think.com (Barry Margolin) writes:
- >>>My interpretation of *READ-SUPPRESS* is that when it doesn't say something
- >>>operates differently from normal, it should operate the normal way. Thus,
- >>
- >>Maybe it's the cloudy weather affecting my judgement, but since nearly
- >>all sharp reader macros behave a certain way when *read-suppress* is
- >>non-nil, why then would you assume that a sharp reader macro that slipped
- >>through the specification net wouldn't behave in a similar manner?
-
- >I based my assumption on the fact that CLtL and the dpANS specifically list
- >only a small number of sharpsign macros in the the description of
- >*READ-SUPPRESS*, and make no mention of a general default effect of setting
- >this variable. When interpreting a language standard (AKA "language
- >lawyering"), it's generally not appropriate to extrapolate from specific
- >instances to general cases.
-
- According to my copy only three sharp reader macros, #C, #(, and #',
- were left out of the description for *READ-SUPPRESS*, that's hardly a
- small number! We have twelve *specific* reader macro examples to ponder
- in that description of *READ-SUPPRESS*; excluding #=, all produce nil when
- *READ-SUPPRESS* is non-nil. How much extrapolation is required to properly
- reconcile the behavior of #C, #(, or #' given this kind of evidence?
-
- >>Normally these two expressions produce a vector of two elements, the symbols
- >>foo and bar, but when *read-suppress* is non-nil we get this instead?
- >>
- >> #1A(foo bar)
- >> => nil
- >>
- >> #(foo bar)
- >> => #(nil nil)
- >>
- >>Isn't this a bit inconsistent (if not confusing)?
-
- >I agree that it's inconsistent and confusing, but I also believe it's
- >implied by CLtL.
-
- One man's implication is another man's extrapolation? ;-)
-
- >Actually, I'm considering suggesting a more general change:
-
- > When *READ-SUPPRESS* is true, READ, READ-PRESERVING-WHITESPACE, and
- > READ-DELIMITED-LIST all return NIL; however, they continue to parse the
- > representation of an object in the normal way, in order to skip over
- > the object. Any standard read macro that is defined to read an object
- > or token will do so, but not signal an error if the object read is not
- > of an appropriate type or syntax.
-
- >Sound reasonable?
-
- Yes, very much so, but you're already tempting fate (**EXTRAPOLATION**)
- by not mentioning READ-FROM-STRING!
-
- -jpf.
- --
- __________________________________________________________________________
- WaveStar Technology WaveStar Common Lisp John P. Flanagan
- W344 N6855 Bayberry Court ANSI-12.24, X3J13/92 (414) 367-5014
- Oconomowoc, WI 53066 HPUX-800/700/400/300 jpf@wstar.mixcom.com
-