< prev index next >

src/java.base/share/classes/sun/reflect/generics/reflectiveObjects/GenericArrayTypeImpl.java

Print this page

        

@@ -63,17 +63,12 @@
     public Type getGenericComponentType() {
         return genericComponentType; // return cached component type
     }
 
     public String toString() {
-        Type componentType = getGenericComponentType();
         StringBuilder sb = new StringBuilder();
-
-        if (componentType instanceof Class)
-            sb.append(((Class)componentType).getName() );
-        else
-            sb.append(componentType.toString());
+        sb.append(getGenericComponentType().getTypeName());
         sb.append("[]");
         return sb.toString();
     }
 
     @Override
< prev index next >