ValueMapper: Fix unused var warning. NFC

llvm-svn: 266529
This commit is contained in:
Simon Atanasyan 2016-04-16 11:49:40 +00:00
parent b5c0025d1d
commit e12bef7ea7
1 changed files with 2 additions and 0 deletions

View File

@ -505,6 +505,7 @@ bool MDNodeMapper::mapOperand(const Metadata *Op) {
return false;
if (Optional<Metadata *> MappedOp = M.mapSimpleMetadata(Op)) {
#ifndef NDEBUG
if (auto *CMD = dyn_cast<ConstantAsMetadata>(Op))
assert((!*MappedOp || M.getVM().count(CMD->getValue()) ||
M.getVM().getMappedMD(Op)) &&
@ -512,6 +513,7 @@ bool MDNodeMapper::mapOperand(const Metadata *Op) {
else
assert((isa<MDString>(Op) || M.getVM().getMappedMD(Op)) &&
"Expected result to be memoized");
#endif
return *MappedOp != Op;
}