[PATCH] D30357: [ObjectYAML] NFC. Refactor DWARFYAML CompileUnit dump code

Adrian Prantl via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Mar 2 14:00:28 PST 2017


aprantl added a comment.

Few more inline comments, feel free to commit whenever ready.



================
Comment at: lib/ObjectYAML/DWARFVisitor.cpp:38
+template <typename T>
+size_t DWARFYAML::VisitorImpl<T>::GetRefSize(const DWARFYAML::Unit &Unit) {
+  if (Unit.Version == 2)
----------------
we probably want a target-independent type like uint64_t here?

why not make this static uint64_t getRefSize(DebugInfo, Unit) instead?


================
Comment at: lib/ObjectYAML/DWARFVisitor.h:29
+
+template <typename T> class VisitorImpl {
+protected:
----------------
We should also add a Doxygen comment here to explaining what this is.


https://reviews.llvm.org/D30357





More information about the llvm-commits mailing list