This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug fortran/31725] substring bound evaluated multiple times: wrong code for string(function():) = 'X'
- From: "fxcoudert at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 14 May 2007 19:29:48 -0000
- Subject: [Bug fortran/31725] substring bound evaluated multiple times: wrong code for string(function():) = 'X'
- References: <bug-31725-14459@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #6 from fxcoudert at gcc dot gnu dot org 2007-05-14 20:29 -------
Subject: Bug 31725
Author: fxcoudert
Date: Mon May 14 19:29:33 2007
New Revision: 124720
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=124720
Log:
PR fortran/31725
* trans-expr.c (gfc_conv_substring): Evaluate substring bounds
only once.
* gfortran.dg/substr_4.f: New test.
Added:
trunk/gcc/testsuite/gfortran.dg/substr_4.f
Modified:
trunk/gcc/fortran/ChangeLog
trunk/gcc/fortran/trans-expr.c
trunk/gcc/testsuite/ChangeLog
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31725