http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45793

Tobias Burnus <burnus at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |burnus at gcc dot gnu.org

--- Comment #8 from Tobias Burnus <burnus at gcc dot gnu.org> 2010-09-26 
07:49:34 UTC ---
(In reply to comment #3)
> When building f951, there was a warning
> 
> ../trunk/gcc/fortran/module.c: In function 'create_int_parameter_array':
> ../trunk/gcc/fortran/module.c:5346: warning: 'e' may be used uninitialized in
> this function

I have never quite understood when -Werror is effective and when not!


(In reply to comment #5)
> This patch untested gets rid of the valgrind error I was seeing.

> @@ -5342,8 +5341,8 @@ create_int_parameter_array (const char *name, int
>    sym->as->upper[0] = gfc_get_int_expr (gfc_default_integer_kind, NULL, 
> size); 
> 
>    sym->value = value;
> -  e->shape = gfc_get_shape (1);
> -  mpz_init_set_ui (e->shape[0], size);
> +  sym->value->shape = gfc_get_shape (1);
> +  mpz_init_set_ui (sym->value->shape[0], size);
>  }

The patch is obvious and OK for committal. Thanks for fixing this stupid
copy-and-paste bug of mine!

Reply via email to