From 80e9667ead57da8b90a5215d36497a2629f6f514 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=9B=D0=B5=D0=BE=D0=BD=D0=B8=D0=B4=20=D0=AE=D1=80=D1=8C?= =?UTF-8?q?=D0=B5=D0=B2=20=28Leonid=20Yuriev=29?= Date: Sat, 23 Mar 2024 15:32:02 +0300 Subject: [PATCH] =?UTF-8?q?mdbx++:=20=D1=8F=D0=B2=D0=BD=D0=BE=D0=B5=20?= =?UTF-8?q?=D0=BF=D1=80=D0=B8=D0=B2=D0=B5=D0=B4=D0=B5=D0=BD=D0=B8=D0=B5=20?= =?UTF-8?q?=D0=BA=20`int`=20=D0=B2=D0=BD=D1=83=D1=82=D1=80=D0=B8=20`conste?= =?UTF-8?q?xpr=20mdbx::memcmp()`.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- mdbx.h++ | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/mdbx.h++ b/mdbx.h++ index 0507774f..90d981b8 100644 --- a/mdbx.h++ +++ b/mdbx.h++ @@ -5120,8 +5120,8 @@ static MDBX_CXX20_CONSTEXPR int memcmp(const void *a, const void *b, __cpp_lib_is_constant_evaluated >= 201811L if (::std::is_constant_evaluated()) { for (size_t i = 0; i < bytes; ++i) { - const int diff = - static_cast(a)[i] - static_cast(b)[i]; + const int diff = int(static_cast(a)[i]) - + int(static_cast(b)[i]); if (diff) return diff; }