Re: [Rd] Curry: proposed new functional programming, er, function.

From: Yike Lu <>
Date: Sat, 26 May 2012 12:30:05 -0400

On 5/25/12 5:23 PM, Hadley Wickham wrote:
> On Fri, May 25, 2012 at 3:14 PM, Yike Lu<> wrote:
>> So here's the way I'm reading this:
>> Original:
>> curry_call is the function body you're constructing, which is itself just a
>> one liner which calls the symbol FUN with the appropriate substitutions.
> Yup. With a bit more infrastructure you could probably modify it so
> that multiple curries collapsed into the equivalent single curry.
Yes I could see how one would do that - if the detects a Curry as the first function being called, we would short circuit the usual evaluation into a different path which properly collapses all the nesting.

It's interesting how R offers these facilities to override the usual evaluation order, but if one does that too much it could easily become confusing. I was looking at Rpipe the other day ( and the way he implements it is by defining his own Eval.

Cheers, mailing list Received on Sat 26 May 2012 - 16:34:46 GMT

This quarter's messages: by month, or sorted: [ by date ] [ by thread ] [ by subject ] [ by author ]

All messages

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Sat 26 May 2012 - 18:11:39 GMT.

Mailing list information is available at Please read the posting guide before posting to the list.

list of date sections of archive