Skip to content

Commit 86a03b4

Browse files
committed
Better exception message
1 parent 0003547 commit 86a03b4

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

src/main/java/org/apache/commons/lang3/reflect/TypeUtils.java

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -695,16 +695,14 @@ public static Type[] getImplicitUpperBounds(final WildcardType wildcardType) {
695695
*/
696696
private static Class<?> getRawType(final ParameterizedType parameterizedType) {
697697
final Type rawType = parameterizedType.getRawType();
698-
699698
// check if raw type is a Class object
700699
// not currently necessary, but since the return type is Type instead of
701700
// Class, there's enough reason to believe that future versions of Java
702701
// may return other Type implementations. And type-safety checking is
703702
// rarely a bad idea.
704703
if (!(rawType instanceof Class<?>)) {
705-
throw new IllegalStateException("Wait... What!? Type of rawType: " + rawType);
704+
throw new IllegalStateException("Type of rawType: " + rawType);
706705
}
707-
708706
return (Class<?>) rawType;
709707
}
710708

0 commit comments

Comments
 (0)