https://gcc.gnu.org/bugzilla/show_bug.cgi?id=89077
Harald Anlauf <anlauf at gmx dot de> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |anlauf at gmx dot de --- Comment #4 from Harald Anlauf <anlauf at gmx dot de> --- Replacing character(*), parameter :: str2 = transfer([(str(i:i), i=1,len(str))], str) by character, parameter :: str2a(*) = [(str(i:i), i=1,len(str))] character(*), parameter :: str2 = transfer(str2a, str) 'solves' the issue. I think there are close (code-wise) duplicates to this issue, where some information of an array constructor is lost in constant expressions.