From: "Tobias Schlüter" <tobias.schlueter@physik.uni-muenchen.de>
To: Paul Brook <paul@codesourcery.com>
Cc: fortran@gcc.gnu.org, patch <gcc-patches@gcc.gnu.org>
Subject: Re: [gfortran] Fix PR 13201
Date: Wed, 09 Jun 2004 14:00:00 -0000 [thread overview]
Message-ID: <40C70490.3000300@physik.uni-muenchen.de> (raw)
In-Reply-To: <200406082344.14900.paul@codesourcery.com>
Here's what I committed. I changed the check to "sym->as->type !=
AS_EXPLICIT", as this seems correct and caused no adverse effects. I
also fixed an additional typo in the comment directly following.
- Tobi
Index: resolve.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/fortran/resolve.c,v
retrieving revision 1.4
diff -u -p -r1.4 resolve.c
--- resolve.c 18 May 2004 00:48:04 -0000 1.4
+++ resolve.c 9 Jun 2004 12:30:29 -0000
@@ -3736,14 +3736,22 @@ resolve_symbol (gfc_symbol * sym)
|| sym->as->type == AS_ASSUMED_SHAPE)
&& sym->attr.dummy == 0)
{
- gfc_error("Assumed %s array at %L must be a dummy argument",
- sym->as->type == AS_ASSUMED_SIZE ? "size" : "shape",
- &sym->declared_at);
+ gfc_error ("Assumed %s array at %L must be a dummy argument",
+ sym->as->type == AS_ASSUMED_SIZE ? "size" : "shape",
+ &sym->declared_at);
+ return;
+ }
+
+ if (sym->attr.flavor == FL_PARAMETER
+ && sym->as != NULL && sym->as->type != AS_EXPLICIT)
+ {
+ gfc_error ("Parameter array '%s' at %L must have an explicit shape",
+ sym->name, &sym->declared_at);
return;
}
/* Make sure that character string variables with assumed length are
- dummy argument. */
+ dummy arguments. */
if (sym->attr.flavor == FL_VARIABLE && !sym->attr.result
&& sym->ts.type == BT_CHARACTER
next prev parent reply other threads:[~2004-06-09 12:38 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-05-31 22:50 Tobias Schlüter
2004-06-08 23:54 ` Paul Brook
2004-06-09 14:00 ` Tobias Schlüter [this message]
2004-06-09 16:43 ` Jonathan Lennox
2004-06-09 16:57 ` Joseph S. Myers
2004-07-09 21:13 Tobias Schlüter
2004-07-09 21:30 ` Paul Brook
2004-07-09 22:36 ` Tobias Schlüter
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=40C70490.3000300@physik.uni-muenchen.de \
--to=tobias.schlueter@physik.uni-muenchen.de \
--cc=fortran@gcc.gnu.org \
--cc=gcc-patches@gcc.gnu.org \
--cc=paul@codesourcery.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).