[PATCH] D98994: NFC. Refactored DIPrinter for better support of new print styles.

Alex Orlov via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sat Apr 3 13:08:33 PDT 2021


aorlov marked 3 inline comments as done.
aorlov added inline comments.


================
Comment at: llvm/include/llvm/DebugInfo/Symbolize/DIPrinter.h:34-35
+  uint64_t Address = 0;
+  Request(StringRef ModuleName, uint64_t Address)
+      : ModuleName(ModuleName), Address(Address){};
+};
----------------
dblaikie wrote:
> I probably wouldn't bother with a ctor here - uses can use braced init to construct it with a similar amount of syntax.
I have removed any streams from DIPrinter. Now it is a clean interface.
Note we don't need stderr in JSONPrinter. 
And any other printer might not use the stdout and/or stderr at all.
But I kept OS and ES in PlainPrinterBase ctor. 
I don't see how to gracefully use braced init of PlainPrinterBase.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D98994/new/

https://reviews.llvm.org/D98994



More information about the llvm-commits mailing list