mirror of
https://github.com/ElementsProject/elements.git
synced 2026-08-20 13:37:28 +02:00
Mark single-argument constructors "explicit"
This commit is contained in:
parent
415f2bff69
commit
1ac3c983bf
8 changed files with 9 additions and 9 deletions
|
|
@ -29,7 +29,7 @@ BOOST_FIXTURE_TEST_SUITE(miner_tests, TestingSetup)
|
|||
// BOOST_CHECK_EXCEPTION predicates to check the specific validation error
|
||||
class HasReason {
|
||||
public:
|
||||
HasReason(const std::string& reason) : m_reason(reason) {}
|
||||
explicit HasReason(const std::string& reason) : m_reason(reason) {}
|
||||
bool operator() (const std::runtime_error& e) const {
|
||||
return std::string(e.what()).find(m_reason) != std::string::npos;
|
||||
};
|
||||
|
|
|
|||
|
|
@ -23,7 +23,7 @@ BOOST_FIXTURE_TEST_SUITE(validation_block_tests, RegtestingSetup)
|
|||
struct TestSubscriber : public CValidationInterface {
|
||||
uint256 m_expected_tip;
|
||||
|
||||
TestSubscriber(uint256 tip) : m_expected_tip(tip) {}
|
||||
explicit TestSubscriber(uint256 tip) : m_expected_tip(tip) {}
|
||||
|
||||
void UpdatedBlockTip(const CBlockIndex* pindexNew, const CBlockIndex* pindexFork, bool fInitialDownload) override
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue