aboutsummaryrefslogtreecommitdiff
path: root/src/pubkey.h
diff options
context:
space:
mode:
authorAntoine Poinsot <darosior@protonmail.com>2022-08-04 11:28:57 +0200
committerAntoine Poinsot <darosior@protonmail.com>2022-08-04 11:32:25 +0200
commit50cfc9e7613d6cf6b534df6e551238b80678c70d (patch)
treec7f6ee123fab8b4ac98f2ccc3d5a2a7a861402f3 /src/pubkey.h
parent0ca258a5ace798c4e54308aa8a09b1ab3302cd7e (diff)
(pubk)key: mark Derive() as nodiscard
Diffstat (limited to 'src/pubkey.h')
-rw-r--r--src/pubkey.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/pubkey.h b/src/pubkey.h
index 463efe1b00..0485a38f72 100644
--- a/src/pubkey.h
+++ b/src/pubkey.h
@@ -218,7 +218,7 @@ public:
bool Decompress();
//! Derive BIP32 child pubkey.
- bool Derive(CPubKey& pubkeyChild, ChainCode &ccChild, unsigned int nChild, const ChainCode& cc) const;
+ [[nodiscard]] bool Derive(CPubKey& pubkeyChild, ChainCode &ccChild, unsigned int nChild, const ChainCode& cc) const;
};
class XOnlyPubKey
@@ -327,7 +327,7 @@ struct CExtPubKey {
void Decode(const unsigned char code[BIP32_EXTKEY_SIZE]);
void EncodeWithVersion(unsigned char code[BIP32_EXTKEY_WITH_VERSION_SIZE]) const;
void DecodeWithVersion(const unsigned char code[BIP32_EXTKEY_WITH_VERSION_SIZE]);
- bool Derive(CExtPubKey& out, unsigned int nChild) const;
+ [[nodiscard]] bool Derive(CExtPubKey& out, unsigned int nChild) const;
};
/** Users of this module must hold an ECCVerifyHandle. The constructor and