[PATCH] D49964: [DWARF] Refactor DWARF classes to use unified error reporting. NFC.
Victor Leschuk via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Sat Jul 28 23:04:10 PDT 2018
vleschuk created this revision.
vleschuk added reviewers: aprantl, dblaikie, probinson.
vleschuk added a project: debug-info.
Herald added a subscriber: JDevlieghere.
DWARF-related classes in lib/DebugInfo/DWARF contained duplicating code for creating StringError instances, like:
template <typename... Ts>
static Error createError(char const *Fmt, const Ts &... Vals) {
std::string Buffer;
raw_string_ostream Stream(Buffer);
Stream << format(Fmt, Vals...);
return make_error<StringError>(Stream.str(), inconvertibleErrorCode());
}
Similar function was placed in Support lib in https://reviews.llvm.org/D49824 .
This revision makes DWARF classes use this function instead of their local implementation of it.
Repository:
rL LLVM
https://reviews.llvm.org/D49964
Files:
include/llvm/DebugInfo/DWARF/DWARFListTable.h
lib/DebugInfo/DWARF/DWARFAcceleratorTable.cpp
lib/DebugInfo/DWARF/DWARFContext.cpp
lib/DebugInfo/DWARF/DWARFDebugFrame.cpp
lib/DebugInfo/DWARF/DWARFDebugLine.cpp
lib/DebugInfo/DWARF/DWARFDebugRangeList.cpp
lib/DebugInfo/DWARF/DWARFDebugRnglists.cpp
lib/DebugInfo/DWARF/DWARFListTable.cpp
lib/DebugInfo/DWARF/DWARFUnit.cpp
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D49964.157883.patch
Type: text/x-patch
Size: 28449 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20180729/6a8e8c61/attachment.bin>
More information about the llvm-commits
mailing list