Repository: bitcoin/bitcoin
File: src/interfaces/mining.h (C/C++)

Code before:

    virtual CBlockHeader getBlockHeader() = 0;
    // Block contains a dummy coinbase transaction that should not be used.
    virtual CBlock getBlock() = 0;

    // Fees per transaction, not including coinbase transaction.
    virtual std::vector<CAmount> getTxFees() = 0;
    // Sigop cost per transaction, not including coinbase transaction.
    virtual std::vector<int64_t> getTxSigops() = 0;

    /** Return fields needed to construct a coinbase transaction */
    virtual node::CoinbaseTemplate getCoinbase() = 0;
    /**
     * Return dummy coinbase transaction.
     *
     * @note deprecated: use getCoinbase()
     **/
    virtual CTransactionRef getCoinbaseTx() = 0;
    /**
     * Return scriptPubKey with SegWit OP_RETURN.
     */
    virtual std::vector<unsigned char> getCoinbaseCommitment() = 0;
    /**
     * Return which output in the dummy coinbase contains the SegWit OP_RETURN.
     *
     * @note deprecated. Scan outputs from getCoinbase() outputs field for the
     *       SegWit marker.
     */
    virtual int getWitnessCommitmentIndex() = 0;

    /**
     * Compute merkle path to the coinbase transaction
     *
     * @return merkle path ordered from the deepest
     */
    virtual std::vector<uint256> getCoinbaseMerklePath() = 0;

    /**
     * Construct and broadcast the block. Modifies the template in place,
     * updating the fields listed below as well as the merkle root.
     *
     * @param[in] version version block header field
     * @param[in] timestamp time block header field (unix timestamp)
     * @param[in] nonce nonce block header field
     * @param[in] coinbase complete coinbase transaction (including witness)
     *
     * @note unlike the submitblock RPC, this method does NOT add the
     *       coinbase witness automatically.
     *
     * @returns if the block was processed, does not necessarily indicate validity.
     *

Review comment (suggestion):
In commit "mining: add getCoinbase()" (73553c809ef6517839c4d1b02b657e6fa401f8a8)

Was it intentional not to include the "note deprecated: use getCoinbase()" comment on this method? Would be good to include if not.

Code after:

    virtual CBlockHeader getBlockHeader() = 0;
    // Block contains a dummy coinbase transaction that should not be used.
    virtual CBlock getBlock() = 0;

    // Fees per transaction, not including coinbase transaction.
    virtual std::vector<CAmount> getTxFees() = 0;
    // Sigop cost per transaction, not including coinbase transaction.
    virtual std::vector<int64_t> getTxSigops() = 0;

    /**
     * Return serialized dummy coinbase transaction.
     *
     * @note deprecated: use getCoinbaseTx()
     */
    virtual CTransactionRef getCoinbaseRawTx() = 0;

    /** Return fields needed to construct a coinbase transaction */
    virtual node::CoinbaseTx getCoinbaseTx() = 0;

    /**
     * Return scriptPubKey with SegWit OP_RETURN.
     *
     * @note deprecated: use getCoinbaseTx()
     */
    virtual std::vector<unsigned char> getCoinbaseCommitment() = 0;

    /**
     * Return which output in the dummy coinbase contains the SegWit OP_RETURN.
     *
     * @note deprecated. Scan outputs from getCoinbaseTx() outputs field for the
     *       SegWit marker.
     */
    virtual int getWitnessCommitmentIndex() = 0;

    /**
     * Compute merkle path to the coinbase transaction
     *
     * @return merkle path ordered from the deepest
     */
    virtual std::vector<uint256> getCoinbaseMerklePath() = 0;

    /**
     * Construct and broadcast the block. Modifies the template in place,
     * updating the fields listed below as well as the merkle root.
     *
     * @param[in] version version block header field
     * @param[in] timestamp time block header field (unix timestamp)
     * @param[in] nonce nonce block header field
     * @param[in] coinbase complete coinbase transaction (including witness)
     *