Skip to content

Commit 99a4c48

Browse files
committed
Reduce warnings.
1 parent 7c879ba commit 99a4c48

File tree

8 files changed

+9
-9
lines changed

8 files changed

+9
-9
lines changed

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();

src/zmq/certificate.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ bool certificate::derive(config::sodium& out_public,
7070
static inline bool ok_setting(const std::string& key)
7171
{
7272
return key.find_first_of('#') == std::string::npos;
73-
};
73+
}
7474

7575
bool certificate::create(config::sodium& out_public,
7676
config::sodium& out_private, bool setting)
@@ -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)