[Bug fortran/54301] Add optional warning if pointer assigning a local variable to a nonlocal pointer
tkoenig at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Sun Aug 19 17:10:00 GMT 2012
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54301
Thomas Koenig <tkoenig at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Last reconfirmed| |2012-08-19
Ever Confirmed|0 |1
--- Comment #4 from Thomas Koenig <tkoenig at gcc dot gnu.org> 2012-08-19 17:10:28 UTC ---
(In reply to comment #3)
> Given the potential badness, I still think one should warn for (a) to (d).
> Though, one probably should think of not warning if the target has the SAVE
> attribute.
If the target has the SAVE attribute or is allocatable, we shouldn't warn.
> The other question is whether the warning should be enabled by -Wall or not. (I
> would enable it with -Wall.)
At least. Because the behavior is very likely to lead to difficult to
detect bugs, I would even consider warning by default.
More information about the Gcc-bugs
mailing list