From: Kenneth D. Forbus

Subject: Re: configuring the internal pretty-printer

Date: 1998-6-11 11:26

Maybe I'm old-fashioned, but I find DO -- which is part of the common
lisp spec -- is just as easy to use, is more flexible, and displays well under pretty-printing.

At 09:50 AM 6/11/98 -0500, Rob Farrow wrote:
> >One suggestion is to use ITERATE instead of LOOP. For those of us who >don't prefer the "non-sexp" way that loop keywords appear, Iter is a >well used alternative. It is not common lisp but it is widely ported. It >is also extensible, unlike Loop. > >(iter > (for p in primes) > (until (> p max)) > (never (zerop (rem i p))) > (finally > (rplacd last (list i)) > (setq last (rest last)))) > >You will find ITERATE at most lisp FTP sites. > > >Rob Farrow || There is no ultimate answer. >Phone: 972/480-2698 MSGID: RCFJ || Only more revealing ways >Email: <ti.com at farrow> || of looking at the question. > > > >Juanma Barranquero writes:
> > -----BEGIN PGP SIGNED MESSAGE----- > > Hash: SHA1 > > > > (I'm using ACL4W release 3.0.2) > > > > Is there any way to configure the internal pretty-printer to do a > > somewhat friendlier indenting *without* having to resort to the XP > > pretty-printer? > > > > Currently, it (in re-indent, and not pretty-print, mode) indents one > > of my test loops like that: > > > > (loop > > for p in primes > > until (> p max) > > never (zerop (rem i p)) > > finally > > (rplacd last (list i)) > > (setq last (rest last)))) > > > > And that doesn't seem to be that At the very least, the forms in the > > finally clause should be indented a few spaces, I think. > > > > If I use the pretty-print mode, I get: > > > > (LOOP > > FOR > > P > > IN > > PRIMES > > UNTIL > > (> P MAX) > > NEVER > > (ZEROP (REM I P)) > > FINALLY > > (RPLACD LAST (LIST I)) > > (SETQ LAST (REST LAST)))) > > > > which is even worse. > > > > Thanks, > > > > /L/e/k/t/u > > > > > > -----BEGIN PGP SIGNATURE----- > > Version: PGPfreeware 5.5.3i; see <http://www.pgpi.com> > > > > iQA/AwUBNX+T2f4C0a0jUw5YEQIM+gCfVk7VsKtqgwaD0Iw2qem+bIxxU+wAoOz5 > > 1rLcMlmSKH2PnPWBHJQknlOV > > =7Qzo > > -----END PGP SIGNATURE----- > >
> >