This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug fortran/50619] Surprising interaction between -finit-real=NAN and the associate construct
- From: "burnus at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Mon, 04 Jun 2012 12:32:20 +0000
- Subject: [Bug fortran/50619] Surprising interaction between -finit-real=NAN and the associate construct
- Auto-submitted: auto-generated
- References: <bug-50619-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=50619
--- Comment #4 from Tobias Burnus <burnus at gcc dot gnu.org> 2012-06-04 12:32:20 UTC ---
(In reply to comment #3)
> I can confirm this behaviour in gcc-4.6.2, 4.7.0, and 4.8.0 (20120530)
> development version. Since this renders -finit-real=NAN unusable for me, I
> would consider this a serious bug.
I concur that it is a bad wrong-code bug, but it only occurs with the
nondefault flag -finit-real=* - and it is not a regression -, thus, I think it
is bad but not serious.
Unfortunately, the number of active gfortran developers is not that high, which
in turn means that bugs aren't fixed and features not implemented as quickly as
everyone would like. (Note: 99% of the Fortran-frontend development is done in
the spare time!) Thus, if you are interested in contributing to gfortran - or
if you know someone who is ...
* * *
Regarding this bugreport: I think the following patch should fix it. I will
test it and submit it.
--- a/gcc/fortran/resolve.c
+++ b/gcc/fortran/resolve.c
@@ -10105,3 +10105,4 @@ build_default_init_expr (gfc_symbol *sym)
|| sym->attr.cray_pointee
- || sym->attr.cray_pointer)
+ || sym->attr.cray_pointer
+ || sym->assoc)
return NULL;