]> git.ipfire.org Git - thirdparty/gcc.git/commit
Fortran: fix bogus bounds check for reallocation on assignment [PR116706]
authorHarald Anlauf <anlauf@gmx.de>
Wed, 19 Mar 2025 21:56:03 +0000 (22:56 +0100)
committerHarald Anlauf <anlauf@gmx.de>
Tue, 25 Mar 2025 21:14:39 +0000 (22:14 +0100)
commitde9500d93eed789bf7bc4a82b522edb6dd2b6202
tree1fad519b430effb2c48a8a2995fded3189d93ccc
parent82bd83122a483275787fcd18131bf6cd91fbdbd4
Fortran: fix bogus bounds check for reallocation on assignment [PR116706]

PR fortran/116706

gcc/fortran/ChangeLog:

* trans-array.cc (gfc_is_reallocatable_lhs): Fix check on
allocatable components of derived type or class objects.

gcc/testsuite/ChangeLog:

* gfortran.dg/bounds_check_27.f90: New test.

(cherry picked from commit 3292ca9b0818c3e55102413c2407711d0755d280)
gcc/fortran/trans-array.cc
gcc/testsuite/gfortran.dg/bounds_check_27.f90 [new file with mode: 0644]