From: Dmitri Gribenko Date: Wed, 19 Dec 2012 17:29:30 +0000 (+0000) Subject: Add a missing 'else'. Found by grep '} if' X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=d7ebf3eead93232af7c7f0d30385a1f4c890f904;p=clang Add a missing 'else'. Found by grep '} if' No testcase because this did not affect correctness: a declaration can only be ClassTemplateDecl or a FunctionTemplateDecl, not both. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@170565 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/tools/libclang/IndexingContext.cpp b/tools/libclang/IndexingContext.cpp index 8f7102911e..3a73aee59f 100644 --- a/tools/libclang/IndexingContext.cpp +++ b/tools/libclang/IndexingContext.cpp @@ -827,7 +827,7 @@ IndexingContext::getEntityContainer(const Decl *D) const { if (const ClassTemplateDecl *ClassTempl = dyn_cast(D)) { DC = ClassTempl->getTemplatedDecl(); - } if (const FunctionTemplateDecl * + } else if (const FunctionTemplateDecl * FuncTempl = dyn_cast(D)) { DC = FuncTempl->getTemplatedDecl(); }