This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug fortran/33544] [4.3 only] Warning in TRANSFER intrinsic should be made optional
- From: "jvdelisle at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 19 Oct 2007 04:58:44 -0000
- Subject: [Bug fortran/33544] [4.3 only] Warning in TRANSFER intrinsic should be made optional
- References: <bug-33544-14284@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #10 from jvdelisle at gcc dot gnu dot org 2007-10-19 04:58 -------
This does the trick. I am checking the testsuite for any side effects.
Index: simplify.c
===================================================================
--- simplify.c (revision 129465)
+++ simplify.c (working copy)
@@ -4065,7 +4065,7 @@ gfc_simplify_transfer (gfc_expr *source,
result_size = result_elt_size;
}
- if (source_size < result_size)
+ if (gfc_option.warn_surprising && source_size < result_size)
gfc_warning("Intrinsic TRANSFER at %L has partly undefined result: "
"source size %ld < result size %ld", &source->where,
(long) source_size, (long) result_size);
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=33544