OSDN Git Service

2006-02-09 Andrew Haley <aph@redhat.com>
authoraph <aph@138bc75d-0d04-0410-961f-82ee72b054a4>
Thu, 9 Feb 2006 14:05:31 +0000 (14:05 +0000)
committeraph <aph@138bc75d-0d04-0410-961f-82ee72b054a4>
Thu, 9 Feb 2006 14:05:31 +0000 (14:05 +0000)
        PR java/26192
        * expr.c (expand_invoke): Allow methods in arrays to be resolved
        in their superclass.

        * typeck.c (build_java_array_type): Generate TYPE_STUB_DECLs for
        array types.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@110799 138bc75d-0d04-0410-961f-82ee72b054a4

gcc/java/ChangeLog
gcc/java/expr.c
gcc/java/typeck.c

index 89cef7c..baf89cb 100644 (file)
@@ -1,3 +1,12 @@
+2006-02-09  Andrew Haley  <aph@redhat.com>
+
+       PR java/26192
+       * expr.c (expand_invoke): Allow methods in arrays to be resolved
+       in their superclass.
+
+       * typeck.c (build_java_array_type): Generate TYPE_STUB_DECLs for
+       array types.
+       
 2006-02-08  Tom Tromey  <tromey@redhat.com>
 
        PR java/22578:
index 52f7e48..785ccc4 100644 (file)
@@ -2279,6 +2279,7 @@ expand_invoke (int opcode, int method_ref_index, int nargs ATTRIBUTE_UNUSED)
      superclass chain when we're BC-compiling.  */
   if (! flag_verify_invocations
       && method
+      && ! TYPE_ARRAY_P (self_type)
       && self_type != DECL_CONTEXT (method))
     method = NULL_TREE;
 
index eac1b53..3441a1d 100644 (file)
@@ -385,9 +385,11 @@ build_java_array_type (tree element_type, HOST_WIDE_INT length)
     else
       strcpy (suffix, "[]");
     TYPE_NAME (t) 
+      = TYPE_STUB_DECL (t)
       = build_decl (TYPE_DECL,
                    identifier_subst (el_name, "", '.', '.', suffix),
                              t);
+    TYPE_DECL_SUPPRESS_DEBUG (TYPE_STUB_DECL (t)) = true;
   }
 
   set_java_signature (t, sig);