Hi

I don't think there is a reasonable objection to forbid a form like

        ((returns-something-funcallable arg1 arg2 ... argN) 1 2 3 ... N)

from "working as expected".  As Martin pointed out, if the return value of the 
form is a "macro" then this would have to be interpreted in the "regular" 
evaluation regime.

As per "extending" LET there have been a lot of proposals... IMHO a nice one is 
to go the LOOP way :)

(LETS [var <symbol> <form>]*
      [fun (<name> <arglist> <body>)]*
      [labels (<name> <arglist> <body>)]*
      [values <list> <form>]*
  IN
  <body>)

Of course you can add some ways of extending the syntax by having something like

(def-lets-binding <tag> ...)

You get the idea....

Cheers
--
MA



On May 25, 2011, at 17:51 , Matthew Swank wrote:

> Alessio Stalla <alessiostalla@...> writes:
> 
>> 
>> On Wed, May 25, 2011 at 4:45 PM, Matthew Swank
>> <akopa.gmane.poster@...> wrote:
>>> Pascal Costanza <pc@...> writes:
>>> 
>>>> 
>>>> 
>>>> On 25 May 2011, at 04:51, Matthew D. Swank wrote:
>>> 
>>>>> However, consider the following:
>>>>> 
>>>>> ((returns-a-function) arg arg ...)
>>>>> 
>>>>> Would it be reasonable to allow this as a legal form as well?
>> 
>> While in principle I like such a thing, I think it doesn't play well
>> with Lisp-2 (or more specifically, with Common Lisp). If ((whatever)
>> ...) is a valid expression, then one would expect (let ((foo
>> (whatever))) (foo ...)) to be equivalent, but it's not. And you can't
>> use flet/labels for the same effect. 
> 
> Well, let bindings could be extended to use an operator to specify the 
> namespace:
> 
> (let (((function foo) (lambda (arg ...) ...))
>      (bar  (lambda (arg ...) ...)))
>  (foo ...)
>  (funcall bar ...))
> 
> 
> and flet/labels would transform into a generalized let binding.
> 
> This would make the standard transformation of let -> function call a little
> problematic, however.
> 
> I suppose at the bottom of all this is an implied primitive binding operator 
> for
> operators: perhaps flambda!
> 
> Matt
> 
> 
> 
> _______________________________________________
> pro mailing list
> pro@common-lisp.net
> http://lists.common-lisp.net/cgi-bin/mailman/listinfo/pro

--
Marco Antoniotti, Associate Professor                           tel.    +39 - 
02 64 48 79 01
DISCo, Università Milano Bicocca U14 2043               
http://bimib.disco.unimib.it
Viale Sarca 336
I-20126 Milan (MI) ITALY

Please note that I am not checking my Spam-box anymore.
Please do not forward this email without asking me first.





_______________________________________________
pro mailing list
pro@common-lisp.net
http://lists.common-lisp.net/cgi-bin/mailman/listinfo/pro

Reply via email to