According to JLS 15.27.2 the lambda body has the same scope as the surrounding context and I would like to know if there is a specific reason to why default methods from the interface that is implemented by the lambda aren't available within the body too? Does this restriction enable some optimization or is it just to keep the overload rules simple?
I was prototyping some Java 8 API today and when I hit this limitation I was pretty disappointed because using default methods would have allowed me to implement that API in a very elegant and non-intrusive way.
Achieving the same elegancy is more or less possible by requiring a static import, but that results in "polluting" the namespace.
Is there a chance that this restriction will be lifted?