Final defenders

Talden talden at
Wed Aug 8 03:37:08 PDT 2012

On Wed, Aug 8, 2012 at 9:49 PM, Stephen Colebourne <scolebourne at> wrote:
> Where there is no doubt in my mind is that I will use traits (in
> whatever form they are provided) for far, far more than interface
> evolution when JDK8 is released.

This paragraph stood out to me.  The wording is important.

In threads attempting to use default methods as traits, the message
has consistently been that traits are not the intent of the feature
and that attempts to use them as such will produce poor results.
Indeed, if I recall correctly, that message has gone as far as stating
that traits are not a JDK8 goal.

Should we then continue to try and fill in the gaps with things like
final defaults? Can we define a useful set of cases in which value is
yielded without requiring even further gap-filler? Or does adding yet
another 'not quite traits' feature to interfaces yield so much of a
burden on developers so as to smother the benefit?

It seemed that what you were really saying was "...that I will use
interface default methods to implement traits far, far more...". I say
that because you cannot say that you will 'use traits' when they're
not on offer - you can only state an intent to use the offered
features in an unintended way.  Of course that's not a definitely bad
thing, people have done useful things in many industries including
this one by using their tools and materials in ways unintended by the

Is that intentional misuse something that should concern this project though?

Now the desire to have real traits, that 4th element, that I
understand and agree with. I don't agree with further delaying all of
the value that JDK8 brings (already delayed) to try and get them in
though.  Definitely worth making sure no-one shuts the door on them
for a later JDK though.

Aaron Scott-Boddendijk

More information about the lambda-dev mailing list