]> granicus.if.org Git - clang/commitdiff
fix warning in no-assert mode.
authorChris Lattner <sabre@nondot.org>
Thu, 19 Feb 2009 06:41:13 +0000 (06:41 +0000)
committerChris Lattner <sabre@nondot.org>
Thu, 19 Feb 2009 06:41:13 +0000 (06:41 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65024 91177308-0d34-0410-b5e6-96231b3b80d8

lib/AST/Builtins.cpp

index e4a79e4a380df586b19d211cc486dde83408b738..b572e8e04b576d2a184f27b3264aec8c7f83c23b 100644 (file)
@@ -71,9 +71,7 @@ Builtin::Context::isPrintfLike(unsigned ID, unsigned &FormatIdx,
   assert(*Printf == ':' && "p or P specifier must have be followed by a ':'");
   ++Printf;
 
-  const char *PrintfEnd = strchr(Printf, ':');
-  assert(PrintfEnd && "printf specifier must end with a ':'");
-
+  assert(strchr(Printf, ':') && "printf specifier must end with a ':'");
   FormatIdx = strtol(Printf, 0, 10);
   return true;
 }