Why is *print-circle* set to T by default? WAS: grinding, etc.
Subject: Why is *print-circle* set to T by default? WAS: grinding, etc.
From: Richard Fateman
Date: Wed, 09 Feb 2011 08:20:33 -0800
I think the proper solution is to set *print-circle* to nil, but
*print-level* to some modest number, like 5 or even 10.
Sublists below level 10 then are printed as # .
If you have reason to believe that the data below that level is useful
and not a loop, you can
use lisp's pprint function to see it all.
That's what I do, anyway.
Setting *print-circle* to t is probably more expensive and definitely
harder to read with shared
substructure, and something I do only if I expect circular structures or
want to see sharing, which
is nice to know about sometimes.
Try it.
RJF
On 2/9/2011 8:06 AM, Robert Dodier wrote:
> *print-circle* is set to T because circular lists are stuck onto
> the symbol property list by the assume mechanism.
> Various Lisps barf on that (endless printing or stack overflow).
>
> e.g. with Clisp 2.42:
>
> assume (x> 0);
> :lisp (let ((*print-circle* nil)) (print (symbol-plist '$x)))
> => stack overflow
>
> CMUCL 19a:
>
> assume (x> 0);
> :lisp (let ((*print-circle* nil)) (print (symbol-plist '$x)))
> => endless mess
>
> The problem is that the bad behavior isn't limited to
> the assume system. You could be looking at something else.
>
> FWIW
>
> Robert Dodier
> _______________________________________________
> Maxima mailing list
> Maxima at math.utexas.edu
> http://www.math.utexas.edu/mailman/listinfo/maxima