diff options
author | Georgii Rymar <grimar@accesssoftek.com> | 2020-11-27 13:34:30 +0300 |
---|---|---|
committer | Georgii Rymar <grimar@accesssoftek.com> | 2020-12-01 10:53:00 +0300 |
commit | 31eeac915a0a25c2690b956931c77684bc34da0b (patch) | |
tree | 055a6bf1aed2e5056f79e250bbe469926245e7cb /clang/lib/Frontend/CompilerInvocation.cpp | |
parent | e785379afff8dc256fc72a0f74677b43defa2059 (diff) | |
download | llvm-31eeac915a0a25c2690b956931c77684bc34da0b.zip llvm-31eeac915a0a25c2690b956931c77684bc34da0b.tar.gz llvm-31eeac915a0a25c2690b956931c77684bc34da0b.tar.bz2 |
[llvm-readelf/obj] - Move unique warning handling logic to the `ObjDumper`.
This moves the `reportUniqueWarning` method to the base class.
My motivation is the following:
I've experimented with replacing `reportWarning` calls with `reportUniqueWarning`
in ELF dumper. I've found that for example for removing them from `DynRegionInfo` helper
class, it is worth to pass a dumper instance to it (to be able to call dumper()->reportUniqueWarning()).
The problem was that `ELFDumper<ELFT>` is a template class. I had to make `DynRegionInfo` to be templated
and do lots of minor changes everywhere what did not look reasonable/nice.
At the same time I guess one day other dumpers like COFF/MachO/Wasm etc might want to
start using `reportUniqueWarning` API too. Then it looks reasonable to move the logic to the
base class.
With that the problem of passing the dumper instance will be gone.
Differential revision: https://reviews.llvm.org/D92218
Diffstat (limited to 'clang/lib/Frontend/CompilerInvocation.cpp')
0 files changed, 0 insertions, 0 deletions