summaryrefslogtreecommitdiffstats
path: root/llvm/lib
diff options
context:
space:
mode:
authorPeter Collingbourne <peter@pcc.me.uk>2016-06-24 21:37:11 +0000
committerPeter Collingbourne <peter@pcc.me.uk>2016-06-24 21:37:11 +0000
commit995d6cc8f9f246e244f086cbb68ec1b4304eb9e3 (patch)
treea3f2c58d1ae8c8bf93100afd508ede89b6a69438 /llvm/lib
parent29ce701a06fe779614ee16ed06460f6ddb43e1b3 (diff)
downloadbcm5719-llvm-995d6cc8f9f246e244f086cbb68ec1b4304eb9e3.tar.gz
bcm5719-llvm-995d6cc8f9f246e244f086cbb68ec1b4304eb9e3.zip
Fix unused variable warning in -asserts builds.
llvm-svn: 273737
Diffstat (limited to 'llvm/lib')
-rw-r--r--llvm/lib/Transforms/IPO/CrossDSOCFI.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/llvm/lib/Transforms/IPO/CrossDSOCFI.cpp b/llvm/lib/Transforms/IPO/CrossDSOCFI.cpp
index 99d58333954..d95ba327a9a 100644
--- a/llvm/lib/Transforms/IPO/CrossDSOCFI.cpp
+++ b/llvm/lib/Transforms/IPO/CrossDSOCFI.cpp
@@ -98,8 +98,7 @@ void CrossDSOCFI::buildCFICheck() {
GO.getMetadata(LLVMContext::MD_type, Types);
for (MDNode *Type : Types) {
// Sanity check. GO must not be a function declaration.
- auto F = dyn_cast<Function>(&GO);
- assert(!F || !F->isDeclaration());
+ assert(!isa<Function>(&GO) || !cast<Function>(&GO)->isDeclaration());
if (ConstantInt *TypeId = extractNumericTypeId(Type))
TypeIds.insert(TypeId->getZExtValue());
OpenPOWER on IntegriCloud