Avoid unnecessarily casting away const, fixing a FIXME.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@46591 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/Analysis/ConstantFolding.cpp b/lib/Analysis/ConstantFolding.cpp
index 21e1944..e29b2db 100644
--- a/lib/Analysis/ConstantFolding.cpp
+++ b/lib/Analysis/ConstantFolding.cpp
@@ -508,7 +508,7 @@
 /// canConstantFoldCallTo - Return true if its even possible to fold a call to
 /// the specified function.
 bool
-llvm::canConstantFoldCallTo(Function *F) {
+llvm::canConstantFoldCallTo(const Function *F) {
   switch (F->getIntrinsicID()) {
   case Intrinsic::sqrt:
   case Intrinsic::powi:
diff --git a/lib/Analysis/ScalarEvolution.cpp b/lib/Analysis/ScalarEvolution.cpp
index e373478..10f05bc 100644
--- a/lib/Analysis/ScalarEvolution.cpp
+++ b/lib/Analysis/ScalarEvolution.cpp
@@ -1979,7 +1979,7 @@
 
   if (const CallInst *CI = dyn_cast<CallInst>(I))
     if (const Function *F = CI->getCalledFunction())
-      return canConstantFoldCallTo((Function*)F);  // FIXME: elim cast
+      return canConstantFoldCallTo(F);
   return false;
 }