Skip to content

Commit 9a60ad3

Browse files
sigiesecgummif
andauthored
Apply suggestions from code review
Co-Authored-By: gummif <[email protected]>
1 parent 3d4be81 commit 9a60ad3

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

tests/socket.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ TEST_CASE("socket swap", "[socket]")
4848
}
4949
TEST_CASE("rass", "[socket]")
5050
{
51-
zmq::context_t ctx;
51+
zmq::context_t ctx;
5252
zmq::socket_t sock(ctx, zmq::socket_type::push);
5353
sock.bind("inproc://test");
5454
const std::string m = "Hello, world";

zmq.hpp

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -280,7 +280,7 @@ class message_t
280280
}
281281

282282
#if defined(ZMQ_BUILD_DRAFT_API) && defined(ZMQ_CPP11)
283-
// this function is too greedy, must add
283+
// TODO: this function is too greedy, must add
284284
// SFINAE for begin and end support.
285285
template<typename T>
286286
explicit message_t(const T &msg_) : message_t(std::begin(msg_), std::end(msg_))
@@ -654,7 +654,8 @@ enum class send_flags : int
654654

655655
constexpr send_flags operator|(send_flags a, send_flags b) noexcept
656656
{
657-
return static_cast<send_flags>(static_cast<int>(a) | static_cast<int>(b));
657+
return static_cast<send_flags>(static_cast<std::underlying_type<send_flags>::type>(a)
658+
| static_cast<<std::underlying_type<send_flags>::type>(b));
658659
}
659660

660661
enum class recv_flags : int

0 commit comments

Comments
 (0)