This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [gfortran] Patch for pr20363
- From: Tobias Schlüter <tobias dot schlueter at physik dot uni-muenchen dot de>
- To: Erik Edelmann <eedelman at acclab dot helsinki dot fi>
- Cc: fortran at gcc dot gnu dot org, gcc-patches at gcc dot gnu dot org
- Date: Sun, 10 Jul 2005 22:17:55 +0200
- Subject: Re: [gfortran] Patch for pr20363
- References: <20050707234709.GA21080@acclab.helsinki.fi>
Erik Edelmann wrote:
> The attached patch fixes pr20363. The problem was the function
> find_special in decl.c. When in an INTERFACE, we first checked
> if the name was the name of the interface, and only then, if it
> wasn't, we looked in the current name space. With this patch, we
> do it the other way around.
Can you explain to me why we need find_special()? It looks like it would
simply not make sense to call it in build_sym(). Or anywhere else, for that
matter, but maybe I misunderstand. And with your patch it doesn't seem to do
much special any longer. There are also a few minor issues which I point out
below.
> + int i;
>
> + i = gfc_get_symbol (name, NULL, result);
> + if (i==0)
Blanks are required around "==". This line has a trailing blank.
> + goto end;
Why not simply return i;? Also everywhere else where you goto end.
> ! { dg-do compile }
> module snafu
The testcase should say which PR it tests in a comment.
Thanks,
- Tobi