aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/CodeGen/TargetLoweringBase.cpp
diff options
context:
space:
mode:
authorserge-sans-paille <sguelton@redhat.com>2022-01-26 10:11:12 -0500
committerserge-sans-paille <sguelton@redhat.com>2022-01-26 16:17:45 +0100
commitef8206320769ad31422a803a0d6de6077fd231d2 (patch)
tree06ca6445f38939d6a543e0a64c2ede55497a06cd /llvm/lib/CodeGen/TargetLoweringBase.cpp
parent99ae5c13f64e138d6b17c00bd01c87c3ce58cb6b (diff)
downloadllvm-ef8206320769ad31422a803a0d6de6077fd231d2.zip
llvm-ef8206320769ad31422a803a0d6de6077fd231d2.tar.gz
llvm-ef8206320769ad31422a803a0d6de6077fd231d2.tar.bz2
Rename llvm::array_lengthof into llvm::size to match std::size from C++17
As a conquence move llvm::array_lengthof from STLExtras.h to STLForwardCompat.h (which is included by STLExtras.h so no build breakage expected).
Diffstat (limited to 'llvm/lib/CodeGen/TargetLoweringBase.cpp')
-rw-r--r--llvm/lib/CodeGen/TargetLoweringBase.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/CodeGen/TargetLoweringBase.cpp b/llvm/lib/CodeGen/TargetLoweringBase.cpp
index ab57423..f34a917 100644
--- a/llvm/lib/CodeGen/TargetLoweringBase.cpp
+++ b/llvm/lib/CodeGen/TargetLoweringBase.cpp
@@ -966,7 +966,7 @@ TargetLoweringBase::getTypeConversion(LLVMContext &Context, EVT VT) const {
// If this is a simple type, use the ComputeRegisterProp mechanism.
if (VT.isSimple()) {
MVT SVT = VT.getSimpleVT();
- assert((unsigned)SVT.SimpleTy < array_lengthof(TransformToType));
+ assert((unsigned)SVT.SimpleTy < size(TransformToType));
MVT NVT = TransformToType[SVT.SimpleTy];
LegalizeTypeAction LA = ValueTypeActions.getTypeAction(SVT);