[cfe-commits] r134888 - /cfe/trunk/lib/CodeGen/CodeGenModule.cpp

Jay Foad jay.foad at gmail.com
Mon Jul 11 00:56:41 PDT 2011


Author: foad
Date: Mon Jul 11 02:56:41 2011
New Revision: 134888

URL: http://llvm.org/viewvc/llvm-project?rev=134888&view=rev
Log:
De-constify Types in FunctionType::get().

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

Modified: cfe/trunk/lib/CodeGen/CodeGenModule.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/CodeGen/CodeGenModule.cpp?rev=134888&r1=134887&r2=134888&view=diff
==============================================================================
--- cfe/trunk/lib/CodeGen/CodeGenModule.cpp (original)
+++ cfe/trunk/lib/CodeGen/CodeGenModule.cpp Mon Jul 11 02:56:41 2011
@@ -1614,10 +1614,8 @@
 
 llvm::Function *CodeGenModule::getIntrinsic(unsigned IID, llvm::Type **Tys,
                                             unsigned NumTys) {
-  return llvm::Intrinsic::getDeclaration(&getModule(),
-                                         (llvm::Intrinsic::ID)IID,
-                                         const_cast<const llvm::Type **>(Tys),
-                                         NumTys);
+  return llvm::Intrinsic::getDeclaration(&getModule(), (llvm::Intrinsic::ID)IID,
+                                         Tys, NumTys);
 }
 
 static llvm::StringMapEntry<llvm::Constant*> &
@@ -2295,7 +2293,7 @@
   }
 
   // Otherwise construct the function by hand.
-  const llvm::Type *args[] = { Int8PtrTy, Int32Ty };
+  llvm::Type *args[] = { Int8PtrTy, Int32Ty };
   const llvm::FunctionType *fty
     = llvm::FunctionType::get(VoidTy, args, false);
   return BlockObjectDispose =
@@ -2314,7 +2312,7 @@
   }
 
   // Otherwise construct the function by hand.
-  const llvm::Type *args[] = { Int8PtrTy, Int8PtrTy, Int32Ty };
+  llvm::Type *args[] = { Int8PtrTy, Int8PtrTy, Int32Ty };
   const llvm::FunctionType *fty
     = llvm::FunctionType::get(VoidTy, args, false);
   return BlockObjectAssign =





More information about the cfe-commits mailing list