OSDN Git Service

2008-05-22 Andrew Haley <aph@redhat.com>
[pf3gnuchains/gcc-fork.git] / libjava / java / lang / Class.java
index d59e83e..868e370 100644 (file)
@@ -1090,10 +1090,12 @@ public final class Class<T>
        ++pos;
        while (Character.isDigit(fullName.charAt(pos)))
          ++pos;
+       fullName = fullName.substring(pos);
       }
-    int packagePos = fullName.lastIndexOf(".", pos);
+
+    int packagePos = fullName.lastIndexOf(".");
     if (packagePos == -1)
-      return fullName.substring(pos);
+      return fullName;
     else
       return fullName.substring(packagePos + 1);
   }