[PATCH] D153459: [DebugInfo] Add error handling to DWARFDebugAbbrev::getAbbreviationDeclarationSet
James Henderson via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Jun 21 23:51:45 PDT 2023
jhenderson added inline comments.
================
Comment at: llvm/lib/DebugInfo/DWARF/DWARFDebugAbbrev.cpp:167
+ .first;
+ return &(PrevAbbrOffsetPos->second);
}
----------------
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.
================
Comment at: llvm/lib/DebugInfo/DWARF/DWARFVerifier.cpp:157
ValidAbbrevOffset = false;
+ consumeError(AbbrevSetOrErr.takeError());
+ }
----------------
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.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D153459/new/
https://reviews.llvm.org/D153459
More information about the llvm-commits
mailing list