diff options
author | Guido Falsi <madpilot@FreeBSD.org> | 2020-03-23 12:43:39 +0000 |
---|---|---|
committer | Guido Falsi <madpilot@FreeBSD.org> | 2020-03-23 12:43:39 +0000 |
commit | dd087e4403f01b71ec9a31c76240cf6a38a947a5 (patch) | |
tree | ab0b600ff924d7cc0ee56b8ec123f0f7dc2d585a /net-im/telegram-desktop | |
parent | 9be215704ee82ea2ebff915af038b6b2345374b0 (diff) | |
download | ports-dd087e4403f01b71ec9a31c76240cf6a38a947a5.tar.gz ports-dd087e4403f01b71ec9a31c76240cf6a38a947a5.zip |
Fix build with clang 10
PR: 245004
Obtained from: https://github.com/Tencent/rapidjson/commit/2661a17c7eaede8c881e7455f5a66fd593ed8633#diff-4a56fc9353bac10cf2f51e22e38e3b2a (part)
Approved by: portmgr (blanket)
Notes
Notes:
svn path=/head/; revision=528972
Diffstat (limited to 'net-im/telegram-desktop')
2 files changed, 48 insertions, 0 deletions
diff --git a/net-im/telegram-desktop/files/patch-Telegram_ThirdParty_rlottie_src_lottie_rapidjson_document.h b/net-im/telegram-desktop/files/patch-Telegram_ThirdParty_rlottie_src_lottie_rapidjson_document.h new file mode 100644 index 000000000000..c8c333dcca55 --- /dev/null +++ b/net-im/telegram-desktop/files/patch-Telegram_ThirdParty_rlottie_src_lottie_rapidjson_document.h @@ -0,0 +1,30 @@ +--- Telegram/ThirdParty/rlottie/src/lottie/rapidjson/document.h.orig 2020-01-23 12:47:53 UTC ++++ Telegram/ThirdParty/rlottie/src/lottie/rapidjson/document.h +@@ -24,6 +24,9 @@ + #include "encodedstream.h" + #include <new> // placement new + #include <limits> ++#ifdef __cpp_impl_three_way_comparison ++#include <compare> ++#endif + + RAPIDJSON_DIAG_PUSH + #ifdef __clang__ +@@ -175,12 +178,17 @@ class GenericMemberIterator { (public) + + //! @name relations + //@{ ++#ifdef __cpp_impl_three_way_comparison ++ template <bool Const_> bool operator==(const GenericMemberIterator<Const_,Encoding,Allocator>& that) const { return ptr_ == that.ptr_; } ++ template <bool Const_> std::strong_ordering operator<=>(const GenericMemberIterator<Const_,Encoding,Allocator>& that) const { return ptr_ <=> that.ptr_; } ++#else + bool operator==(ConstIterator that) const { return ptr_ == that.ptr_; } + bool operator!=(ConstIterator that) const { return ptr_ != that.ptr_; } + bool operator<=(ConstIterator that) const { return ptr_ <= that.ptr_; } + bool operator>=(ConstIterator that) const { return ptr_ >= that.ptr_; } + bool operator< (ConstIterator that) const { return ptr_ < that.ptr_; } + bool operator> (ConstIterator that) const { return ptr_ > that.ptr_; } ++#endif + //@} + + //! @name dereference diff --git a/net-im/telegram-desktop/files/patch-Telegram_lib__base_base_thread__safe__wrap.h b/net-im/telegram-desktop/files/patch-Telegram_lib__base_base_thread__safe__wrap.h new file mode 100644 index 000000000000..8e0764f500a8 --- /dev/null +++ b/net-im/telegram-desktop/files/patch-Telegram_lib__base_base_thread__safe__wrap.h @@ -0,0 +1,18 @@ +--- Telegram/lib_base/base/thread_safe_wrap.h.orig 2020-01-29 09:41:30 UTC ++++ Telegram/lib_base/base/thread_safe_wrap.h +@@ -19,13 +19,13 @@ class thread_safe_wrap { (public) + + template <typename Callback> + auto with(Callback &&callback) { +- QMutexLocker lock(&_mutex); ++ QMutexLocker lock((QBasicMutex *)&_mutex); + return callback(_value); + } + + template <typename Callback> + auto with(Callback &&callback) const { +- QMutexLocker lock(&_mutex); ++ QMutexLocker lock((QBasicMutex *)&_mutex); + return callback(_value); + } + |