Skip to content

Commit 3ca2bcd

Browse files
committed
8335060: ClassCastException after JDK-8294960
Reviewed-by: liach, jpai
1 parent 747e1e4 commit 3ca2bcd

File tree

2 files changed

+806
-8
lines changed

2 files changed

+806
-8
lines changed

src/java.base/share/classes/java/lang/invoke/TypeConvertingMethodAdapter.java

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -69,14 +69,14 @@ private static MethodRefEntry unbox(ClassDesc owner, String methodName, ClassDes
6969
}
7070

7171
private static TypeKind primitiveTypeKindFromClass(Class<?> type) {
72-
if (type == int.class) return TypeKind.IntType;
73-
if (type == long.class) return TypeKind.LongType;
74-
if (type == boolean.class) return TypeKind.BooleanType;
75-
if (type == short.class) return TypeKind.ShortType;
76-
if (type == byte.class) return TypeKind.ByteType;
77-
if (type == char.class) return TypeKind.CharType;
78-
if (type == float.class) return TypeKind.FloatType;
79-
if (type == double.class) return TypeKind.DoubleType;
72+
if (type == Integer.class) return TypeKind.IntType;
73+
if (type == Long.class) return TypeKind.LongType;
74+
if (type == Boolean.class) return TypeKind.BooleanType;
75+
if (type == Short.class) return TypeKind.ShortType;
76+
if (type == Byte.class) return TypeKind.ByteType;
77+
if (type == Character.class) return TypeKind.CharType;
78+
if (type == Float.class) return TypeKind.FloatType;
79+
if (type == Double.class) return TypeKind.DoubleType;
8080
return null;
8181
}
8282

0 commit comments

Comments
 (0)