https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70231
--- Comment #5 from CVS 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:15acabb80f91b12836bcf4ffcb92ea10fe4e8272 commit r14-4147-g15acabb80f91b12836bcf4ffcb92ea10fe4e8272 Author: Harald Anlauf <anl...@gmx.de> Date: Mon Sep 18 22:11:40 2023 +0200 fortran: fix checking of CHARACTER lengths in array constructors [PR70231] gcc/fortran/ChangeLog: PR fortran/70231 * trans-array.cc (trans_array_constructor): In absence of a typespec, use string length determined by get_array_ctor_strlen() to reasonably initialize auxiliary variable for bounds-checking. gcc/testsuite/ChangeLog: PR fortran/70231 * gfortran.dg/bounds_check_fail_7.f90: New test.