From 6ef4ea499fc91de4fdd9266f0658debb4c4ab87b Mon Sep 17 00:00:00 2001 From: Anders Carlsson Date: Fri, 10 Apr 2009 04:59:59 +0000 Subject: [PATCH] Rename variables to avoid conflict. llvm-svn: 68764 --- clang/lib/CodeGen/CGExprConstant.cpp | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/clang/lib/CodeGen/CGExprConstant.cpp b/clang/lib/CodeGen/CGExprConstant.cpp index c5f22023d37e..a3fca20f4fb1 100644 --- a/clang/lib/CodeGen/CGExprConstant.cpp +++ b/clang/lib/CodeGen/CGExprConstant.cpp @@ -482,7 +482,7 @@ llvm::Constant *CodeGenModule::EmitConstantExpr(const Expr *E, assert(0 && "Constant expressions should be initialized."); return 0; case APValue::LValue: { - const llvm::Type *DestType = getTypes().ConvertTypeForMem(E->getType()); + const llvm::Type *DestTy = getTypes().ConvertTypeForMem(E->getType()); llvm::Constant *Offset = llvm::ConstantInt::get(llvm::Type::Int64Ty, Result.Val.getLValueOffset()); @@ -502,21 +502,21 @@ llvm::Constant *CodeGenModule::EmitConstantExpr(const Expr *E, // Convert to the appropriate type; this could be an lvalue for // an integer. - if (isa(DestType)) - return llvm::ConstantExpr::getBitCast(C, DestType); + if (isa(DestTy)) + return llvm::ConstantExpr::getBitCast(C, DestTy); - return llvm::ConstantExpr::getPtrToInt(C, DestType); + return llvm::ConstantExpr::getPtrToInt(C, DestTy); } else { C = Offset; // Convert to the appropriate type; this could be an lvalue for // an integer. - if (isa(DestType)) - return llvm::ConstantExpr::getIntToPtr(C, DestType); + if (isa(DestTy)) + return llvm::ConstantExpr::getIntToPtr(C, DestTy); // If the types don't match this should only be a truncate. - if (C->getType() != DestType) - return llvm::ConstantExpr::getTrunc(C, DestType); + if (C->getType() != DestTy) + return llvm::ConstantExpr::getTrunc(C, DestTy); return C; } -- GitLab