Fix a warning. [-Wunused-variable]

llvm-svn: 184284
This commit is contained in:
NAKAMURA Takumi
2013-06-19 06:58:20 +00:00
parent dc2e2fb9ce
commit 9157b55c3c

View File

@@ -723,9 +723,9 @@ void CodeGenModule::SetFunctionAttributes(GlobalDecl GD,
SetLLVMFunctionAttributes(FD, getTypes().arrangeGlobalDeclaration(GD), F);
if (getCXXABI().HasThisReturn(GD)) {
llvm::Type *RetTy = F->getReturnType();
assert(!F->arg_empty() &&
F->arg_begin()->getType()->canLosslesslyBitCastTo(RetTy) &&
F->arg_begin()->getType()
->canLosslesslyBitCastTo(F->getReturnType()) &&
"unexpected this return");
F->addAttribute(1, llvm::Attribute::Returned);
}