Simplify zero initialization of DIEAttrs variable.
authorDavid Blaikie <dblaikie@gmail.com>
Wed, 16 Oct 2013 00:47:21 +0000 (00:47 +0000)
committerDavid Blaikie <dblaikie@gmail.com>
Wed, 16 Oct 2013 00:47:21 +0000 (00:47 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192755 91177308-0d34-0410-b5e6-96231b3b80d8

lib/CodeGen/AsmPrinter/DIEHash.cpp

index 519c8a0068586359d19d60cbc6cc29735ce1c470..c56d2e64730841d00f8af2fca77dbb4d3e99a923 100644 (file)
@@ -361,8 +361,7 @@ void DIEHash::hashAttributes(const DIEAttrs &Attrs) {
 
 // Add all of the attributes for \param Die to the hash.
 void DIEHash::addAttributes(DIE *Die) {
-  DIEAttrs Attrs;
-  memset(&Attrs, 0, sizeof(Attrs));
+  DIEAttrs Attrs = {};
   collectAttributes(Die, Attrs);
   hashAttributes(Attrs);
 }