https://gcc.gnu.org/bugzilla/show_bug.cgi?id=89925
anlauf at gcc dot gnu.org changed: What |Removed |Added ---------------------------------------------------------------------------- Resolution|--- |FIXED Status|WAITING |RESOLVED --- Comment #17 from anlauf at gcc dot gnu.org --- Backported as r11-11310-gb755a7af1f2ef1: commit b755a7af1f2ef1f5348d04db20f751e898abcd9d Author: Chung-Lin Tang <clt...@codesourcery.com> Date: Fri Dec 3 17:27:17 2021 +0800 fortran: Fix setting of array lower bound for named arrays This patch fixes a case of setting array low-bounds, found for particular uses of SOURCE=/MOLD=. This adjusts the relevant part in gfc_trans_allocate() to set e3_has_nodescriptor only for non-named arrays. 2021-12-03 Tobias Burnus <tob...@codesourcery.com> gcc/fortran/ChangeLog: * trans-stmt.c (gfc_trans_allocate): Set e3_has_nodescriptor to true only for non-named arrays. gcc/testsuite/ChangeLog: * gfortran.dg/allocate_with_source_26.f90: Adjust testcase. * gfortran.dg/allocate_with_mold_4.f90: New testcase. (cherry picked from commit 6262e3a22b3d86afc116480bc59a7bb30b0cfd40) Closing.