mirror of
https://github.com/ElementsProject/elements.git
synced 2026-08-15 12:51:00 +02:00
tidy: modernize-use-emplace
This commit is contained in:
parent
4a5aae9330
commit
fa05a726c2
47 changed files with 167 additions and 162 deletions
|
|
@ -1017,7 +1017,7 @@ CScript ScriptPubKey(MsCtx ctx, const CScript& script, TaprootBuilder& builder)
|
|||
//! Fill the witness with the data additional to the script satisfaction.
|
||||
void SatisfactionToWitness(MsCtx ctx, CScriptWitness& witness, const CScript& script, TaprootBuilder& builder) {
|
||||
// For P2WSH, it's only the witness script.
|
||||
witness.stack.push_back(std::vector<unsigned char>(script.begin(), script.end()));
|
||||
witness.stack.emplace_back(script.begin(), script.end());
|
||||
if (!miniscript::IsTapscript(ctx)) return;
|
||||
// For Tapscript we also need the control block.
|
||||
witness.stack.push_back(*builder.GetSpendData().scripts.begin()->second.begin());
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue