This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

[PATCH] Java: fixing a declaration.


The following patch fixes a misplaced declaration in
java/parse.y:check_inner_class_access:

  http://gcc.gnu.org/ml/java/2001-02/msg00284.html

I'm checking this in, both in the branch and the trunk.

./A

Index: ChangeLog
===================================================================
RCS file: /cvs/gcc/gcc/gcc/java/ChangeLog,v
retrieving revision 1.647.2.7
diff -u -p -r1.647.2.7 ChangeLog
--- ChangeLog	2001/02/19 22:46:57	1.647.2.7
+++ ChangeLog	2001/02/20 20:00:22
@@ -1,3 +1,8 @@
+2001-02-20  Alexandre Petit-Bianco  <apbianco@redhat.com>
+
+	* parse.y (check_inner_class_access): Moved declaration of local
+	`enclosing_decl_type' to the right location.
+
 2001-02-19  Bryce McKinlay  <bryce@albatross.co.nz>
 
 	* parse.y (parser_check_super_interface): Don't call 
Index: parse.y
===================================================================
RCS file: /cvs/gcc/gcc/gcc/java/parse.y,v
retrieving revision 1.251.2.5
diff -u -p -r1.251.2.5 parse.y
--- parse.y	2001/02/19 22:46:58	1.251.2.5
+++ parse.y	2001/02/20 20:00:58
@@ -6789,6 +6789,7 @@ check_inner_class_access (decl, enclosin
      tree decl, enclosing_decl, cl;
 {
   const char *access;
+  tree enclosing_decl_type;
 
   /* We don't issue an error message when CL is null. CL can be null
      as a result of processing a JDEP crafted by source_start_java_method
@@ -6798,7 +6799,7 @@ check_inner_class_access (decl, enclosin
   if (!decl || !cl)
     return;
 
-  tree enclosing_decl_type = TREE_TYPE (enclosing_decl);
+  enclosing_decl_type = TREE_TYPE (enclosing_decl);
 
   if (CLASS_PRIVATE (decl))
     {


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]