summaryrefslogtreecommitdiffstats
path: root/clang
diff options
context:
space:
mode:
authorNAKAMURA Takumi <geek4civic@gmail.com>2014-11-11 01:36:11 +0000
committerNAKAMURA Takumi <geek4civic@gmail.com>2014-11-11 01:36:11 +0000
commit17d6094d14b0e0ceb7131be9d12d65e8edb7da07 (patch)
tree57c9e6929297502a5c580a0cdfc18affd77bf228 /clang
parentf373c77f50451ff585b507cce05705632553d13a (diff)
downloadbcm5719-llvm-17d6094d14b0e0ceb7131be9d12d65e8edb7da07.tar.gz
bcm5719-llvm-17d6094d14b0e0ceb7131be9d12d65e8edb7da07.zip
CGExpr.cpp: Suppress a warning. [-Wunused-variable]
llvm-svn: 221655
Diffstat (limited to 'clang')
-rw-r--r--clang/lib/CodeGen/CGExpr.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/clang/lib/CodeGen/CGExpr.cpp b/clang/lib/CodeGen/CGExpr.cpp
index 389cd000a72..b433a6454eb 100644
--- a/clang/lib/CodeGen/CGExpr.cpp
+++ b/clang/lib/CodeGen/CGExpr.cpp
@@ -2211,8 +2211,10 @@ void CodeGenFunction::EmitCheck(llvm::Value *Checked, StringRef CheckName,
for (int i = 1, n = Kinds.size(); i < n; ++i)
assert(RecoverKind == getRecoverableKind(Kinds[i]) &&
"All recoverable kinds in a single check must be same!");
+#ifndef NDEBUG
for (auto Kind : Kinds)
assert(SanOpts.has(Kind));
+#endif
if (CGM.getCodeGenOpts().SanitizeUndefinedTrapOnError) {
assert (RecoverKind != CheckRecoverableKind::AlwaysRecoverable &&
OpenPOWER on IntegriCloud