Use explicit conversion from WitnessV0KeyHash -> CKeyID

These types are equivalent, in data etc, so they need only their
data cast across.
This commit is contained in:
Ben Woosley
2020-01-15 13:41:25 -08:00
parent 2c54217f91
commit f32c1e07fd
4 changed files with 9 additions and 3 deletions

View File

@@ -106,6 +106,7 @@ struct WitnessV0KeyHash : public uint160
explicit WitnessV0KeyHash(const uint160& hash) : uint160(hash) {}
explicit WitnessV0KeyHash(const CPubKey& pubkey);
};
CKeyID ToKeyID(const WitnessV0KeyHash& key_hash);
//! CTxDestination subtype to encode any future Witness version
struct WitnessUnknown