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

--- Comment #2 from GCC Commits <cvs-commit at gcc dot gnu.org> ---
The trunk branch has been updated by Mikael Morin <[email protected]>:

https://gcc.gnu.org/g:d745dfbe669d71061dbd5fbb3d5d0dce6432621c

commit r17-4865-gd745dfbe669d71061dbd5fbb3d5d0dce6432621c
Author: Mikael Morin <[email protected]>
Date:   Sun Oct 4 11:25:06 2026 +0200

    fortran: Enforce restrictions on polymorphic volatile array arguments
[PR127682]

    Use CLASS_DATA when querying polymorphic entities.

    The checks of restrictions on volatile or asynchronous actual and dummy
    arrays missed forbidden cases, when the arrays were polymorphic.  Adjust
    them so that the right attributes and fields are checked depending on
    whether the dummy is polymorphic or not.

            PR fortran/127682

    gcc/fortran/ChangeLog:

            * interface.cc (compare_parameter): Update the conditions enforcing
            the restrictions on volatile and asynchronous array arguments so
            that they also work with polymorphic dummy arrays.

    gcc/testsuite/ChangeLog:

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

Reply via email to