MCPcopy Create free account
hub / github.com/bitcoin/bitcoin / MakeScripts

Method MakeScripts

src/script/descriptor.cpp:1675–1687  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1673
1674protected:
1675 std::vector<CScript> MakeScripts(const std::vector<CPubKey>& keys, std::span<const CScript> scripts,
1676 FlatSigningProvider& provider) const override
1677 {
1678 const auto script_ctx{m_node.GetMsCtx()};
1679 for (const auto& key : keys) {
1680 if (miniscript::IsTapscript(script_ctx)) {
1681 provider.pubkeys.emplace(Hash160(XOnlyPubKey{key}), key);
1682 } else {
1683 provider.pubkeys.emplace(key.GetID(), key);
1684 }
1685 }
1686 return Vector(m_node.ToScript(ScriptMaker(keys, script_ctx)));
1687 }
1688
1689public:
1690 MiniscriptDescriptor(std::vector<std::unique_ptr<PubkeyProvider>> providers, miniscript::Node<uint32_t>&& node)

Callers

nothing calls this directly

Calls 8

IsTapscriptFunction · 0.85
Hash160Function · 0.85
VectorFunction · 0.85
ScriptMakerClass · 0.85
GetMsCtxMethod · 0.80
emplaceMethod · 0.80
ToScriptMethod · 0.80
GetIDMethod · 0.45

Tested by

no test coverage detected