[PATCH] D51081: [DWARF v5] Refactoring range list dumping to fold DWARF v4 functionality into v5 handling (almost NFC).

David Blaikie via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Aug 22 16:18:52 PDT 2018


dblaikie added inline comments.


================
Comment at: include/llvm/DebugInfo/DWARF/DWARFListTable.h:52
+  bool empty() const {
+    return Entries.empty() || Entries.begin()->isEndOfList();
+  }
----------------
probinson wrote:
> dblaikie wrote:
> > Why this new special case - when would the range list contain an empty range?
> It's explicitly legal to have a list that consists solely of the end-of-list marker.  Not saying any producer would actually emit it this way, but it's one way to describe an empty range.  The parser should handle this case smoothly.
Good point - I guess I could narrow/clarify my comment somewhat: Why is the emptiness of a range list important? I'd figure the printing algorithm would work the same either way.


https://reviews.llvm.org/D51081





More information about the llvm-commits mailing list