On Wed, 26 Jan 2022 00:06:25 GMT, liach wrote:
> They will probably accept a MethodHandles.Lookup object to define a class for
> such a single-interface instance plus calling the default methods beyond the
> restrictions.
Yes, that's one option. Such library should take a Lookup parameter to
On Tue, 25 Jan 2022 22:01:22 GMT, Johannes Kuhn wrote:
> My question was for when a library wants to implement something similar to
> `MethodHandleProxies.asInterfaceInstace`, and for example supports Interfaces
> with more than a single abstract method. Currently, such a library would also
>
On Tue, 25 Jan 2022 21:35:27 GMT, Mandy Chung wrote:
>> The MethodHandle of a default method should be made as a fixed arity method
>> handle because it is invoked via Proxy's invocation handle with a non-vararg
>> array of arguments. On the other hand, the
>> `InvocationHandle::invokeDefault
> The MethodHandle of a default method should be made as a fixed arity method
> handle because it is invoked via Proxy's invocation handle with a non-vararg
> array of arguments. On the other hand, the `InvocationHandle::invokeDefault`
> method was added in Java 16 to invoke a default method o
On Tue, 25 Jan 2022 17:20:50 GMT, Mandy Chung wrote:
> What about this:
Looks okay, main thing is to have it be consistent with the existing methods.
-
PR: https://git.openjdk.java.net/jdk/pull/7185
On Tue, 25 Jan 2022 14:36:26 GMT, Alan Bateman wrote:
>> Mandy Chung has updated the pull request incrementally with one additional
>> commit since the last revision:
>>
>> fix accident argument ordering after edit
>
> src/java.base/share/classes/jdk/internal/access/JavaLangReflectAccess.java
On Mon, 24 Jan 2022 23:13:24 GMT, Mandy Chung wrote:
> To invoke the default method, the caller will need access to the declaring
> interface of the default method (via bytecode invocation or reflection). The
> bug I had was because java.base (the module of the invocation handler) does
> not h
On Mon, 24 Jan 2022 23:18:41 GMT, Mandy Chung wrote:
>> The MethodHandle of a default method should be made as a fixed arity method
>> handle because it is invoked via Proxy's invocation handle with a non-vararg
>> array of arguments. On the other hand, the
>> `InvocationHandle::invokeDefault
On Mon, 24 Jan 2022 23:02:52 GMT, Johannes Kuhn wrote:
>> Mandy Chung has updated the pull request incrementally with three additional
>> commits since the last revision:
>>
>> - revert MethodHandlesProxiesTest change
>> - Add new regression test
>> - Should not perform access check on the i
> The MethodHandle of a default method should be made as a fixed arity method
> handle because it is invoked via Proxy's invocation handle with a non-vararg
> array of arguments. On the other hand, the `InvocationHandle::invokeDefault`
> method was added in Java 16 to invoke a default method o
On Mon, 24 Jan 2022 23:03:49 GMT, Mandy Chung wrote:
>> The MethodHandle of a default method should be made as a fixed arity method
>> handle because it is invoked via Proxy's invocation handle with a non-vararg
>> array of arguments. On the other hand, the
>> `InvocationHandle::invokeDefault
On Sat, 22 Jan 2022 21:48:38 GMT, Johannes Kuhn wrote:
>> The MethodHandle of a default method should be made as a fixed arity method
>> handle because it is invoked via Proxy's invocation handle with a non-vararg
>> array of arguments. On the other hand, the
>> `InvocationHandle::invokeDefau
> The MethodHandle of a default method should be made as a fixed arity method
> handle because it is invoked via Proxy's invocation handle with a non-vararg
> array of arguments. On the other hand, the `InvocationHandle::invokeDefault`
> method was added in Java 16 to invoke a default method o
On Fri, 21 Jan 2022 22:49:38 GMT, Mandy Chung wrote:
> The MethodHandle of a default method should be made as a fixed arity method
> handle because it is invoked via Proxy's invocation handle with a non-vararg
> array of arguments. On the other hand, the `InvocationHandle::invokeDefault`
> me
On Fri, 21 Jan 2022 22:49:38 GMT, Mandy Chung wrote:
> The MethodHandle of a default method should be made as a fixed arity method
> handle because it is invoked via Proxy's invocation handle with a non-vararg
> array of arguments. On the other hand, the `InvocationHandle::invokeDefault`
> me
On Fri, 21 Jan 2022 23:16:50 GMT, liach wrote:
> Will older versions up to Java 8 get an alternative fix (changing the
> accessed handle to non-vararg) too?
This is up to the update release maintainers to decide. The backport fix is
straight-forward. I include that in the JBS report.
-
On Fri, 21 Jan 2022 22:49:38 GMT, Mandy Chung wrote:
> The MethodHandle of a default method should be made as a fixed arity method
> handle because it is invoked via Proxy's invocation handle with a non-vararg
> array of arguments. On the other hand, the `InvocationHandle::invokeDefault`
> me
The MethodHandle of a default method should be made as a fixed arity method
handle because it is invoked via Proxy's invocation handle with a non-vararg
array of arguments. On the other hand, the `InvocationHandle::invokeDefault`
method was added in Java 16 to invoke a default method of a prox
18 matches
Mail list logo