This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [gfortran] Fix PR 13201
- From: Paul Brook <paul at codesourcery dot com>
- To: fortran at gcc dot gnu dot org
- Cc: Tobias Schlüter <tobias dot schlueter at physik dot uni-muenchen dot de>,patch <gcc-patches at gcc dot gnu dot org>
- Date: Fri, 9 Jul 2004 21:53:09 +0100
- Subject: Re: [gfortran] Fix PR 13201
- Organization: CodeSourcery
- References: <40EF0064.90805@physik.uni-muenchen.de>
On Friday 09 July 2004 21:30, Tobias Schlüter wrote:
> My previous fixlet for PR 13201 didn't catch the general case of a
> parameter array not having a constant shape. This followup patch fixes
> that omission.
>
> Looking the patch over, I think a better name than 'constant shape' is
> probably called for. I'm open to suggestions how to concisely say
> 'explicit shape, determined at compile time by means of constants'. I
> will definitely enhance the comment in array.c.
The standard calls variables whose size is not known at compile time
"automatic objects". My suggested wording is:
"Parameter array '%s' at %L cannot be automatic or assumed shape"
Assumed size already triggers a different error elsewhere.
> Built and tested on i686-pc-linux.
>
> - Tobi
>
> 2004-07-09 Tobias Schlueter <tobias.schlueter@physik.uni-muenchen.de>
>
> PR fortran/13201
> * resolve.c (resolve_symbol): Verify that the shape of a
> parameter array is not only explicit, but also constant.
> * array.c (gfc_is_constant_shape): New function.
> * gfortran.h (gfc_is_constant_shape): Add prototype.
Ok.
Paul