Skip to content

Commit

Permalink
Merge pull request #226 from evoskuil/version3
Browse files Browse the repository at this point in the history
Remove unnecessary const on `operator const bool() const`.
  • Loading branch information
evoskuil committed Apr 2, 2021
2 parents f4ae48d + 52f36d4 commit 46f8427
Show file tree
Hide file tree
Showing 10 changed files with 13 additions and 13 deletions.
8 changes: 4 additions & 4 deletions .appveyor.yml
Expand Up @@ -15,16 +15,16 @@ environment:
matrix:
- configuration: StaticDebug
platform: x64
BOOST_UNIT_TEST_OPTIONS: "--run_test=authenticator_tests,certificate_tests,context_tests,frame_tests,identifiers_tests,message_tests,poller_tests,socket_tests,worker_tests --show_progress=no --detect_memory_leak=0 --report_level=no --build_info=yes"
BOOST_UNIT_TEST_OPTIONS: "--run_test=* --show_progress=no --detect_memory_leak=0 --report_level=no --build_info=yes"
- configuration: StaticRelease
platform: x64
BOOST_UNIT_TEST_OPTIONS: "--run_test=authenticator_tests,certificate_tests,context_tests,frame_tests,identifiers_tests,message_tests,poller_tests,socket_tests,worker_tests --show_progress=no --detect_memory_leak=0 --report_level=no --build_info=yes"
BOOST_UNIT_TEST_OPTIONS: "--run_test=* --show_progress=no --detect_memory_leak=0 --report_level=no --build_info=yes"
- configuration: StaticDebug
platform: Win32
BOOST_UNIT_TEST_OPTIONS: "--run_test=authenticator_tests,certificate_tests,context_tests,frame_tests,identifiers_tests,message_tests,poller_tests,socket_tests,worker_tests --show_progress=no --detect_memory_leak=0 --report_level=no --build_info=yes"
BOOST_UNIT_TEST_OPTIONS: "--run_test=* --show_progress=no --detect_memory_leak=0 --report_level=no --build_info=yes"
- configuration: StaticRelease
platform: Win32
BOOST_UNIT_TEST_OPTIONS: "--run_test=authenticator_tests,certificate_tests,context_tests,frame_tests,identifiers_tests,message_tests,poller_tests,socket_tests,worker_tests --show_progress=no --detect_memory_leak=0 --report_level=no --build_info=yes"
BOOST_UNIT_TEST_OPTIONS: "--run_test=* --show_progress=no --detect_memory_leak=0 --report_level=no --build_info=yes"

matrix:
fast_finish: true
Expand Down
2 changes: 1 addition & 1 deletion include/bitcoin/protocol/zmq/certificate.hpp
Expand Up @@ -43,7 +43,7 @@ class BCP_API certificate
certificate(const config::sodium& private_key);

/// True if the certificate is valid.
operator const bool() const;
operator bool() const;

/// The public key base85 text.
const config::sodium& public_key() const;
Expand Down
2 changes: 1 addition & 1 deletion include/bitcoin/protocol/zmq/context.hpp
Expand Up @@ -45,7 +45,7 @@ class BCP_API context
virtual ~context();

/// True if the context is valid and started.
operator const bool() const;
operator bool() const;

/// The underlying zeromq context.
void* self();
Expand Down
2 changes: 1 addition & 1 deletion include/bitcoin/protocol/zmq/frame.hpp
Expand Up @@ -47,7 +47,7 @@ class BCP_API frame
virtual ~frame();

/// True if the construction was successful.
operator const bool() const;
operator bool() const;

/// True if there is more data to receive.
bool more() const;
Expand Down
2 changes: 1 addition & 1 deletion include/bitcoin/protocol/zmq/socket.hpp
Expand Up @@ -80,7 +80,7 @@ class BCP_API socket
virtual bool stop();

/// True if the socket is valid.
operator const bool() const;
operator bool() const;

/// The underlying zeromq socket.
void* self();
Expand Down
2 changes: 1 addition & 1 deletion libbitcoin-protocol-test_runner.sh
Expand Up @@ -9,7 +9,7 @@
# Define tests and options.
#==============================================================================
BOOST_UNIT_TEST_OPTIONS=\
"--run_test=authenticator_tests,certificate_tests,context_tests,frame_tests,identifiers_tests,message_tests,poller_tests,socket_tests,worker_tests "\
"--run_test=* "\
"--show_progress=no "\
"--detect_memory_leak=0 "\
"--report_level=no "\
Expand Down
2 changes: 1 addition & 1 deletion src/zmq/certificate.cpp
Expand Up @@ -97,7 +97,7 @@ bool certificate::create(config::sodium& out_public,
return false;
}

certificate::operator const bool() const
certificate::operator bool() const
{
return public_;
}
Expand Down
2 changes: 1 addition & 1 deletion src/zmq/context.cpp
Expand Up @@ -74,7 +74,7 @@ bool context::stop()
///////////////////////////////////////////////////////////////////////////
}

context::operator const bool() const
context::operator bool() const
{
return self_ != nullptr;
}
Expand Down
2 changes: 1 addition & 1 deletion src/zmq/frame.cpp
Expand Up @@ -67,7 +67,7 @@ bool frame::initialize(const data_chunk& data)
return true;
}

frame::operator const bool() const
frame::operator bool() const
{
return valid_;
}
Expand Down
2 changes: 1 addition & 1 deletion src/zmq/socket.cpp
Expand Up @@ -190,7 +190,7 @@ bool socket::stop()
return true;
}

socket::operator const bool() const
socket::operator bool() const
{
return self_ != nullptr;
}
Expand Down

0 comments on commit 46f8427

Please sign in to comment.