From 040c172cdf186c9ccfb0642aa9ac598f115bb46b Mon Sep 17 00:00:00 2001 From: Chris Robinson Date: Fri, 8 Dec 2023 10:11:08 -0800 Subject: Clean up some more clang-tidy warnings --- common/ringbuffer.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'common/ringbuffer.cpp') diff --git a/common/ringbuffer.cpp b/common/ringbuffer.cpp index af1f3669..0d3b7e30 100644 --- a/common/ringbuffer.cpp +++ b/common/ringbuffer.cpp @@ -24,7 +24,9 @@ #include #include +#include #include +#include #include "almalloc.h" @@ -40,7 +42,7 @@ RingBufferPtr RingBuffer::Create(std::size_t sz, std::size_t elem_sz, int limit_ power_of_two |= power_of_two>>4; power_of_two |= power_of_two>>8; power_of_two |= power_of_two>>16; - if constexpr(SIZE_MAX > UINT_MAX) + if constexpr(std::numeric_limits::max() > std::numeric_limits::max()) power_of_two |= power_of_two>>32; } ++power_of_two; -- cgit v1.2.3