From b788136508be35d67092d98e33cbf3d7063647ec Mon Sep 17 00:00:00 2001 From: levlam Date: Sun, 3 Mar 2024 02:14:53 +0300 Subject: [PATCH] Minor improvements. --- CMake/FindAtomics.cmake | 18 +++++++++--------- td/telegram/ContactsManager.cpp | 1 - td/telegram/ContactsManager.h | 1 - td/telegram/DialogParticipantManager.cpp | 2 ++ 4 files changed, 11 insertions(+), 11 deletions(-) diff --git a/CMake/FindAtomics.cmake b/CMake/FindAtomics.cmake index c35d625f0..a85513258 100644 --- a/CMake/FindAtomics.cmake +++ b/CMake/FindAtomics.cmake @@ -18,19 +18,19 @@ include(CheckCXXSourceCompiles) # RISC-V only has 32-bit and 64-bit atomic instructions. GCC is supposed # to convert smaller atomics to those larger ones via masking and -# shifting like LLVM, but it’s a known bug that it does not. This means +# shifting like LLVM, but it's a known bug that it does not. This means # anything that wants to use atomics on 1-byte or 2-byte types needs # to link atomic library, but not 4-byte or 8-byte (though it does no harm). set(ATOMIC_CODE " - #include - #include - std::atomic n8(0); // riscv64 - std::atomic n64(0); // armel, mipsel, powerpc - int main() { - ++n8; - ++n64; - }") + #include + #include + std::atomic n8{0}; // riscv64 + std::atomic n64{0}; // armel, mipsel, powerpc + int main() { + ++n8; + ++n64; + }") set(ATOMICS_LIBS " " "-latomic") if (CMAKE_SYSTEM_NAME MATCHES "NetBSD") diff --git a/td/telegram/ContactsManager.cpp b/td/telegram/ContactsManager.cpp index e283c4f77..19b017c6c 100644 --- a/td/telegram/ContactsManager.cpp +++ b/td/telegram/ContactsManager.cpp @@ -84,7 +84,6 @@ #include #include -#include #include #include #include diff --git a/td/telegram/ContactsManager.h b/td/telegram/ContactsManager.h index feffaa1e9..8f811b2ac 100644 --- a/td/telegram/ContactsManager.h +++ b/td/telegram/ContactsManager.h @@ -19,7 +19,6 @@ #include "td/telegram/DialogInviteLink.h" #include "td/telegram/DialogLocation.h" #include "td/telegram/DialogParticipant.h" -#include "td/telegram/DialogParticipantFilter.h" #include "td/telegram/EmojiStatus.h" #include "td/telegram/files/FileId.h" #include "td/telegram/files/FileSourceId.h" diff --git a/td/telegram/DialogParticipantManager.cpp b/td/telegram/DialogParticipantManager.cpp index 84298ef72..f0dedd2a5 100644 --- a/td/telegram/DialogParticipantManager.cpp +++ b/td/telegram/DialogParticipantManager.cpp @@ -35,12 +35,14 @@ #include "td/utils/Hints.h" #include "td/utils/logging.h" #include "td/utils/misc.h" +#include "td/utils/Slice.h" #include "td/utils/SliceBuilder.h" #include "td/utils/Status.h" #include "td/utils/Time.h" #include #include +#include namespace td {