--- a/jdk/test/sun/invoke/util/ValueConversionsTest.java Wed Jul 05 18:20:00 2017 +0200
+++ b/jdk/test/sun/invoke/util/ValueConversionsTest.java Fri Aug 17 13:42:25 2012 -0700
@@ -159,14 +159,8 @@
assertEquals(caster.type(), ValueConversions.identity().type());
for (Object obj : objects) {
Class<?> src = obj.getClass();
- boolean canCast;
- if (dst.isInterface()) {
- canCast = true;
- } else {
- canCast = dst.isAssignableFrom(src);
- assertEquals(canCast, dst.isInstance(obj));
- }
- //System.out.println("obj="+obj+" <: dst="+dst);
+ boolean canCast = dst.isAssignableFrom(src);
+ //System.out.println("obj="+obj+" <: dst="+dst+(canCast ? " (OK)" : " (will fail)"));
try {
Object result = caster.invokeExact(obj);
if (canCast)