https://gcc.gnu.org/bugzilla/show_bug.cgi?id=117791
--- Comment #9 from GCC Commits <cvs-commit at gcc dot gnu.org> --- The master branch has been updated by Harald Anlauf <anl...@gcc.gnu.org>: https://gcc.gnu.org/g:2261a15c0715cbf5c129b66ee44fc1d3a9e36972 commit r15-5766-g2261a15c0715cbf5c129b66ee44fc1d3a9e36972 Author: Harald Anlauf <anl...@gmx.de> Date: Wed Nov 27 21:11:16 2024 +0100 Fortran: fix crash with bounds check writing array section [PR117791] PR fortran/117791 gcc/fortran/ChangeLog: * trans-io.cc (gfc_trans_transfer): When an array index depends on a function evaluation or an expression, do not use optimized array I/O of an array section and fall back to normal scalarization. gcc/testsuite/ChangeLog: * gfortran.dg/bounds_check_array_io.f90: New test.