https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66227
--- Comment #6 from janus at gcc dot gnu.org --- (In reply to janus from comment #5) > I'm currently not sure which one it is, but I'll investigate. I think it's both ;) extends_type_of_3.f90 is definitely wrong, because it contains the exact case reported in this PR. This fixes it: Index: gcc/testsuite/gfortran.dg/extends_type_of_3.f90 =================================================================== --- gcc/testsuite/gfortran.dg/extends_type_of_3.f90 (Revision 242412) +++ gcc/testsuite/gfortran.dg/extends_type_of_3.f90 (Arbeitskopie) @@ -83,7 +83,6 @@ if (extends_type_of(b1,a1) .neqv. .true.) call should_not_exist() if (extends_type_of(b11,a1) .neqv. .true.) call should_not_exist() if (extends_type_of(b11,a11) .neqv. .true.) call should_not_exist() -if (extends_type_of(b1,a11) .neqv. .false.) call should_not_exist() if (extends_type_of(a1,b11) .neqv. .false.) call abort()