]> granicus.if.org Git - clang/commitdiff
Fix unused variable warning after r273754.
authorJames Y Knight <jyknight@google.com>
Sat, 25 Jun 2016 16:40:53 +0000 (16:40 +0000)
committerJames Y Knight <jyknight@google.com>
Sat, 25 Jun 2016 16:40:53 +0000 (16:40 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@273783 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Sema/Sema.cpp

index a87f13d7e6b38721b63a0a92b03ef8b6a4039482..a242ace9f64eeb66eaa31b7c4f8e785bbaad8680 100644 (file)
@@ -525,6 +525,7 @@ static void checkUndefinedButUsed(Sema &S) {
       S.Diag(ND->getLocation(), diag::warn_undefined_internal)
         << isa<VarDecl>(ND) << ND;
     } else if (auto *FD = dyn_cast<FunctionDecl>(ND)) {
+      (void)FD;
       assert(FD->getMostRecentDecl()->isInlined() &&
              "used object requires definition but isn't inline or internal?");
       // FIXME: This is ill-formed; we should reject.