Index: flang/runtime/namelist.cpp =================================================================== --- flang/runtime/namelist.cpp +++ flang/runtime/namelist.cpp @@ -263,6 +263,7 @@ auto *listInput{io.get_if>()}; RUNTIME_CHECK(handler, listInput != nullptr); // Check the group header + io.BeginReadingRecord(); std::optional next{io.GetNextNonBlank()}; if (!next || *next != '&') { handler.SignalError(