MCPcopy Create free account
hub / github.com/bitcoin/bitcoin / operator<

Method operator<

src/script/descriptor.cpp:192–199  ·  view source on GitHub ↗

Compare two public keys represented by this provider. * Used by the Miniscript descriptors to check for duplicate keys in the script. */

Source from the content-addressed store, hash-verified

190 * Used by the Miniscript descriptors to check for duplicate keys in the script.
191 */
192 bool operator<(PubkeyProvider& other) const {
193 FlatSigningProvider dummy;
194
195 std::optional<CPubKey> a = GetPubKey(0, dummy, dummy);
196 std::optional<CPubKey> b = other.GetPubKey(0, dummy, dummy);
197
198 return a < b;
199 }
200
201 /** Derive a public key and put it into out.
202 * read_cache is the cache to read keys from (if not nullptr)

Callers

nothing calls this directly

Calls 2

GetPubKeyFunction · 0.85
GetPubKeyMethod · 0.45

Tested by

no test coverage detected