refactor: uint256::operator==() = default

This is standard C++20, and may allow a compiler to optimize a bit more.
This commit is contained in:
MarcoFalke
2026-08-05 13:48:02 +02:00
parent c940fd7514
commit fa6df14c23

View File

@@ -59,6 +59,8 @@ public:
std::fill(m_data.begin(), m_data.end(), 0);
}
constexpr bool operator==(const base_blob&) const = default;
/** Lexicographic ordering
* @note Does NOT match the ordering on the corresponding \ref
* base_uint::CompareTo, which starts comparing from the end.
@@ -70,7 +72,6 @@ public:
return 0;
}
friend constexpr bool operator==(const base_blob& a, const base_blob& b) { return a.Compare(b) == 0; }
friend constexpr bool operator<(const base_blob& a, const base_blob& b) { return a.Compare(b) < 0; }
/** @name Hex representation