Skip to content

Commit 5541f7c

Browse files
committed
Merge bitcoin/bitcoin#32187: refactor: Remove spurious virtual from final ~CZMQNotificationInterface
fa69c42 refactor: Remove spurious virtual from final ~CZMQNotificationInterface (MarcoFalke) Pull request description: `virtual` does not make sense here, because: * The class is `final`, thus the destructor isn't overridden in a derived class * The destructor also isn't overriding the destructor of the base, clarified in commit 2b3ea39 * Clang 21 may warn about this ``` src/zmq/zmqnotificationinterface.h:25:13: error: virtual method '~CZMQNotificationInterface' is inside a 'final' class and can never be overridden [-Werror,-Wunnecessary-virtual-specifier] 25 | virtual ~CZMQNotificationInterface(); | ^ ``` Fix all issues by removing it. ACKs for top commit: davidgumberg: crACK bitcoin/bitcoin@fa69c42 janb84: ACK [fa69c42](bitcoin/bitcoin@fa69c42) TheCharlatan: ACK fa69c42 Tree-SHA512: 26ea977f31fe24c116d68dea6c583de7c6fc480877e1baefcde11db4ac191e352027d492ee6ad69a60fe4ff537e0841c638b3a3e81356d9e00c60030845fc96e
2 parents 6f6f83a + fa69c42 commit 5541f7c

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/zmq/zmqnotificationinterface.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// Copyright (c) 2015-2022 The Bitcoin Core developers
1+
// Copyright (c) 2015-present The Bitcoin Core developers
22
// Distributed under the MIT software license, see the accompanying
33
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
44

@@ -22,7 +22,7 @@ struct NewMempoolTransactionInfo;
2222
class CZMQNotificationInterface final : public CValidationInterface
2323
{
2424
public:
25-
virtual ~CZMQNotificationInterface();
25+
~CZMQNotificationInterface();
2626

2727
std::list<const CZMQAbstractNotifier*> GetActiveNotifiers() const;
2828

0 commit comments

Comments
 (0)