From 70371a4344a22439f3a24b9fc69a3c2576425774 Mon Sep 17 00:00:00 2001 From: Olek <115580134+oleks-rip@users.noreply.github.com> Date: Wed, 21 May 2025 13:28:18 -0400 Subject: [PATCH] Fix initializer list initialization for GCC-15 (#5443) --- include/xrpl/beast/hash/uhash.h | 2 +- include/xrpl/beast/net/IPEndpoint.h | 4 ++-- include/xrpl/protocol/AccountID.h | 2 +- include/xrpl/protocol/Book.h | 8 ++++---- include/xrpl/protocol/UintTypes.h | 8 ++++---- include/xrpl/resource/detail/Key.h | 2 +- src/xrpld/app/paths/RippleLineCache.h | 2 +- 7 files changed, 14 insertions(+), 14 deletions(-) diff --git a/include/xrpl/beast/hash/uhash.h b/include/xrpl/beast/hash/uhash.h index ab3eaad039..ac4ba7256d 100644 --- a/include/xrpl/beast/hash/uhash.h +++ b/include/xrpl/beast/hash/uhash.h @@ -30,7 +30,7 @@ namespace beast { template struct uhash { - explicit uhash() = default; + uhash() = default; using result_type = typename Hasher::result_type; diff --git a/include/xrpl/beast/net/IPEndpoint.h b/include/xrpl/beast/net/IPEndpoint.h index e66e7f4caa..345ba4b8da 100644 --- a/include/xrpl/beast/net/IPEndpoint.h +++ b/include/xrpl/beast/net/IPEndpoint.h @@ -215,7 +215,7 @@ namespace std { template <> struct hash<::beast::IP::Endpoint> { - explicit hash() = default; + hash() = default; std::size_t operator()(::beast::IP::Endpoint const& endpoint) const @@ -230,7 +230,7 @@ namespace boost { template <> struct hash<::beast::IP::Endpoint> { - explicit hash() = default; + hash() = default; std::size_t operator()(::beast::IP::Endpoint const& endpoint) const diff --git a/include/xrpl/protocol/AccountID.h b/include/xrpl/protocol/AccountID.h index 2677dd76bc..295cf41e4f 100644 --- a/include/xrpl/protocol/AccountID.h +++ b/include/xrpl/protocol/AccountID.h @@ -149,7 +149,7 @@ namespace std { template <> struct hash : ripple::AccountID::hasher { - explicit hash() = default; + hash() = default; }; } // namespace std diff --git a/include/xrpl/protocol/Book.h b/include/xrpl/protocol/Book.h index 0a04deb277..0fcff0df80 100644 --- a/include/xrpl/protocol/Book.h +++ b/include/xrpl/protocol/Book.h @@ -104,7 +104,7 @@ private: boost::base_from_member, 1>; public: - explicit hash() = default; + hash() = default; using value_type = std::size_t; using argument_type = ripple::Issue; @@ -131,7 +131,7 @@ private: hasher m_hasher; public: - explicit hash() = default; + hash() = default; using value_type = std::size_t; using argument_type = ripple::Book; @@ -154,7 +154,7 @@ namespace boost { template <> struct hash : std::hash { - explicit hash() = default; + hash() = default; using Base = std::hash; // VFALCO NOTE broken in vs2012 @@ -164,7 +164,7 @@ struct hash : std::hash template <> struct hash : std::hash { - explicit hash() = default; + hash() = default; using Base = std::hash; // VFALCO NOTE broken in vs2012 diff --git a/include/xrpl/protocol/UintTypes.h b/include/xrpl/protocol/UintTypes.h index 9a7284158e..d6cdc9350e 100644 --- a/include/xrpl/protocol/UintTypes.h +++ b/include/xrpl/protocol/UintTypes.h @@ -119,25 +119,25 @@ namespace std { template <> struct hash : ripple::Currency::hasher { - explicit hash() = default; + hash() = default; }; template <> struct hash : ripple::NodeID::hasher { - explicit hash() = default; + hash() = default; }; template <> struct hash : ripple::Directory::hasher { - explicit hash() = default; + hash() = default; }; template <> struct hash : ripple::uint256::hasher { - explicit hash() = default; + hash() = default; }; } // namespace std diff --git a/include/xrpl/resource/detail/Key.h b/include/xrpl/resource/detail/Key.h index f953d5103e..188ee142da 100644 --- a/include/xrpl/resource/detail/Key.h +++ b/include/xrpl/resource/detail/Key.h @@ -53,7 +53,7 @@ struct Key struct key_equal { - explicit key_equal() = default; + key_equal() = default; bool operator()(Key const& lhs, Key const& rhs) const diff --git a/src/xrpld/app/paths/RippleLineCache.h b/src/xrpld/app/paths/RippleLineCache.h index 5a3188c810..6196211a70 100644 --- a/src/xrpld/app/paths/RippleLineCache.h +++ b/src/xrpld/app/paths/RippleLineCache.h @@ -104,7 +104,7 @@ private: struct Hash { - explicit Hash() = default; + Hash() = default; std::size_t operator()(AccountKey const& key) const noexcept