diff options
author | James Henderson <jh7370@my.bristol.ac.uk> | 2019-12-17 12:02:54 +0000 |
---|---|---|
committer | James Henderson <jh7370@my.bristol.ac.uk> | 2019-12-17 12:04:09 +0000 |
commit | 5666b70fd0748765ecaa69950a4868cf23a16cc9 (patch) | |
tree | 5d81a48bd5a197c1d04a03deb1133efe6f4be704 /llvm/lib/DebugInfo | |
parent | 67ce7f51a50f5fb4633fcdc0e80038d1f63a40f3 (diff) | |
download | bcm5719-llvm-5666b70fd0748765ecaa69950a4868cf23a16cc9.tar.gz bcm5719-llvm-5666b70fd0748765ecaa69950a4868cf23a16cc9.zip |
[DebugInfo] Only print a single blank line after an empty line table
Commit 84a9756 added an extra blank line at the end of any line table.
However, a blank line is also printed after the line table header, which
meant that two blank lines in a row were being printed after a header,
if there were no rows. This patch defers the post-header blank line
printing until it has been determined that there are rows to print.
Reviewed by: dblaikie
Differential Revision: https://reviews.llvm.org/D71540
Diffstat (limited to 'llvm/lib/DebugInfo')
-rw-r--r-- | llvm/lib/DebugInfo/DWARF/DWARFDebugLine.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/DebugInfo/DWARF/DWARFDebugLine.cpp b/llvm/lib/DebugInfo/DWARF/DWARFDebugLine.cpp index 445f4bf48a7..f5b1c40024d 100644 --- a/llvm/lib/DebugInfo/DWARF/DWARFDebugLine.cpp +++ b/llvm/lib/DebugInfo/DWARF/DWARFDebugLine.cpp @@ -453,9 +453,9 @@ DWARFDebugLine::LineTable::LineTable() { clear(); } void DWARFDebugLine::LineTable::dump(raw_ostream &OS, DIDumpOptions DumpOptions) const { Prologue.dump(OS, DumpOptions); - OS << '\n'; if (!Rows.empty()) { + OS << '\n'; Row::dumpTableHeader(OS); for (const Row &R : Rows) { R.dump(OS); |