Dear all, said PR was addressed by Jose in https://gcc.gnu.org/pipermail/fortran/2021-April/055949.html but unfortunately his patch was never reviewed. IMHO the patch is mostly fine, with one small exception that it should use POINTER_TYPE_P (TREE_TYPE (tmp)), see PR and attached adjusted patch. Regtested on x86_64-pc-linux-gnu. Since this fixes a 11/12/13 regression on valid code, I'd like to commit this one on these branches, but would be glad to see an OK or LGTM from somebody else. (Jose says he's too busy currently.) Thanks, Harald