[llvm] r351641 - [NFC] Fix unused variable warnings in Release builds
Johannes Doerfert via llvm-commits
llvm-commits at lists.llvm.org
Sat Jan 19 01:39:58 PST 2019
Author: jdoerfert
Date: Sat Jan 19 01:39:57 2019
New Revision: 351641
URL: http://llvm.org/viewvc/llvm-project?rev=351641&view=rev
Log:
[NFC] Fix unused variable warnings in Release builds
Modified:
llvm/trunk/lib/IR/MDBuilder.cpp
Modified: llvm/trunk/lib/IR/MDBuilder.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/IR/MDBuilder.cpp?rev=351641&r1=351640&r2=351641&view=diff
==============================================================================
--- llvm/trunk/lib/IR/MDBuilder.cpp (original)
+++ llvm/trunk/lib/IR/MDBuilder.cpp Sat Jan 19 01:39:57 2019
@@ -131,6 +131,7 @@ MDNode *MDBuilder::mergeCallbackEncoding
auto *NewCBCalleeIdxAsCM = cast<ConstantAsMetadata>(NewCB->getOperand(0));
uint64_t NewCBCalleeIdx =
cast<ConstantInt>(NewCBCalleeIdxAsCM->getValue())->getZExtValue();
+ (void)NewCBCalleeIdx;
SmallVector<Metadata *, 4> Ops;
unsigned NumExistingOps = ExistingCallbacks->getNumOperands();
@@ -142,6 +143,7 @@ MDNode *MDBuilder::mergeCallbackEncoding
auto *OldCBCalleeIdxAsCM = cast<ConstantAsMetadata>(Ops[u]);
uint64_t OldCBCalleeIdx =
cast<ConstantInt>(OldCBCalleeIdxAsCM->getValue())->getZExtValue();
+ (void)OldCBCalleeIdx;
assert(NewCBCalleeIdx != OldCBCalleeIdx &&
"Cannot map a callback callee index twice!");
}
More information about the llvm-commits
mailing list