re PR java/2538 (latest gcj no longer compiles apache xerces parser due problems...
authorAlexandre Petit-Bianco <apbianco@redhat.com>
Tue, 8 May 2001 08:11:26 +0000 (01:11 -0700)
committerAlexandre Petit-Bianco <apbianco@gcc.gnu.org>
Tue, 8 May 2001 08:11:26 +0000 (01:11 -0700)
2001-05-07  Alexandre Petit-Bianco  <apbianco@redhat.com>

* parse.y (build_unresolved_array_type): Set
EXPR_WFL_QUALIFICATION on the newly created wfl.
Fixes PR java/2538. Fixes PR java/2535.

(http://gcc.gnu.org/ml/gcc-patches/2001-05/msg00438.html )

From-SVN: r41917

gcc/java/ChangeLog
gcc/java/parse.y

index fc09afd787243397725d423ec98b258a0370b67b..01f513bc44cc16d3fedcc22ca9ab3bb5684621ed 100644 (file)
@@ -1,3 +1,9 @@
+2001-05-07  Alexandre Petit-Bianco  <apbianco@redhat.com>
+
+       * parse.y (build_unresolved_array_type): Set
+       EXPR_WFL_QUALIFICATION on the newly created wfl.
+       Fixes PR java/2538. Fixes PR java/2535.
+
 2001-05-07  Alexandre Petit-Bianco  <apbianco@redhat.com>
 
        * parse.y (fix_constructors): Removed unecessary assignment to
index aaff8b4fd713cbc3ad28ff0fe87d275d67cfb02c..9985c736e01c0eba13dca9d024ebdea7a218af87 100644 (file)
@@ -3305,6 +3305,7 @@ build_unresolved_array_type (type_or_wfl)
      tree type_or_wfl;
 {
   const char *ptr;
+  tree wfl;
 
   /* TYPE_OR_WFL might be an array on a resolved type. In this case,
      just create a array type */
@@ -3316,10 +3317,14 @@ build_unresolved_array_type (type_or_wfl)
                 IDENTIFIER_POINTER (EXPR_WFL_NODE (type_or_wfl)),
                 IDENTIFIER_LENGTH (EXPR_WFL_NODE (type_or_wfl)));
   ptr = obstack_finish (&temporary_obstack);
-  return build_expr_wfl (get_identifier (ptr),
-                        EXPR_WFL_FILENAME (type_or_wfl),
-                        EXPR_WFL_LINENO (type_or_wfl),
-                        EXPR_WFL_COLNO (type_or_wfl));
+  wfl = build_expr_wfl (get_identifier (ptr),
+                       EXPR_WFL_FILENAME (type_or_wfl),
+                       EXPR_WFL_LINENO (type_or_wfl),
+                       EXPR_WFL_COLNO (type_or_wfl));
+  /* Re-install the existing qualifications so that the type can be
+     resolved properly. */
+  EXPR_WFL_QUALIFICATION (wfl) = EXPR_WFL_QUALIFICATION (type_or_wfl);
+  return wfl;
 }
 
 static void