r175160 - Remove an unneeded const_cast

Dmitri Gribenko gribozavr at gmail.com
Thu Feb 14 05:49:48 PST 2013


Author: gribozavr
Date: Thu Feb 14 07:49:48 2013
New Revision: 175160

URL: http://llvm.org/viewvc/llvm-project?rev=175160&view=rev
Log:
Remove an unneeded const_cast

Modified:
    cfe/trunk/lib/Edit/RewriteObjCFoundationAPI.cpp

Modified: cfe/trunk/lib/Edit/RewriteObjCFoundationAPI.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Edit/RewriteObjCFoundationAPI.cpp?rev=175160&r1=175159&r2=175160&view=diff
==============================================================================
--- cfe/trunk/lib/Edit/RewriteObjCFoundationAPI.cpp (original)
+++ cfe/trunk/lib/Edit/RewriteObjCFoundationAPI.cpp Thu Feb 14 07:49:48 2013
@@ -296,9 +296,8 @@ bool edit::rewriteToObjCSubscriptSyntax(
   if (!Method)
     return false;
 
-  const ObjCInterfaceDecl *
-    IFace = NS.getASTContext().getObjContainingInterface(
-                                          const_cast<ObjCMethodDecl *>(Method));
+  const ObjCInterfaceDecl *IFace =
+      NS.getASTContext().getObjContainingInterface(Method);
   if (!IFace)
     return false;
   Selector Sel = Msg->getSelector();





More information about the cfe-commits mailing list