https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106856
--- Comment #4 from anlauf at gcc dot gnu.org --- Created attachment 54567 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=54567&action=edit Updated patch The original patches started to bit-rot, so here is an updated version. The current situation is as follows: - it fixes a couple of ice-on-valid, ice-on-invalid, rejects-valid cases, see below - testcase interface_41.f90 turns out to be actually valid Fortran and is now correctly accepted (-> testsuite needs adjustment) - testcase pr69398.f90 ICE's - as expected, see comment in new testcase class_75.f90. Shall we mark this one as XFAIL for the time being and reopen pr69398? - it appears that the following PRs are addressed or fixed with this patch: pr53951, pr101101, pr104229, pr107380 So applying the patch would be a big achievement over the current situation. @Thomas: do you think this path should/could be followed?