mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-05-20 08:53:36 +02:00
Add serialization methods to XOnlyPubKey
It is useful to have serialzation methods for XOnlyPubKey. These will serialize the internal uint256, so it is not prefixed with the length as CPubKey does.
This commit is contained in:
parent
d43923c381
commit
d557eff2ad
@ -286,6 +286,9 @@ public:
|
||||
bool operator==(const XOnlyPubKey& other) const { return m_keydata == other.m_keydata; }
|
||||
bool operator!=(const XOnlyPubKey& other) const { return m_keydata != other.m_keydata; }
|
||||
bool operator<(const XOnlyPubKey& other) const { return m_keydata < other.m_keydata; }
|
||||
|
||||
//! Implement serialization without length prefixes since it is a fixed length
|
||||
SERIALIZE_METHODS(XOnlyPubKey, obj) { READWRITE(obj.m_keydata); }
|
||||
};
|
||||
|
||||
struct CExtPubKey {
|
||||
|
Loading…
x
Reference in New Issue
Block a user