[llvm] ddf79de - [Asan] Fix -Wunused-private-field in non-assertion builds (NFC)
Jie Fu via llvm-commits
llvm-commits at lists.llvm.org
Thu Mar 7 15:43:10 PST 2024
Author: Jie Fu
Date: 2024-03-08T07:42:01+08:00
New Revision: ddf79deb42d901fbb732e56464efbf93bc444070
URL: https://github.com/llvm/llvm-project/commit/ddf79deb42d901fbb732e56464efbf93bc444070
DIFF: https://github.com/llvm/llvm-project/commit/ddf79deb42d901fbb732e56464efbf93bc444070.diff
LOG: [Asan] Fix -Wunused-private-field in non-assertion builds (NFC)
llvm-project/llvm/lib/Transforms/Instrumentation/AddressSanitizer.cpp:650:13:
error: private field 'OwnerFn' is not used [-Werror,-Wunused-private-field]
Function *OwnerFn = nullptr;
^
1 error generated.
Added:
Modified:
llvm/lib/Transforms/Instrumentation/AddressSanitizer.cpp
Removed:
################################################################################
diff --git a/llvm/lib/Transforms/Instrumentation/AddressSanitizer.cpp b/llvm/lib/Transforms/Instrumentation/AddressSanitizer.cpp
index c95a50a033b1b2..db75eec21a3745 100644
--- a/llvm/lib/Transforms/Instrumentation/AddressSanitizer.cpp
+++ b/llvm/lib/Transforms/Instrumentation/AddressSanitizer.cpp
@@ -656,6 +656,7 @@ class RuntimeCallInserter {
ArrayRef<Value *> Args = {},
const Twine &Name = "") {
assert(IRB.GetInsertBlock()->getParent() == OwnerFn);
+ (void)OwnerFn;
return IRB.CreateCall(Callee, Args, Name, nullptr);
}
};
More information about the llvm-commits
mailing list