This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug fortran/36751] assignment between allocatable arrays of different size causes glibc error
- From: "tkoenig at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 9 Jul 2008 15:31:13 -0000
- Subject: [Bug fortran/36751] assignment between allocatable arrays of different size causes glibc error
- References: <bug-36751-14147@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #3 from tkoenig at gcc dot gnu dot org 2008-07-09 15:31 -------
(In reply to comment #2)
> I am not sure the code is valid.
It's not, as -fbounds-check will tell you:
$ gfortran -fbounds-check foo.f90
$ ./a.out
At line 15 of file foo.f90
Fortran runtime error: Array bound mismatch, size mismatch for dimension 2 of
array 'a2' (1/2)
You need -fbounds-check for this to be detected. As this
test is only possible at run-time, checking in the absence
of -fbounds-check isn't done.
Closing.
--
tkoenig at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |RESOLVED
Resolution| |INVALID
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36751