Re: Relative merits of Lisp-1 vs. Lisp-2?
- From: Ron Garret <rNOSPAMon@xxxxxxxxxxx>
- Date: Wed, 31 May 2006 11:39:31 -0700
In article <4e62huF1d5oraU1@xxxxxxxxxxxxxx>,
Pascal Costanza <pc@xxxxxxxxx> wrote:
Didier Verna wrote:
Pascal Costanza wrote:
What's wrong with that ?((make-adder 10) 3) and (let ((x (make-adder 10))) (x 3)) would not be the
same.
I fail to see the point. Since you know you're in a Lisp-2, you
know
(x 3) will need a functional value for x, which is not what let provides
(you
have flet for that), so I'm not expecting those two expressions to be the
same
at all. I just want to be able to write the first one and I don't see a
good
reason why it's not possible.
It's not a serious issue, but it could be confusing, especially when
refactoring your code. Consider taking the complement of a function:
(not ((complement f) ...)) <=> (funcall f ...)
(not (f ...)) <=> ((complement #'f) ...)
So what's the problem?
It seems to me that this would make Lisp-2 harder to explain without
gaining any expressiveness.
Common Lisp is already plenty hard to explain. I doubt this would make
matters much worse than they already are.
And the problem with forcing ((...) ...) to be an error is not losing
expressiveness, it's losing the ability to implement certain kinds of
DSLs (like the new macro system I'm working on) in a straightforward
manner. I can hack my implementation to do the Right Thing with ((...)
....) in two lines of code, and then I can implement the key feature of
my macro system (the ability to refer directly to a top-level binding)
in another two lines of code. But to do it in portable CL requires many
dozens of lines of very hacky code (because I have to shoehorn the
binding into a symbol to trick CL into calling it). It's very annoying.
rg
.
- Follow-Ups:
- Re: Relative merits of Lisp-1 vs. Lisp-2?
- From: Burton Samograd
- Re: Relative merits of Lisp-1 vs. Lisp-2?
- References:
- Relative merits of Lisp-1 vs. Lisp-2?
- From: JesusWaffle
- Re: Relative merits of Lisp-1 vs. Lisp-2?
- From: Pascal Costanza
- Re: Relative merits of Lisp-1 vs. Lisp-2?
- From: Didier Verna
- Re: Relative merits of Lisp-1 vs. Lisp-2?
- From: Pascal Costanza
- Re: Relative merits of Lisp-1 vs. Lisp-2?
- From: Didier Verna
- Re: Relative merits of Lisp-1 vs. Lisp-2?
- From: Pascal Costanza
- Relative merits of Lisp-1 vs. Lisp-2?
- Prev by Date: Re: Just can't hear enough about Cells?
- Next by Date: Re: xml and s-expression
- Previous by thread: Re: Relative merits of Lisp-1 vs. Lisp-2?
- Next by thread: Re: Relative merits of Lisp-1 vs. Lisp-2?
- Index(es):
Relevant Pages
|