From 94eab4ad0407f0ceb1f7ae72686e16b6f1cc27e4 Mon Sep 17 00:00:00 2001 From: Chandler Carruth Date: Sat, 13 Feb 2010 10:38:52 +0000 Subject: Silence unused variable warning in a build without assertions. llvm-svn: 96098 --- clang/lib/CodeGen/CGVtable.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'clang/lib') diff --git a/clang/lib/CodeGen/CGVtable.cpp b/clang/lib/CodeGen/CGVtable.cpp index c0291486f7b..163088e91a2 100644 --- a/clang/lib/CodeGen/CGVtable.cpp +++ b/clang/lib/CodeGen/CGVtable.cpp @@ -16,6 +16,7 @@ #include "clang/AST/CXXInheritance.h" #include "clang/AST/RecordLayout.h" #include "llvm/ADT/DenseSet.h" +#include "llvm/Support/Compiler.h" #include "llvm/Support/Format.h" #include @@ -745,7 +746,7 @@ VtableBuilder::layoutVirtualMemberFunctions(BaseSubobject Base, // Check if this virtual member function overrides a method in a primary // base. If this is the case, and the return type doesn't require adjustment // then we can just use the member function from the primary base. - if (const CXXMethodDecl *OverriddenMD = + if (const CXXMethodDecl ATTRIBUTE_UNUSED *OverriddenMD = OverridesMethodInPrimaryBase(MD, PrimaryBases)) { assert(!ReturnTypeConversionRequiresAdjustment(MD, OverriddenMD) && "FIXME: Handle covariant thunks!"); -- cgit v1.2.3