[PATCH] D64407: [DWARF] Simplify constructing of DWARFAttribute. NFC.

Igor Kudrin via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Jul 9 07:04:17 PDT 2019


ikudrin added inline comments.


================
Comment at: lib/DebugInfo/DWARF/DWARFDie.cpp:666
 DWARFDie::attribute_iterator::attribute_iterator(DWARFDie D, bool End)
-    : Die(D), AttrValue(0), Index(0) {
+    : Die(D), AttrValue(), Index(0) {
   auto AbbrDecl = Die.getAbbreviationDeclarationPtr();
----------------
Eugene.Zelenko wrote:
> You don't need to call default member constructor explicitly. Default member initialization could be used for Index too.
The main intent here was to remove the first unused argument in the constructor of `DWARFAttribute` because it is a bit of misleading. And other changes in that class were done because there was no reason not to do them when I was there.
As for `Index`, I believe it is out of the scope of this patch because it is a member of a different class.


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

https://reviews.llvm.org/D64407





More information about the llvm-commits mailing list