[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
replies to hash table comments
- To: Moon@stony-brook.scrc.symbolics.com
- Subject: replies to hash table comments
- From: Jim McDonald <email@example.com>
- Date: Tue, 24 May 88 18:21:46 PDT
- Cc: firstname.lastname@example.org
Date: Tue, 24 May 88 17:31 EDT
From: David A. Moon <Moon@STONY-BROOK.SCRC.Symbolics.COM>
Here's my problem: This is a slippery slope: today it's hash tables,
tomorrow it will be random-states, next week it will be CLOS objects,
where will it end? Also bear in mind that I hate the #A and #S syntaxes
and disable them for output whenever I can. I just don't like seeing
huge amounts of output shoved in my face. That leaves me predisposed to
oppose proposals like this one.
I think one of the major underrated features of lisp is that in
general you need not spend any of your programming/debugging efforts
writing code to format the objects you're manipulating.
When I had to write in Fortan or Pascal, usually the first or second
task was to identify the data structures I was going to use, and
following that to write formatting code to be used for debugging.
Then as the structures changed I would (with growing annoyance)
rewrite the formatters. I remember those days with nausea.
I also dislike huge amounts of output, but the proper mechanism is,
as you suggested, to elide the output on first showing and possibly
make it accessible in more detail later. (Otherwise, why not argue
against the default format for lists, since some are very long.)
More parameters to control the default elision would be a welcome
addition to the language/environment.
I'd really like to be able to set some global that would, for
example, make any call to print and friends immediately terminate
after 100 characters or two newlines were produced. Or terminate
when column 78 was reached. Or put all the characters in a hidden
buffer but only display the first 40 unless that buffer is explicitly
I also would like to be able to tell defstruct in some simple manner
that a particular slot is always huge and uninteresting, so print it
as #<hidden by popular request>. Ideally, I should be able to
toggle this suppression from, say, the inspector without having said
anything about it in the defstruct definition.
It just doesn't seem that hard to come up with simple solutions for
the major offenders that spew unwelcome characters.
BTW, until your message it never occurred to me there might not be a
simple way to make CLOS objects display their contents by default.
I'd call it a misfeature if you can't.