Skip to content

Commit 46f8427

Browse files
authored
Merge pull request #226 from evoskuil/version3
Remove unnecessary const on `operator const bool() const`.
2 parents f4ae48d + 52f36d4 commit 46f8427

10 files changed

Lines changed: 13 additions & 13 deletions

File tree

.appveyor.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,16 +15,16 @@ environment:
1515
matrix:
1616
- configuration: StaticDebug
1717
platform: x64
18-
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"
18+
BOOST_UNIT_TEST_OPTIONS: "--run_test=* --show_progress=no --detect_memory_leak=0 --report_level=no --build_info=yes"
1919
- configuration: StaticRelease
2020
platform: x64
21-
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"
21+
BOOST_UNIT_TEST_OPTIONS: "--run_test=* --show_progress=no --detect_memory_leak=0 --report_level=no --build_info=yes"
2222
- configuration: StaticDebug
2323
platform: Win32
24-
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"
24+
BOOST_UNIT_TEST_OPTIONS: "--run_test=* --show_progress=no --detect_memory_leak=0 --report_level=no --build_info=yes"
2525
- configuration: StaticRelease
2626
platform: Win32
27-
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"
27+
BOOST_UNIT_TEST_OPTIONS: "--run_test=* --show_progress=no --detect_memory_leak=0 --report_level=no --build_info=yes"
2828

2929
matrix:
3030
fast_finish: true

include/bitcoin/protocol/zmq/certificate.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ class BCP_API certificate
4343
certificate(const config::sodium& private_key);
4444

4545
/// True if the certificate is valid.
46-
operator const bool() const;
46+
operator bool() const;
4747

4848
/// The public key base85 text.
4949
const config::sodium& public_key() const;

include/bitcoin/protocol/zmq/context.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ class BCP_API context
4545
virtual ~context();
4646

4747
/// True if the context is valid and started.
48-
operator const bool() const;
48+
operator bool() const;
4949

5050
/// The underlying zeromq context.
5151
void* self();

include/bitcoin/protocol/zmq/frame.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ class BCP_API frame
4747
virtual ~frame();
4848

4949
/// True if the construction was successful.
50-
operator const bool() const;
50+
operator bool() const;
5151

5252
/// True if there is more data to receive.
5353
bool more() const;

include/bitcoin/protocol/zmq/socket.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ class BCP_API socket
8080
virtual bool stop();
8181

8282
/// True if the socket is valid.
83-
operator const bool() const;
83+
operator bool() const;
8484

8585
/// The underlying zeromq socket.
8686
void* self();

libbitcoin-protocol-test_runner.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
# Define tests and options.
1010
#==============================================================================
1111
BOOST_UNIT_TEST_OPTIONS=\
12-
"--run_test=authenticator_tests,certificate_tests,context_tests,frame_tests,identifiers_tests,message_tests,poller_tests,socket_tests,worker_tests "\
12+
"--run_test=* "\
1313
"--show_progress=no "\
1414
"--detect_memory_leak=0 "\
1515
"--report_level=no "\

src/zmq/certificate.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@ bool certificate::create(config::sodium& out_public,
9797
return false;
9898
}
9999

100-
certificate::operator const bool() const
100+
certificate::operator bool() const
101101
{
102102
return public_;
103103
}

src/zmq/context.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ bool context::stop()
7474
///////////////////////////////////////////////////////////////////////////
7575
}
7676

77-
context::operator const bool() const
77+
context::operator bool() const
7878
{
7979
return self_ != nullptr;
8080
}

src/zmq/frame.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ bool frame::initialize(const data_chunk& data)
6767
return true;
6868
}
6969

70-
frame::operator const bool() const
70+
frame::operator bool() const
7171
{
7272
return valid_;
7373
}

src/zmq/socket.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -190,7 +190,7 @@ bool socket::stop()
190190
return true;
191191
}
192192

193-
socket::operator const bool() const
193+
socket::operator bool() const
194194
{
195195
return self_ != nullptr;
196196
}

0 commit comments

Comments
 (0)