[llvm-branch-commits] [lld] 070e505 - [LLD][ELF] Add missing initialization of Symbol `used` member.

Douglas Yung via llvm-branch-commits llvm-branch-commits at lists.llvm.org
Wed Jun 10 10:50:54 PDT 2026


Author: Andrew Ng
Date: 2026-06-10T17:50:22Z
New Revision: 070e505ce21d5bb0aae18704ec3a2660f59b7e3c

URL: https://github.com/llvm/llvm-project/commit/070e505ce21d5bb0aae18704ec3a2660f59b7e3c
DIFF: https://github.com/llvm/llvm-project/commit/070e505ce21d5bb0aae18704ec3a2660f59b7e3c.diff

LOG: [LLD][ELF] Add missing initialization of Symbol `used` member.

On the "main" branch, Symbol no longer has the `used` member which was
moved in PR #190117 (commit 6a874161). Therefore, when the cherry pick
from PR #198129 (commit 905a88b9) was merged to the "release/22.x"
branch, the initialization of `used` was lost.

Added: 
    

Modified: 
    lld/ELF/Symbols.h

Removed: 
    


################################################################################
diff  --git a/lld/ELF/Symbols.h b/lld/ELF/Symbols.h
index 23994ccea1ef0..26d28825558c9 100644
--- a/lld/ELF/Symbols.h
+++ b/lld/ELF/Symbols.h
@@ -243,11 +243,11 @@ class Symbol {
          uint8_t stOther, uint8_t type)
       : file(file), nameData(name.data()), nameSize(name.size()), type(type),
         binding(binding), stOther(stOther), symbolKind(k), isPreemptible(false),
-        isUsedInRegularObj(false), isExported(false), ltoCanOmit(false),
-        traced(false), hasVersionSuffix(false), isInIplt(false),
-        gotInIgot(false), folded(false), archSpecificBit(false),
-        scriptDefined(false), dsoDefined(false), dsoProtected(false),
-        versionScriptAssigned(false), thunkAccessed(false),
+        isUsedInRegularObj(false), used(false), isExported(false),
+        ltoCanOmit(false), traced(false), hasVersionSuffix(false),
+        isInIplt(false), gotInIgot(false), folded(false),
+        archSpecificBit(false), scriptDefined(false), dsoDefined(false),
+        dsoProtected(false), versionScriptAssigned(false), thunkAccessed(false),
         inDynamicList(false), referenced(false), referencedAfterWrap(false) {}
 
   void overwrite(Symbol &sym, Kind k) const {


        


More information about the llvm-branch-commits mailing list