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]
Other format: [Raw text]

Fix bootstrap in gcc/fortran/


Hi all,

My i386-linux nightly autobuilder didn't bootstrap tonight due to:

/home/fxcoudert/gfortran_nightbuild/trunk/gcc/fortran/trans-common.c: In function ‘create_common’:
/home/fxcoudert/gfortran_nightbuild/trunk/gcc/fortran/trans-common.c: 531: error: ‘field_init’ may be used uninitialized in this function


I think this can be fixed by the patch above, which I unfortunately don't have time to test: but, if someone can confirm that it does reenable bootstrap, please feel free to commit it!

Thanks,
FX



Index: trans-common.c
===================================================================
--- trans-common.c      (revision 125637)
+++ trans-common.c      (working copy)
@@ -528,7 +528,7 @@ create_common (gfc_common_head *com, seg
   tree union_type;
   tree *field_link;
   tree field;
-  tree field_init;
+  tree field_init = NULL_TREE;
   record_layout_info rli;
   tree decl;
   bool is_init = false;
@@ -551,8 +551,6 @@ create_common (gfc_common_head *com, seg
      artificial field that contains all the data.  */
   if (saw_equiv)
     field = get_init_field (head, union_type, &field_init, rli);
-  else
-    field = NULL_TREE;
   if (field != NULL_TREE)
     {


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