https://gcc.gnu.org/bugzilla/show_bug.cgi?id=94030
--- Comment #6 from CVS Commits <cvs-commit at gcc dot gnu.org> --- The releases/gcc-9 branch has been updated by Mark Eggleston <markeggles...@gcc.gnu.org>: https://gcc.gnu.org/g:514bd32c5273b1b6c3438016faf96ffdd45639ca commit r9-8440-g514bd32c5273b1b6c3438016faf96ffdd45639ca Author: Mark Eggleston <markeggles...@gcc.gnu.org> Date: Thu Apr 2 08:26:34 2020 +0100 fortran: ICE equivalence with an element of an array PR94030 Deferred size arrays can not be used in equivalance statements. gcc/fortran/ChangeLog: Backport from master 2020-04-02 Mark Eggleston <markeggles...@gcc.gnu.org> PR fortran/94030 * resolve.c (resolve_equivalence): Correct formatting around the label "identical_types". Instead of using gfc_resolve_array_spec use is_non_constants_shape_array to determine whether the array can be used in a in an equivalence statement. gcc/testsuite/ChangeLog: Backport from master 2020-04-02 Mark Eggleston <markeggles...@gcc.gnu.org> PR fortran/94030 * gfortran.dg/pr94030_1.f90 * gfortran.dg/pr94030_2.f90