call operator and orthogonality with existing VM internals
Jakob Praher
jp at hapra.at
Tue Mar 9 09:24:40 PST 2010
Neal Gafter schrieb:
> On Tue, Mar 9, 2010 at 4:23 AM, Jakob Praher <jp at hapra.at> wrote:
>
> BGGA manages to handle function types with covariant returns and
> contravariant argument types by treating then as instances of generic
> interfaces using wildcards.
>
Makes sense. Thought about that but had problems since one has to
specify that in the formal parameters. This relation is not (easily)
encodable in the type definition itself. Function1<? extends R, ? super
T> (leaving out exceptions) has to be used as formal parameters
otherwise no "subtyping will be posisble".
This is also what I meant that here the out-of-box usablity of function
types (as interfaces) is limited. (Was this also one of the reason that
you introduced the {..=>..) syntax?)
-- Jakob.
More information about the lambda-dev
mailing list