From ... From: Erik Naggum Subject: Re: 2 Common Lisp Questions Date: 1998/02/24 Message-ID: <3097297058569856@naggum.no>#1/1 X-Deja-AN: 328099434 References: <6ct032$qo7$1@Masala.CC.UH.EDU> <6cteri$t9r$1@Masala.CC.UH.EDU> mail-copies-to: never Organization: Naggum Software; +47 8800 8879; http://www.naggum.no Newsgroups: comp.lang.lisp * Barry Margolin | While Lisp implementations may perform tail call elimination, the | original poster is correct that they're not required to, as they are for | Scheme. | | The philosophy of Common Lisp is that optimizations are up to | implementors, not to be specified by the language design, and market | forces will direct them appropriately. * Some Anonymous Wanker | That's unfortunate because tail call optimization happens to be the key | to programming in Lisp using the functional paradigm (it's already suited | to this paradigm in other ways). Barry is telling you that if you need it, you go to a Lisp vendor that has made a point of making tail-call optimizations. that's what the market is all about. you don't program in a standard, you program in an actual implementation. if you are conscientious and show sufficient attention to detail, you document the parts of your application that depend on the implementation and make requirements on your users to satisfy those requirements, much like memory size and CPU speed and such when specifying minimal hardware configurations. of course, this should not be construed to mean that you ignore the standard. an implementation is supposed to conform to a standard and you should consult the standard for the proper behavior of the implemention. in that sense, you are programming according to the standard, but still _in_ the implementation. lots of issues are deferred to implementors in Common Lisp, because it was impossible to get sufficient agreement on the Only Right Thing. in Scheme, the committee refused to include many features if no such consensus could be reached. I very much appreciate the Common Lisp folks for choosing not to force me to implement stuff myself that I cannot yet, if ever, do as well as the implementors of my Common Lisp. (this is what Scheme requires of all programmers who want one of those features.) incidentally, tail call optimization has its downsides, such as making code much harder to debug. however, most real Common Lisp systems allow you to request it, and do as best as they can. implementation issues can make different tail calls optimizable in different implementations. | I take it that the standards committee isn't reconsidering this | unfortunate decision? which "unfortunate" decision? to leave decisions like that to the market forces, or not forcing a very complex requirement on all implementations? your two questions actually have the same one answer: Common Lisp is not Scheme. or more generally for Lisp: Lisp is a family of sometimes very different languages, not one language with dialects with minor variations that someone from one dialect can call flaws in another. or even more generally: judge a language on its own merits, not those of some other language. this latter point holds for _all_ languages. #:Erik -- God grant me serenity to accept the code I cannot change, courage to change the code I can, and wisdom to know the difference.