This gives us more meaningful information when
getAbbreviationDeclarationSet fails. Right now only
verifyAbbrevSection actually uses the error that it returns, but the
other call sites could be rewritten to take advantage of the returned error.
Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
llvm/lib/DebugInfo/DWARF/DWARFDebugAbbrev.cpp | ||
---|---|---|
167 | Not sure why you've added the parentheses? Oh, I see they're there in the other return clauses in this method - but they're unnecessary there too, and should probably be removed to avoid confusion. | |
llvm/lib/DebugInfo/DWARF/DWARFVerifier.cpp | ||
157 | Comment? I'm not too familiar with the verifier, but it seems to me that if there's an error parsing the abbrevs, we should report it as a verification failure, including the error's message, rather than throwing away that message. Of course, that isn't part of this patch, hence a FIXME comment would probably be appropriate. |
llvm/lib/DebugInfo/DWARF/DWARFDebugAbbrev.cpp | ||
---|---|---|
162 | no need for std::move here, I think? (implicit move from a local variable when you return local) |
llvm/lib/DebugInfo/DWARF/DWARFDebugAbbrev.cpp | ||
---|---|---|
162 | Last time I did that, some older compilers on some buildbots didn't like it. I added the std::move to be explicit. |
LGTM!
llvm/lib/DebugInfo/DWARF/DWARFDebugAbbrev.cpp | ||
---|---|---|
162 | The move is required because the return type is Expected so, without the move, we are calling the constructor of Expected with an Error &, and this ctor doesn't exist. We need an Error && for the right ctor to be found | |
llvm/test/tools/llvm-dwarfdump/X86/empty-CU.s | ||
22 | Out of curiosity, do you know what EOM stands for? End of <something>? End <something> Marker? |
Thanks all!
llvm/test/tools/llvm-dwarfdump/X86/empty-CU.s | ||
---|---|---|
22 | I don't know for sure, but I assume it means "End Of" Marker. |
no need for std::move here, I think? (implicit move from a local variable when you return local)