[Bug fortran/67430] reallocate lhs with overloaded assignment operators causes memory error and wrong size
dominiq at lps dot ens.fr
gcc-bugzilla@gcc.gnu.org
Wed Sep 2 08:51:00 GMT 2015
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=67430
Dominique d'Humieres <dominiq at lps dot ens.fr> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |RESOLVED
Resolution|--- |INVALID
--- Comment #1 from Dominique d'Humieres <dominiq at lps dot ens.fr> ---
The code in comment 0 is invalid: in
A = A(1:2)
you assign two elements to a four element array. If you compile your code with
'-fcheck=all', you get at run time the error
At line 29 of file pr67430.f90
Fortran runtime error: Array bound mismatch for dimension 1 of array 'a' (2/4)
More information about the Gcc-bugs
mailing list