diff options
| author | Pieter Wuille <[email protected]> | 2020-03-11 09:35:50 -0700 |
|---|---|---|
| committer | Pieter Wuille <[email protected]> | 2020-03-30 16:10:30 -0700 |
| commit | 4eb5643e3538863c9d2ff261f49a9a1b248de243 (patch) | |
| tree | 377437ffee20c67fa7e0611c31be6b2490a4483c /src/txdb.cpp | |
| parent | Convert blockencodings_tests to new serialization (diff) | |
| download | discoin-4eb5643e3538863c9d2ff261f49a9a1b248de243.tar.xz discoin-4eb5643e3538863c9d2ff261f49a9a1b248de243.zip | |
Convert everything except wallet/qt to new serialization
Diffstat (limited to 'src/txdb.cpp')
| -rw-r--r-- | src/txdb.cpp | 14 |
1 files changed, 1 insertions, 13 deletions
diff --git a/src/txdb.cpp b/src/txdb.cpp index acc47ab45..77dfd0d54 100644 --- a/src/txdb.cpp +++ b/src/txdb.cpp @@ -36,19 +36,7 @@ struct CoinEntry { char key; explicit CoinEntry(const COutPoint* ptr) : outpoint(const_cast<COutPoint*>(ptr)), key(DB_COIN) {} - template<typename Stream> - void Serialize(Stream &s) const { - s << key; - s << outpoint->hash; - s << VARINT(outpoint->n); - } - - template<typename Stream> - void Unserialize(Stream& s) { - s >> key; - s >> outpoint->hash; - s >> VARINT(outpoint->n); - } + SERIALIZE_METHODS(CoinEntry, obj) { READWRITE(obj.key, obj.outpoint->hash, VARINT(obj.outpoint->n)); } }; } |