PROPOSAL: Named and Optional parameters, "Java-style"

Rémi Forax forax at
Thu Oct 20 06:32:58 PDT 2011

On 10/20/2011 02:33 PM, Frédéric Martini wrote:
> (A) I just say that this will not break existing code...
> Of course the simple fact of changing an existing class can break
> compatibility.

The only way to not break code is to consider that
optional parameters are used if all other ways to call a method
have failed (classical pre-1.5, boxing, varargs).

> (B) It seems to me that parameter's name is not always present on the
> bytecode, like when you compile with no debugging info (-g:none).

Yes, currently you have no way to be sure to have parameter names of a 
I think there is a proposal to spec a new bytecode attribute for
storing parameter name for Java 8.

> Using JSR292 and invokedynamic is a great approach for this problem !
> But it should not be possible on all methods, to avoid possible
> incompatibility on the future...

Could you elaborate ?


More information about the coin-dev mailing list