[Lldb-commits] [PATCH] D62211: Simplify `GetName`+`AppendTypeName` by `DWARFDIE`

Jonas Devlieghere via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Wed May 22 16:47:13 PDT 2019


JDevlieghere added inline comments.


================
Comment at: lldb/source/Plugins/SymbolFile/DWARF/DWARFDebugInfoEntry.cpp:1073
+bool DWARFDebugInfoEntry::AppendTypeName(const DWARFDIE die, Stream &s) {
+  if (die) {
+    if (die.GetDIE()->IsNULL()) {
----------------
jankratochvil wrote:
> JDevlieghere wrote:
> > How about turning this into an early return?
> This deep nesting is a general coding style in LLDB so I try to keep it.  Yes, I would like to (and I use elsewhere) early returns to keep the nesting low. I will submit another patch for it when you say it is OK to clean it up.
The deep nesting is definitely a bug and not a feature. We've been removing it where it makes sense. 


Repository:
  rLLDB LLDB

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D62211/new/

https://reviews.llvm.org/D62211





More information about the lldb-commits mailing list