On Jan 13, 2011, at 2:54 AM, John Rose wrote: > On Jan 12, 2011, at 3:31 AM, Christian Thalinger wrote: > >>> If you want to convert an int to a short, you can use explicitCastArguments. >>> >>> MethodHandle mh1 = MethodHandles.identity(int.class); >>> MethodHandle mh2 = MethodHandles.explicitCastArguments(mh1, >>> MethodType.methodType(short.class, int.class)); >>> short s = (short) mh2.invokeExact(123); >> >> No, that also results in the same exception (with b124). > > The implementation of convertArguments and explicitCastArguments both need > work to conform to the final API specification. You are finding real bugs in > them. > > I am surprised that invokedynamic gave you a different result. > > The short-to-int path (the reverse of the above) should work even now, but > maybe something got broken. These unit tests are important! :-)
Yeah, I want them in! -- Christian _______________________________________________ mlvm-dev mailing list [email protected] http://mail.openjdk.java.net/mailman/listinfo/mlvm-dev
