[llvm-branch-commits] [lld] 7916fd7 - [lld-macho] Fix GCC -Wunused-variable in -DLLVM_ENABLE_ASSERTIONS=off build
Fangrui Song via llvm-branch-commits
llvm-branch-commits at lists.llvm.org
Wed Jan 6 11:03:49 PST 2021
Author: Fangrui Song
Date: 2021-01-06T10:58:46-08:00
New Revision: 7916fd71e9431829b22aed77711e11ea1dc225e3
URL: https://github.com/llvm/llvm-project/commit/7916fd71e9431829b22aed77711e11ea1dc225e3
DIFF: https://github.com/llvm/llvm-project/commit/7916fd71e9431829b22aed77711e11ea1dc225e3.diff
LOG: [lld-macho] Fix GCC -Wunused-variable in -DLLVM_ENABLE_ASSERTIONS=off build
Added:
Modified:
lld/MachO/SyntheticSections.cpp
Removed:
################################################################################
diff --git a/lld/MachO/SyntheticSections.cpp b/lld/MachO/SyntheticSections.cpp
index 2ed1f2eb34fb..3f5413696d4b 100644
--- a/lld/MachO/SyntheticSections.cpp
+++ b/lld/MachO/SyntheticSections.cpp
@@ -722,6 +722,7 @@ void SymtabSection::finalizeContents() {
for (Symbol *sym : symtab->getSymbols()) {
if (auto *defined = dyn_cast<Defined>(sym)) {
assert(defined->isExternal());
+ (void)defined;
addSymbol(externalSymbols, sym);
} else if (auto *dysym = dyn_cast<DylibSymbol>(sym)) {
if (dysym->isReferenced())
More information about the llvm-branch-commits
mailing list