diff options
author | Roman Divacky <rdivacky@freebsd.org> | 2012-09-06 15:59:27 +0000 |
---|---|---|
committer | Roman Divacky <rdivacky@freebsd.org> | 2012-09-06 15:59:27 +0000 |
commit | 31ba6135375433b617a8587ea6cc836a014ebd86 (patch) | |
tree | f48bcb797d27fd4240f08c3b8fb28485a7d0bf37 /lib/CodeGen/CGObjCMac.cpp | |
parent | a8ee4412e7410870ed9111f35eb377fa24873781 (diff) |
Dont cast away const needlessly. Found by gcc48 -Wcast-qual.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@163325 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/CGObjCMac.cpp')
-rw-r--r-- | lib/CodeGen/CGObjCMac.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/CodeGen/CGObjCMac.cpp b/lib/CodeGen/CGObjCMac.cpp index ef802a3ed0..9a61e34ab2 100644 --- a/lib/CodeGen/CGObjCMac.cpp +++ b/lib/CodeGen/CGObjCMac.cpp @@ -1860,7 +1860,7 @@ llvm::Constant *CGObjCCommonMac::BuildGCBlockLayout(CodeGenModule &CGM, llvm::Constant *C = BuildIvarLayoutBitmap(BitMap); if (CGM.getLangOpts().ObjCGCBitmapPrint) { printf("\n block variable layout for block: "); - const unsigned char *s = (unsigned char*)BitMap.c_str(); + const unsigned char *s = (const unsigned char*)BitMap.c_str(); for (unsigned i = 0, e = BitMap.size(); i < e; i++) if (!(s[i] & 0xf0)) printf("0x0%x%s", s[i], s[i] != 0 ? ", " : ""); @@ -4187,7 +4187,7 @@ llvm::Constant *CGObjCCommonMac::BuildIvarLayout( printf("\n%s ivar layout for class '%s': ", ForStrongLayout ? "strong" : "weak", OMD->getClassInterface()->getName().data()); - const unsigned char *s = (unsigned char*)BitMap.c_str(); + const unsigned char *s = (const unsigned char*)BitMap.c_str(); for (unsigned i = 0, e = BitMap.size(); i < e; i++) if (!(s[i] & 0xf0)) printf("0x0%x%s", s[i], s[i] != 0 ? ", " : ""); |