mirror of
https://github.com/zeromq/cppzmq.git
synced 2024-12-13 10:52:57 +01:00
Use deleted functions if available
This commit is contained in:
parent
36722d9031
commit
02ceef1727
19
zmq.hpp
19
zmq.hpp
@ -37,14 +37,20 @@
|
|||||||
(__GNUC__ == 4 && __GNUC_MINOR__ > 2)) && \
|
(__GNUC__ == 4 && __GNUC_MINOR__ > 2)) && \
|
||||||
defined(__GXX_EXPERIMENTAL_CXX0X__))
|
defined(__GXX_EXPERIMENTAL_CXX0X__))
|
||||||
#define ZMQ_HAS_RVALUE_REFS
|
#define ZMQ_HAS_RVALUE_REFS
|
||||||
#endif
|
#define ZMQ_DELETED_FUNCTION = delete
|
||||||
#if (defined(__clang__))
|
#elif defined(__clang__)
|
||||||
#if __has_feature(cxx_rvalue_references)
|
#if __has_feature(cxx_rvalue_references)
|
||||||
#define ZMQ_HAS_RVALUE_REFS
|
#define ZMQ_HAS_RVALUE_REFS
|
||||||
#endif
|
#endif
|
||||||
#endif
|
|
||||||
#if (defined(_MSC_VER) && (_MSC_VER >= 1600))
|
#if __has_feature(cxx_deleted_functions)
|
||||||
|
#define ZMQ_DELETED_FUNCTION = delete
|
||||||
|
#endif
|
||||||
|
#elif defined(_MSC_VER) && (_MSC_VER >= 1600)
|
||||||
#define ZMQ_HAS_RVALUE_REFS
|
#define ZMQ_HAS_RVALUE_REFS
|
||||||
|
#define ZMQ_DELETED_FUNCTION
|
||||||
|
#else
|
||||||
|
#define ZMQ_DELETED_FUNCTION
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
// In order to prevent unused variable warnings when building in non-debug
|
// In order to prevent unused variable warnings when building in non-debug
|
||||||
@ -392,11 +398,10 @@ namespace zmq
|
|||||||
|
|
||||||
void *ptr;
|
void *ptr;
|
||||||
|
|
||||||
socket_t (const socket_t&);
|
socket_t (const socket_t&) ZMQ_DELETED_FUNCTION;
|
||||||
void operator = (const socket_t&);
|
void operator = (const socket_t&) ZMQ_DELETED_FUNCTION;
|
||||||
};
|
};
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user