aboutsummaryrefslogtreecommitdiff
path: root/gcc/fortran/io.c
diff options
context:
space:
mode:
authorTobias Schlüter <tobias.schlueter@physik.uni-muenchen.de>2004-11-06 13:49:13 +0100
committerTobias Schlüter <tobi@gcc.gnu.org>2004-11-06 13:49:13 +0100
commitc1df75d1a2eada01c913ba68bfe6a4dfbf9324b3 (patch)
tree765a4f22a680d2ac052e21b8484cf41e523451a2 /gcc/fortran/io.c
parentd08bf5fa33ca8d704846d234a59a13168f97d5a5 (diff)
downloadgcc-c1df75d1a2eada01c913ba68bfe6a4dfbf9324b3.zip
gcc-c1df75d1a2eada01c913ba68bfe6a4dfbf9324b3.tar.gz
gcc-c1df75d1a2eada01c913ba68bfe6a4dfbf9324b3.tar.bz2
re PR fortran/18023 (ice on trying to convert between int and float)
PR fortran/18023 * io.c (resolve_tag): Tighten up exception for assigned FORMAT. From-SVN: r90169
Diffstat (limited to 'gcc/fortran/io.c')
-rw-r--r--gcc/fortran/io.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/gcc/fortran/io.c b/gcc/fortran/io.c
index 73bb06b..1ee7031 100644
--- a/gcc/fortran/io.c
+++ b/gcc/fortran/io.c
@@ -968,10 +968,10 @@ resolve_tag (const io_tag * tag, gfc_expr * e)
if (e->ts.type != tag->type)
{
/* Format label can be integer varibale. */
- if (tag != &tag_format)
+ if (tag != &tag_format || e->ts.type != BT_INTEGER)
{
gfc_error ("%s tag at %L must be of type %s", tag->name, &e->where,
- gfc_basic_typename (tag->type));
+ gfc_basic_typename (tag->type));
return FAILURE;
}
}