[cfe-commits] r150210 - /cfe/trunk/lib/CodeGen/CGObjCMac.cpp

Bill Wendling isanbard at gmail.com
Thu Feb 9 14:45:21 PST 2012


Author: void
Date: Thu Feb  9 16:45:21 2012
New Revision: 150210

URL: http://llvm.org/viewvc/llvm-project?rev=150210&view=rev
Log:
Remove evil const_cast that's not needed anymore.

Modified:
    cfe/trunk/lib/CodeGen/CGObjCMac.cpp

Modified: cfe/trunk/lib/CodeGen/CGObjCMac.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/CodeGen/CGObjCMac.cpp?rev=150210&r1=150209&r2=150210&view=diff
==============================================================================
--- cfe/trunk/lib/CodeGen/CGObjCMac.cpp (original)
+++ cfe/trunk/lib/CodeGen/CGObjCMac.cpp Thu Feb  9 16:45:21 2012
@@ -4158,9 +4158,7 @@
 llvm::Constant *CGObjCCommonMac::GetMethodVarType(const ObjCMethodDecl *D,
                                                   bool Extended) {
   std::string TypeStr;
-  if (CGM.getContext().getObjCEncodingForMethodDecl(
-                                                const_cast<ObjCMethodDecl*>(D),
-                                                    TypeStr, Extended))
+  if (CGM.getContext().getObjCEncodingForMethodDecl(D, TypeStr, Extended))
     return 0;
 
   llvm::GlobalVariable *&Entry = MethodVarTypes[TypeStr];





More information about the cfe-commits mailing list