Updated State of the Lambda

Brian Goetz brian.goetz at oracle.com
Fri Dec 9 20:21:56 PST 2011

>> An updated State of the Lambda is available here:
>>      http://cr.openjdk.java.net/~briangoetz/lambda/lambda-state-4.html
> Excellent to see this posted to the list Brian, good read.  I'm slightly
> confused about the "Method References" section, which states that boxing
> is a valid conversion to be performed when considering whether a method
> reference's signature resolves correctly.  On this mailing list,
> however, Remi Forax said that boxing and unboxing of method reference
> parameters was still an open issue [0].  Have I got the wrong end of the
> stick?

The EG is still discussing on this.  There are two perspectives, both 
with good arguments behind them, which come down to:

A.  Lambdas and method references should be treated exactly the same.

B.  Lambdas and method references are different.  A lambda should be 
treated like it is *overriding* the method from the target type, because 
it is targeting a particular functional interface with full knowledge of 
forethought.  A method reference should be treated like it is *invoking* 
the method from the target type, with attendant greater latitude for 
conversions, because the method signature exists independently of the 
functional interface being targeted.

The EDR spec says B, but we're still discussing.  That's why it's a 
early draft release; people still have opinions and nothing is written 
in stone.

More information about the lambda-dev mailing list