[llvm] 713acbc - [NFC][MC] Initialize all fields of DebugName::Parameters in default constructor (#202701)

via llvm-commits llvm-commits at lists.llvm.org
Sun Jun 14 23:20:35 PDT 2026


Author: Jaydeep Chauhan
Date: 2026-06-15T11:50:30+05:30
New Revision: 713acbccfaf9877af0e57267c29883daeb111e3c

URL: https://github.com/llvm/llvm-project/commit/713acbccfaf9877af0e57267c29883daeb111e3c
DIFF: https://github.com/llvm/llvm-project/commit/713acbccfaf9877af0e57267c29883daeb111e3c.diff

LOG: [NFC][MC] Initialize all fields of DebugName::Parameters in default constructor (#202701)

Initialized both variables **Flags** and **NameLength** of
**DebugNameHeader** structure.

Added: 
    

Modified: 
    llvm/include/llvm/MC/DXContainerInfo.h

Removed: 
    


################################################################################
diff  --git a/llvm/include/llvm/MC/DXContainerInfo.h b/llvm/include/llvm/MC/DXContainerInfo.h
index a730613b07020..3d54840f70594 100644
--- a/llvm/include/llvm/MC/DXContainerInfo.h
+++ b/llvm/include/llvm/MC/DXContainerInfo.h
@@ -22,7 +22,7 @@ struct DebugName {
   dxbc::DebugNameHeader Parameters;
   StringRef Filename;
 
-  DebugName() { Parameters.Flags = 0; }
+  DebugName() : Parameters{0, 0} {}
   DebugName(dxbc::DebugNameHeader &Parameters, StringRef Filename)
       : Parameters(Parameters), Filename(Filename) {}
 


        


More information about the llvm-commits mailing list