Typed Method handles

Rémi Forax forax at univ-mlv.fr
Mon Jun 13 17:52:06 PDT 2011


Hi Neal,

On 06/14/2011 01:54 AM, Neal Gafter wrote:
> Paulo-
>
> I think you misunderstood the technical meaning of my comment, its intended
> tone, and my corporate affiliation.
>
> What I meant by "if we can't then we'll regret not doing it today" is that I
> do not believe we will be able to add reified function types in the future
> because it would break existing code (I can expand on this point if you
> like).

Please expand. I'm curious.

>   Function types could have a beneficial affect on the shape of APIs
> being added along with project Lambda.  If function types are added after SE
> 8, then it will be too late to adapt the APIs added in SE 8 to use them
> instead of SAM interfaces.  Therefore I think we may come to regret not
> adding function types as part of project Lambda.

We may regret but we may not.

There are some technical questions about function types that must be solved:
     A function type is an object type or not ?
     Basically it should be like an array type, but array type are reified,
     Does it mean that function type should be reified.
     In that case, what about function type that use a generics.
     A function type using only reified type is reified or not ?

Also some syntax questions are hard to solve :
   - what is the syntax for function type ?
   - how a human can parse a function type with a function type as 
parameter type
     and/or return type ?

It's not a hazard if mainstream languages that are functional are 
dynamically typed
or/and used type inference.

> I admit my comments are rather short at times, but I didn't mean this to be
> snarky.
>
> I am affiliated with neither Oracle nor Google.  In fact I work for
> Microsoft, but I do care very much about the Java community and the future
> of the Java programming language.  Although I'm not happy about the lawsuit
> between Oracle and Google, I'm very happy that Oracle is now taking control
> of the Java language with some long-term thinking (though I might not agree
> with all the details).  You'll be able to hear more of how I feel about
> these topics when the video of my keynote from a couple of weeks ago in
> Paris is published<http://www.whatsnextparis.com/>.
>
> Cheers,
> Neal

cheers,
Rémi



More information about the lambda-dev mailing list