node::AddMerkleRootAndCoinbase

Insert the coinbase transaction and compute the merkle root of a block.

Synopsis

Declared in <node/miner.h>

void
AddMerkleRootAndCoinbase(
    CBlock& block,
    CTransactionRef coinbase,
    uint32_t version,
    uint32_t timestamp,
    uint32_t nonce);

Parameters

NameDescription
blockThe block to finalize.
coinbaseThe coinbase transaction to insert.
versionThe block version to set.
timestampThe block time to set.
nonceThe block nonce to set.