https://gcc.gnu.org/bugzilla/show_bug.cgi?id=101334
--- Comment #2 from CVS Commits <cvs-commit at gcc dot gnu.org> --- The master branch has been updated by Tobias Burnus <bur...@gcc.gnu.org>: https://gcc.gnu.org/g:fe2771b291c2c7c0ac37b75ec5b160937524b60c commit r12-3890-gfe2771b291c2c7c0ac37b75ec5b160937524b60c Author: Tobias Burnus <tob...@codesourcery.com> Date: Sun Sep 26 19:26:01 2021 +0200 Fortran: Fix associated intrinsic with assumed rank [PR101334] ASSOCIATE (ptr, tgt) takes as first argument also an assumed-rank array; however, using it together with a tgt (required to be non assumed rank) had issues for both scalar and nonscalar tgt. PR fortran/101334 gcc/fortran/ChangeLog: * trans-intrinsic.c (gfc_conv_associated): Support assumed-rank 'pointer' with scalar/array 'target' argument. libgfortran/ChangeLog: * intrinsics/associated.c (associated): Also check for same rank. gcc/testsuite/ChangeLog: * gfortran.dg/associated_assumed_rank.f90: New test.