mdbx: использование clang-format-19.

This commit is contained in:
Леонид Юрьев (Leonid Yuriev) 2024-07-22 14:49:19 +03:00
parent cda8ebe0bd
commit 5c40f6983c
9 changed files with 62 additions and 60 deletions

View File

@ -2260,9 +2260,11 @@ public:
#if defined(DOXYGEN) || \ #if defined(DOXYGEN) || \
(defined(__cpp_lib_string_view) && __cpp_lib_string_view >= 201606L) (defined(__cpp_lib_string_view) && __cpp_lib_string_view >= 201606L)
template <class CHAR, class T> template <class CHAR, class T>
buffer(const ::std::basic_string_view<CHAR, T> &view, bool make_reference, buffer(const ::std::basic_string_view<CHAR, T> &view,
bool make_reference,
const allocator_type &allocator = allocator_type()) const allocator_type &allocator = allocator_type())
: buffer(::mdbx::slice(view), make_reference, allocator) {} : buffer(::mdbx::slice(view), make_reference, allocator) {
}
#endif /* __cpp_lib_string_view >= 201606L */ #endif /* __cpp_lib_string_view >= 201606L */
MDBX_CXX20_CONSTEXPR MDBX_CXX20_CONSTEXPR
@ -2296,7 +2298,8 @@ public:
MDBX_CXX20_CONSTEXPR MDBX_CXX20_CONSTEXPR
buffer(const ::std::basic_string_view<CHAR, T> &view, buffer(const ::std::basic_string_view<CHAR, T> &view,
const allocator_type &allocator = allocator_type()) const allocator_type &allocator = allocator_type())
: buffer(::mdbx::slice(view), allocator) {} : buffer(::mdbx::slice(view), allocator) {
}
#endif /* __cpp_lib_string_view >= 201606L */ #endif /* __cpp_lib_string_view >= 201606L */
buffer(size_t head_room, size_t tail_room, buffer(size_t head_room, size_t tail_room,

View File

@ -3787,7 +3787,9 @@ MDBX_MAYBE_UNUSED static bool cursor_is_tracked(const MDBX_cursor *mc) {
} \ } \
tracked->mc_next = *tracking_head; \ tracked->mc_next = *tracking_head; \
*tracking_head = tracked; \ *tracking_head = tracked; \
{ act; } \ { \
act; \
} \
*tracking_head = tracked->mc_next; \ *tracking_head = tracked->mc_next; \
} while (0) } while (0)

View File

@ -1660,8 +1660,7 @@ __cold ::std::ostream &operator<<(::std::ostream &out,
{env_managed::geometry::MB, "MB"}, {env_managed::geometry::MB, "MB"},
{env_managed::geometry::KiB, "KiB"}, {env_managed::geometry::KiB, "KiB"},
{env_managed::geometry::kB, "kB"}, {env_managed::geometry::kB, "kB"},
{1, " bytes"} {1, " bytes"}};
};
for (const auto i : scales) for (const auto i : scales)
if (bytes % i.one == 0) if (bytes % i.one == 0)

View File

@ -3398,8 +3398,7 @@ __cold int mdbx_get_sysraminfo(intptr_t *page_size, intptr_t *total_pages,
#elif defined(HW_USERMEM) || defined(HW_PHYSMEM64) || defined(HW_MEMSIZE) || \ #elif defined(HW_USERMEM) || defined(HW_PHYSMEM64) || defined(HW_MEMSIZE) || \
defined(HW_PHYSMEM) defined(HW_PHYSMEM)
size_t ram, len = sizeof(ram); size_t ram, len = sizeof(ram);
static const int mib[] = { static const int mib[] = {CTL_HW,
CTL_HW,
#if defined(HW_USERMEM) #if defined(HW_USERMEM)
HW_USERMEM HW_USERMEM
#elif defined(HW_PHYSMEM64) #elif defined(HW_PHYSMEM64)
@ -3448,8 +3447,7 @@ __cold int mdbx_get_sysraminfo(intptr_t *page_size, intptr_t *total_pages,
#elif defined(VM_TOTAL) || defined(VM_METER) #elif defined(VM_TOTAL) || defined(VM_METER)
struct vmtotal info; struct vmtotal info;
size_t len = sizeof(info); size_t len = sizeof(info);
static const int mib[] = { static const int mib[] = {CTL_VM,
CTL_VM,
#if defined(VM_TOTAL) #if defined(VM_TOTAL)
VM_TOTAL VM_TOTAL
#elif defined(VM_METER) #elif defined(VM_METER)