Skip to content

Commit a9f6428

Browse files
author
MarcoFalke
committed
Merge bitcoin/bitcoin#23003: multiprocess: Make interfaces::Chain::isTaprootActive non-const
7e88f61 multiprocess: Make interfaces::Chain::isTaprootActive non-const (Russell Yanofsky) Pull request description: `interfaces::Chain` is an abstract class, so declaring the method const would be exposing internal implementation details of subclasses to interface callers. And specifically this doesn't work because the multiprocess implementation of the `interfaces::Chain::isTaprootActive` method can't be const because IPC connection state and request state is not constant during the call. --- This PR is part of the [process separation project](https://github.com/bitcoin/bitcoin/projects/10). ACKs for top commit: jamesob: ACK bitcoin/bitcoin@7e88f61 Tree-SHA512: 1c5ed89870aeb7170b9048c41299ab650dfa3d0978088e08c4c866fa0babb292722710b16f25540f26667220cb4747b1c256c4bd42893c552291eccc155346a3
2 parents 39872f5 + 7e88f61 commit a9f6428

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/interfaces/chain.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -289,7 +289,7 @@ class Chain
289289
virtual void requestMempoolTransactions(Notifications& notifications) = 0;
290290

291291
//! Check if Taproot has activated
292-
virtual bool isTaprootActive() const = 0;
292+
virtual bool isTaprootActive() = 0;
293293
};
294294

295295
//! Interface to let node manage chain clients (wallets, or maybe tools for

src/node/interfaces.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -698,7 +698,7 @@ class ChainImpl : public Chain
698698
notifications.transactionAddedToMempool(entry.GetSharedTx(), 0 /* mempool_sequence */);
699699
}
700700
}
701-
bool isTaprootActive() const override
701+
bool isTaprootActive() override
702702
{
703703
LOCK(::cs_main);
704704
const CBlockIndex* tip = Assert(m_node.chainman)->ActiveChain().Tip();

0 commit comments

Comments
 (0)