diff --git a/src/common/rendering/stb_include.cpp b/src/common/rendering/stb_include.cpp index 8e5f7a595..97e846d3b 100644 --- a/src/common/rendering/stb_include.cpp +++ b/src/common/rendering/stb_include.cpp @@ -174,7 +174,7 @@ FString stb_include_string(FString str, FString filename, TArray &filen filenames.Push(filename); size_t curIndex = filenames.Size(); - text.AppendFormat("#line 1 %d // %s\n", curIndex, filename.GetChars()); + text.AppendFormat("\n#line 1 %d // %s\n", curIndex, filename.GetChars()); for (int64_t i = 0; i < num; ++i) { @@ -187,7 +187,7 @@ FString stb_include_string(FString str, FString filename, TArray &filen } text += inc; - text.AppendFormat("#line %d %d // %s\n", inc_list[i].next_line_after, curIndex, filename.GetChars()); + text.AppendFormat("\n#line %d %d // %s\n", inc_list[i].next_line_after, curIndex, filename.GetChars()); // no newlines, because we kept the #include newlines, which will get appended next last = inc_list[i].end; }