[Lldb-commits] [PATCH] D63591: DWARFDebugLoc: Make parsing and error reporting more robust
Paul Robinson via Phabricator via lldb-commits
lldb-commits at lists.llvm.org
Thu Jun 20 13:42:09 PDT 2019
probinson added inline comments.
================
Comment at: lib/DebugInfo/DWARF/DWARFDebugLoc.cpp:220
}
- return LL;
+ llvm_unreachable("Exit from function inside while loop!");
}
----------------
dblaikie wrote:
> Given the loop condition is "while (true)" this unreachable seems a bit unnecessary (& the function has non-void return, so if there was a path that got through the loop I imagine the compiler would warn us about that?)
>
> Or is this working around a compiler that warns here despite the lack of any path out of the loop?
I have had to add llvm_unreachable before in this kind of situation, IIRC, which is why I suggested it. Might not be necessary, if all 3 supported toolchains are smart enough nowadays.
Repository:
rL LLVM
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D63591/new/
https://reviews.llvm.org/D63591
More information about the lldb-commits
mailing list