Lambda evaluation - postfix or prefix?

Neal Gafter neal at gafter.com
Wed Jan 27 19:09:15 PST 2010


On Wed, Jan 27, 2010 at 5:19 PM, Doug Lea <dl at cs.oswego.edu> wrote:
> Joshua Bloch wrote:
>> Along these lines I suggested * as a prefix operator, which is familiar from
>> function pointers in C and C++.  Doug Lea likes this.
>
> I admit that I do like this. The correspondence
> to function pointers is close enough that inventing a new
> syntactic form requires a good argument for
> ignoring historical precedent. Which I haven't seen.
> (although I have not had enough time to read these
> recent discussions so maybe I missed it.)

There isn't enough information in this thread to guess what syntax is
proposed.  Can you please rewrite the following example using the
proposed syntax?

#int(String)(throws IOException) foo = #(String filename)(3);
int result = foo!("bar);

Cheers,
Neal


More information about the lambda-dev mailing list