diff --git a/llvm/utils/TableGen/CodeGenRegisters.h b/llvm/utils/TableGen/CodeGenRegisters.h index 2b200adef312..48cb9fe1a7e6 100644 --- a/llvm/utils/TableGen/CodeGenRegisters.h +++ b/llvm/utils/TableGen/CodeGenRegisters.h @@ -353,7 +353,7 @@ namespace llvm { unsigned getNumValueTypes() const { return VTs.size(); } bool hasType(const ValueTypeByHwMode &VT) const { - return std::find(VTs.begin(), VTs.end(), VT) != VTs.end(); + return llvm::is_contained(VTs, VT); } const ValueTypeByHwMode &getValueTypeNum(unsigned VTNum) const {