This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [Patch, fortran] PR28660 - Spurious warning: 'ubound.6' is used uninitialized in this function
- From: Erik Edelmann <erik dot edelmann at iki dot fi>
- To: Paul Thomas <paulthomas2 at wanadoo dot fr>
- Cc: "'fortran at gcc dot gnu dot org'" <fortran at gcc dot gnu dot org>, patch <gcc-patches at gcc dot gnu dot org>
- Date: Mon, 14 Aug 2006 23:35:03 +0300
- Subject: Re: [Patch, fortran] PR28660 - Spurious warning: 'ubound.6' is used uninitialized in this function
- References: <44DCE04A.1040604@wanadoo.fr>
On Fri, Aug 11, 2006 at 09:53:46PM +0200, Paul Thomas wrote:
> OK for trunk and 4.2?
>
> Paul
>
> 2006-08-11 Paul Thomas <pault@gcc.gnu.org>
>
> PR fortran/28660
> * trans-decl.c (generate_expr_decls): New function.
> (generate_dependency_declarations): New function.
> (generate_local_decl): Call previous if not either a dummy or
> a declaration in an entry master.
>
> 2006-08-11 Paul Thomas <pault@gcc.gnu.org>
>
> PR fortran/28660
> * gfortran.dg/dependent_decls_1.f90: New test.
The testcase I can't judge, becasue you forgot to attach it ;-)
> *************** generate_local_decl (gfc_symbol * sym)
> *** 2760,2765 ****
> --- 2866,2879 ----
> {
> if (sym->attr.flavor == FL_VARIABLE)
> {
> + /* Check for dependencies in the array specification and needed have
> + already been added to the function. We mark the symbol now, as
> + well as in traverse_ns, to prevent getting stuck in a circular
> + dependency. */
Perhaps I'm just tired, but I don't understand the first sentence of
this comment.
Other than that, the patch looks OK to me.
Erik