[bootstrap-O3,fortran] add a NULL initializer to avoid a warning at -O3
authorAlexandre Oliva <aoliva@redhat.com>
Thu, 5 Jan 2017 01:46:01 +0000 (01:46 +0000)
committerAlexandre Oliva <aoliva@gcc.gnu.org>
Thu, 5 Jan 2017 01:46:01 +0000 (01:46 +0000)
Building with the bootstrap-O3 configuration option fails to compile
fortran/module.c due to an AFAICT false-positive warning about an
uninitialized use of a variable.

This patch adds a dummy initializer to silence it.

for  gcc/fortran/ChangeLog

* module.c (load_omp_udrs): Initialize name.

From-SVN: r244087

gcc/fortran/ChangeLog
gcc/fortran/module.c

index ec209b2..95c5279 100644 (file)
@@ -1,3 +1,7 @@
+2017-01-04  Alexandre Oliva <aoliva@redhat.com>
+
+       * module.c (load_omp_udrs): Initialize name.
+
 2017-01-02  Janne Blomqvist  <jb@gcc.gnu.org>
 
        PR fortran/78534
index d738cf4..b3b0967 100644 (file)
@@ -4702,7 +4702,7 @@ load_omp_udrs (void)
   mio_lparen ();
   while (peek_atom () != ATOM_RPAREN)
     {
-      const char *name, *newname;
+      const char *name = NULL, *newname;
       char *altname;
       gfc_typespec ts;
       gfc_symtree *st;