diff options
author | Jeffrey Yasskin <jyasskin@google.com> | 2011-01-18 02:00:16 +0000 |
---|---|---|
committer | Jeffrey Yasskin <jyasskin@google.com> | 2011-01-18 02:00:16 +0000 |
commit | dec0984fce504a39a7f085774fb67cfd9957be58 (patch) | |
tree | 55173b9ff3c2a9fdc4be568145ce61ad5cb8f05e /lib/CodeGen/ItaniumCXXABI.cpp | |
parent | fb1e3bc29b667f4275e1d5a43d64ec173f4f9a7d (diff) |
Fix warnings found by gcc-4.6, from -Wunused-but-set-variable and
-Wint-to-pointer-cast.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@123719 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/ItaniumCXXABI.cpp')
-rw-r--r-- | lib/CodeGen/ItaniumCXXABI.cpp | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/lib/CodeGen/ItaniumCXXABI.cpp b/lib/CodeGen/ItaniumCXXABI.cpp index 554d2403c0..edc03b1bd1 100644 --- a/lib/CodeGen/ItaniumCXXABI.cpp +++ b/lib/CodeGen/ItaniumCXXABI.cpp @@ -349,11 +349,11 @@ ItaniumCXXABI::EmitMemberPointerConversion(CodeGenFunction &CGF, bool DerivedToBase = E->getCastKind() == CK_DerivedToBaseMemberPointer; - const CXXRecordDecl *BaseDecl, *DerivedDecl; + const CXXRecordDecl *DerivedDecl; if (DerivedToBase) - DerivedDecl = SrcDecl, BaseDecl = DestDecl; + DerivedDecl = SrcDecl; else - BaseDecl = SrcDecl, DerivedDecl = DestDecl; + DerivedDecl = DestDecl; llvm::Constant *Adj = CGF.CGM.GetNonVirtualBaseClassOffset(DerivedDecl, @@ -1000,7 +1000,6 @@ void ARMCXXABI::ReadArrayCookie(CodeGenFunction &CGF, // The cookie size is always 2 * sizeof(size_t). CookieSize = 2 * SizeSize; - CharUnits NumElementsOffset = CookieSize - SizeSize; // The allocated pointer is the input ptr, minus that amount. AllocPtr = CGF.Builder.CreateBitCast(Ptr, CharPtrTy); |