What should default interfaces be for?
pdoubleya at gmail.com
Tue Mar 13 03:30:06 PDT 2012
a good option, which I feel is in line with what the Lambda team has
proposed so far, is that default methods are necessary to allow
lambdas to be used fruitfully with existing libraries, but that care
is being taken to leave the door open to future improvements (post JDK
8) to the default method feature.
Personally, I would prefer to see an absolutely rock-solid, performant
implementation of lambda, plus associated JDK library extensions to
use them, for JDK 8, and suggest that Oracle's time is best spent
doing just that and not taking even more on.
Regarding default methods, the only concern I have is whether the
proposed approach will also prove useful for non-Java languages on the
JVM, such as Scala - in this interview with Martin Odersky he suggests
it doesn't cover all the cases he would like for Scala
More information about the lambda-dev