From 4453ef2fde154a7a2344da1f63d91277a199ebea Mon Sep 17 00:00:00 2001 From: fxcoudert Date: Wed, 15 Aug 2007 12:39:18 +0000 Subject: [PATCH] PR fortran/29459 * trans.c (gfc_create_var_np): Do not emit warnings for anonymous variables. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@127513 138bc75d-0d04-0410-961f-82ee72b054a4 --- gcc/fortran/ChangeLog | 6 ++++++ gcc/fortran/trans.c | 10 +++++++++- 2 files changed, 15 insertions(+), 1 deletion(-) diff --git a/gcc/fortran/ChangeLog b/gcc/fortran/ChangeLog index e43870d..f9c4dd4 100644 --- a/gcc/fortran/ChangeLog +++ b/gcc/fortran/ChangeLog @@ -1,5 +1,11 @@ 2007-08-15 Francois-Xavier Coudert + PR fortran/29459 + * trans.c (gfc_create_var_np): Do not emit warnings for + anonymous variables. + +2007-08-15 Francois-Xavier Coudert + PR fortran/33066 * decl.c (gfc_get_type_attr_spec): Fix whitespace. (gfc_match_derived_decl): Fix logic. diff --git a/gcc/fortran/trans.c b/gcc/fortran/trans.c index 79112e5..7092ac8 100644 --- a/gcc/fortran/trans.c +++ b/gcc/fortran/trans.c @@ -102,7 +102,15 @@ remove_suffix (char *name, int len) tree gfc_create_var_np (tree type, const char *prefix) { - return create_tmp_var_raw (type, prefix); + tree t; + + t = create_tmp_var_raw (type, prefix); + + /* No warnings for anonymous variables. */ + if (prefix == NULL) + TREE_NO_WARNING (t) = 1; + + return t; } -- 2.7.4