Code Review for jdk

Prepared by:twisti on Tue Jul 2 14:49:28 PDT 2013
Workspace:/Users/twisti/ws/jdk8/jdk
Compare against: http://hg.openjdk.java.net/jdk8/jdk8/jdk
Summary of changes: 99 lines changed: 98 ins; 0 del; 1 mod; 940 unchg
Patch of changes: jdk.patch
Author comments:
8019184: MethodHandles.catchException() fails when methods have 8 args + varargs
Reviewed-by:

The bug seems to be in MethodHandlesImpl.makeGuardWithCatch using ValueConversions.varargsArray:

return makeCollectArguments(ginvoker, ValueConversions.varargsArray(nargs), 0, false);

ValueConversions.varargsArray returns a MethodHandle which's type is:

MethodHandle(Object,Object,Object,Object,Object,Object,Object,Object,Object)Object[]

It doesn't preserve the trailing Object[].

The fix is to call makePairwiseConvert on the result of makeCollectArguments.

Bug id: 8019184
Legend: Modified file
Deleted file
New file

Cdiffs Udiffs Sdiffs Frames Old New Patch Raw src/share/classes/java/lang/invoke/MethodHandleImpl.java

2 lines changed: 1 ins; 0 del; 1 mod; 940 unchg

------ ------ ------ ------ --- New Patch Raw test/java/lang/invoke/TestCatchExceptionWithVarargs.java

97 lines changed: 97 ins; 0 del; 0 mod; 0 unchg

This code review page was prepared using /Users/twisti/bin/webrev (vers 23.18-hg-never-dev).