This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug fortran/51589] Modification of loop index variable by intent(out) or intent(inout) procedures
- From: "anlauf at gmx dot de" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Fri, 16 Dec 2011 22:55:06 +0000
- Subject: [Bug fortran/51589] Modification of loop index variable by intent(out) or intent(inout) procedures
- Auto-submitted: auto-generated
- References: <bug-51589-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51589
Harald Anlauf <anlauf at gmx dot de> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |anlauf at gmx dot de
--- Comment #3 from Harald Anlauf <anlauf at gmx dot de> 2011-12-16 22:55:06 UTC ---
(In reply to comment #2)
> No error messages from Absoft (v9), g95, or PGI (v11.10). All print the
> revised version of i, but only perform 10 iterations.
>
> NAG (5.2 edit 721) considers the intent(out) to be an error. No warning for
> the intent(inout).
Current trunk (4.7) and also 4.6.0 both give an error at runtime
when compiling with "-fcheck=all" :
42
11
At line 6 of file pr51589.f90
Fortran runtime error: Loop variable has been modified