IRGen: Remove unnecessary cast from getOrCreateHelperFunction()

This commit is contained in:
Slava Pestov
2019-09-10 14:44:26 -04:00
parent dcb6a8bc55
commit f31bbf3a6e

View File

@@ -4481,9 +4481,8 @@ IRGenModule::getOrCreateHelperFunction(StringRef fnName, llvm::Type *resultTy,
llvm::FunctionType::get(resultTy, paramTys, false);
llvm::Constant *fn =
cast<llvm::Function>(Module.getOrInsertFunction(fnName, fnTy)
.getCallee()
->stripPointerCasts());
cast<llvm::Constant>(
Module.getOrInsertFunction(fnName, fnTy).getCallee());
if (llvm::Function *def = shouldDefineHelper(*this, fn, setIsNoInline)) {
IRGenFunction IGF(*this, def);