From e9621040e565e15c7d7d29df604b29099ac0a60c Mon Sep 17 00:00:00 2001 From: NAKAMURA Takumi Date: Tue, 15 Sep 2015 01:39:27 +0000 Subject: ItaniumCXXABI.cpp: Fix a warning. [-Wunused-variable] llvm-svn: 247655 --- clang/lib/CodeGen/ItaniumCXXABI.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'clang/lib') diff --git a/clang/lib/CodeGen/ItaniumCXXABI.cpp b/clang/lib/CodeGen/ItaniumCXXABI.cpp index 31be2f98653..85c7fd16030 100644 --- a/clang/lib/CodeGen/ItaniumCXXABI.cpp +++ b/clang/lib/CodeGen/ItaniumCXXABI.cpp @@ -3392,14 +3392,13 @@ static void emitConstructorDestructorAlias(CodeGenModule &CGM, return; auto *Aliasee = cast(CGM.GetAddrOfGlobal(TargetDecl)); - llvm::PointerType *AliasType = Aliasee->getType(); // Create the alias with no name. auto *Alias = llvm::GlobalAlias::create(Linkage, "", Aliasee); // Switch any previous uses to the alias. if (Entry) { - assert(Entry->getType() == AliasType && + assert(Entry->getType() == Aliasee->getType() && "declaration exists with different type"); Alias->takeName(Entry); Entry->replaceAllUsesWith(Alias); -- cgit v1.2.3