https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104908

--- Comment #12 from GCC Commits <cvs-commit at gcc dot gnu.org> ---
The releases/gcc-11 branch has been updated by Harald Anlauf
<anl...@gcc.gnu.org>:

https://gcc.gnu.org/g:07b575d5860dbc8791dbb9d10af9f918f34d7ff0

commit r11-11231-g07b575d5860dbc8791dbb9d10af9f918f34d7ff0
Author: Harald Anlauf <anl...@gmx.de>
Date:   Sat Jan 27 17:41:43 2024 +0100

    Fortran: fix bounds-checking errors for CLASS array dummies [PR104908]

    Commit r11-1235 addressed issues with bounds of unlimited polymorphic array
    dummies.  However, using the descriptor from sym->backend_decl does break
    the case of CLASS array dummies.  The obvious solution is to restrict the
    fix to the unlimited polymorphic case, thus keeping the original descriptor
    in the ordinary case.

    gcc/fortran/ChangeLog:

            PR fortran/104908
            * trans-array.c (gfc_conv_array_ref): Restrict use of transformed
            descriptor (sym->backend_decl) to the unlimited polymorphic case.

    gcc/testsuite/ChangeLog:

            PR fortran/104908
            * gfortran.dg/pr104908.f90: New test.

    (cherry picked from commit ce61de1b8a1bb3a22118e900376f380768f2ba59)

Reply via email to