Skip to content

Commit ac705f6

Browse files
author
Andrey Sibiryov
committed
Merge pull request #43 from tolchz/master
Add an rvalue overload for socket_t::send
2 parents 403f5d6 + 67b2166 commit ac705f6

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

zmq.hpp

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -441,6 +441,13 @@ namespace zmq
441441
throw error_t ();
442442
}
443443

444+
#ifdef ZMQ_HAS_RVALUE_REFS
445+
inline bool send (message_t &&msg_, int flags_ = 0)
446+
{
447+
return send(msg_, flags_);
448+
}
449+
#endif
450+
444451
inline size_t recv (void *buf_, size_t len_, int flags_ = 0)
445452
{
446453
int nbytes = zmq_recv (ptr, buf_, len_, flags_);

0 commit comments

Comments
 (0)