Default method survey results

Steven Simpson ss at comp.lancs.ac.uk
Thu Aug 16 02:30:51 PDT 2012


On 13/08/12 15:24, Maurizio Cimadamore wrote:
> *) a keyword (like default) at the beginning of the method declaration
> will make it very clear and unambiguous that the following method
> declaration is kinda special.

I'd like to drop the keyword, but it might serve a very practical 
purpose beyond this hint.

AIUI, disappointment has been expressed that the current semantics don't 
allow equals(), hashCode(), etc to be overridden.  It's a limit of the 
best semantics that have been devised so far.  If it turns out that they 
can be improved at a later date, but without backward compatibility, the 
'default' keyword could serve to distinguish legacy code that expects to 
have legacy semantics.



More information about the lambda-dev mailing list