s/MethodType/FunctionType


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2115 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/Target/SparcV9/SparcV9RegInfo.cpp b/lib/Target/SparcV9/SparcV9RegInfo.cpp
index 434816e..8ec2399 100644
--- a/lib/Target/SparcV9/SparcV9RegInfo.cpp
+++ b/lib/Target/SparcV9/SparcV9RegInfo.cpp
@@ -264,10 +264,8 @@
   const MachineOperand & calleeOp = CallMI->getOperand(0);
   Value *calleeVal =  calleeOp.getVRegValue();
 
-  PointerType *PT =  cast<PointerType> (calleeVal->getType());
-  MethodType  *MT = cast<MethodType>(PT->getElementType());
-
-  return MT->isVarArg();
+  PointerType *PT =  cast<PointerType>(calleeVal->getType());
+  return cast<FunctionType>(PT->getElementType())->isVarArg();
 }