[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: tail call proposal [was: Re: tail recursion proposal]
| From: Kent Pitman <kmp@harlequin.com>
| Date: Fri, 9 Jan 98 02:37:46 EST
| Subject: tail call proposal [was: Re: tail recursion proposal]
|
| Does that make it any less a design trade-off? Or are you just making
| my point for me?
Of course it is a design trade-off, but so is everything else.
[The following is from memory, so please bear with me -- I don't have
a report handy]
We don't have a rationale for "dynamic typing" vs. static typing --
just a contrast because people may be unfamiliar with it.
We don't have a rationale for automatic memory management vs. explicit
memory management -- we don't even contrast this.
We don't have a rationale for arbitrary-precision integer arithmetic.
We don't have a rationale for making #f and '() distinct objects.
We don't have a rationale for having a single namespace instead of several.
We don't have a rationale for making pairs primitive and lists derived.
There are so many places where Scheme differs from most other
languages and what people may be used to that it is hard for me to
understand why you distinguish this particular design trade-off versus
any other.
Every single choice can be criticized and arguably made the other way
(otherwise it is not a realistic chioce). The purpose of the reports
is to describe the result of a lot of little choices, but not justify
them. The justification is technical, esthetic, and historical and
can be made elsewhere.
Nevertheless, it is not unwarranted to add some text to point out some
of the more unexpected differences to draw attention to readers with
no previous knowledge of the language, but familiar with languages
that have made different choices (completely validly -- don't get me wrong).
I view the rationale on proper tail-recursion implementation (although
I prefer GLS's "tail pessimization" terminology) as one of these, just
like the contrast on "dynamic typing" vs. static typing.
The reports need not be defensive, just point out how Scheme differes
from other languages, not why or whether it is a good vs. a bad
choice (presumably good since otherwise it would have been made some
other way).
Now, you might say that it is important to bring out this particular
point because it is a noticeable difference with respect to other
Lisps. To this I would say that in all likelihood, #f vs. '() are
going to be more noticeable on an every day basis. In addition, I
suspect that a significant fraction of the readers of the report do
not have a Lisp background, but (regrettably) a C background.