1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-23 11:13:28 +01:00

[SimplifyLibCalls] Use any_of(). Suggested by David Blaikie!

llvm-svn: 254239
This commit is contained in:
Davide Italiano 2015-11-28 22:27:48 +00:00
parent cfb0838f67
commit b0e9d52803

View File

@ -86,10 +86,9 @@ static bool isOnlyUsedInEqualityComparison(Value *V, Value *With) {
}
static bool callHasFloatingPointArgument(const CallInst *CI) {
for (const Use &OI : CI->operands())
if (OI->getType()->isFloatingPointTy())
return true;
return false;
return std::any_of(CI->op_begin(), CI->op_end(), [](const Use &OI) {
return OI->getType()->isFloatingPointTy();
});
}
/// \brief Check whether the overloaded unary floating point function