jcf-parse.c (load_class): Back out previous broken patch.
authorAndrew Haley <aph@redhat.com>
Tue, 28 Sep 2004 14:58:31 +0000 (14:58 +0000)
committerAndrew Haley <aph@gcc.gnu.org>
Tue, 28 Sep 2004 14:58:31 +0000 (14:58 +0000)
2004-09-28  Andrew Haley  <aph@redhat.com>

* jcf-parse.c (load_class): Back out previous broken patch.

From-SVN: r88234

gcc/java/ChangeLog
gcc/java/jcf-parse.c

index 1ecd33f82553f75cca14674ef812bb0bab9af9dc..a9438f5ae2c2fe9dc4e47aeb9c6f0902090e042a 100644 (file)
@@ -1,3 +1,7 @@
+2004-09-28  Andrew Haley  <aph@redhat.com>
+
+       * jcf-parse.c (load_class): Back out previous broken patch.
+
 2004-09-28  Andrew Haley  <aph@redhat.com>
 
        PR java/17586
index f36cc95cffecec156ea820ff1d37148abafcc8cf..bc733e84f53eb18d8562a99e6b8ef92eb76c6216 100644 (file)
@@ -566,7 +566,7 @@ void
 load_class (tree class_or_name, int verbose)
 {
   tree name, saved;
-  int class_loaded = 0;
+  int class_loaded;
 
   /* class_or_name can be the name of the class we want to load */
   if (TREE_CODE (class_or_name) == IDENTIFIER_NODE)
@@ -585,20 +585,11 @@ load_class (tree class_or_name, int verbose)
     }
 
   saved = name;
-
   while (1)
     {
       char *separator;
 
-      /* We've already loaded it.  */
-      if (IDENTIFIER_CLASS_VALUE (name) != NULL_TREE)
-       {
-         tree tmp_decl = IDENTIFIER_CLASS_VALUE (name);
-         if (CLASS_PARSED_P (TREE_TYPE (tmp_decl)))
-           break;
-       }
-       
-      if (read_class (name))
+      if ((class_loaded = read_class (name)))
        break;
 
       /* We failed loading name. Now consider that we might be looking
@@ -616,13 +607,6 @@ load_class (tree class_or_name, int verbose)
        break;
     }
 
-  {
-    /* have we found the class we're looking for?  */
-    tree type_decl = IDENTIFIER_CLASS_VALUE (saved);
-    tree type = type_decl ? TREE_TYPE (type_decl) : NULL;
-    class_loaded = type && CLASS_PARSED_P (type);
-  }          
-
   if (!class_loaded && verbose)
     error ("cannot find file for class %s", IDENTIFIER_POINTER (saved));
 }