https://gcc.gnu.org/bugzilla/show_bug.cgi?id=120812
Bug ID: 120812 Summary: [regression] buffer(80:80) = C_NEW_LINE not working with gfortran 15.1 under Mac Product: gcc Version: 15.1.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: fortran Assignee: unassigned at gcc dot gnu.org Reporter: christophe.peyret at onera dot fr Target Milestone: --- Created attachment 61702 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=61702&action=edit buffer(80:80) = C_NEW_LINE not working Hello, I face a problem with gfortran 15.1 on my Mac Intel and Mac Apple Silicon (that didn't exist with gfortran 14) I declare : character(len=:), pointer :: buffer=>null() allocate( character(len=80) :: buffer ) when I enter : buffer(80:80) = C_NEW_LINE the C_NEW_LINE is inserted at buffer(1:1). If I want it to work I need to enter: buffer(1:80) = buffer(1:79) // C_NEW_LINE I join a small example that reproduces the problem Sincerely Christophe