[llvm-branch-commits] [lld] [LLD][ELF] Add missing initialization of Symbol `used` member. (PR #202578)
Andrew Ng via llvm-branch-commits
llvm-branch-commits at lists.llvm.org
Tue Jun 9 04:06:46 PDT 2026
https://github.com/nga888 created https://github.com/llvm/llvm-project/pull/202578
On the "main" branch, Symbol no longer has the `used` member. Therefore, when PR #198129 (commit 905a88b9) was cherry picked to the "release/22.x" branch, the initialization of `used` was lost.
>From e1751aadfca48bd9ca8657e3c02a28d958a27b74 Mon Sep 17 00:00:00 2001
From: Andrew Ng <andrew.ng at sony.com>
Date: Tue, 9 Jun 2026 11:55:05 +0100
Subject: [PATCH] [LLD][ELF] Add missing initialization of Symbol `used`
member.
On the "main" branch, Symbol no longer has the `used` member. Therefore,
when PR #198129 (commit 905a88b9) was cherry picked to the
"release/22.x" branch, the initialization of `used` was lost.
---
lld/ELF/Symbols.h | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
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