aboutsummaryrefslogtreecommitdiff
path: root/lib/util.h
diff options
context:
space:
mode:
authorKitsune Ral <Kitsune-Ral@users.sf.net>2018-07-07 10:30:21 +0900
committerKitsune Ral <Kitsune-Ral@users.sf.net>2018-07-07 10:30:21 +0900
commit1742f6e0f0af6aa6deefe2cee4bc41877f4ac2ad (patch)
tree41736eeec46c6d8a5d5598d059f093fb06bebcb5 /lib/util.h
parent552475704351e68a3983348de39aa60620e1578d (diff)
downloadlibquotient-1742f6e0f0af6aa6deefe2cee4bc41877f4ac2ad.tar.gz
libquotient-1742f6e0f0af6aa6deefe2cee4bc41877f4ac2ad.zip
util.h: DISABLE_MOVE macro
Diffstat (limited to 'lib/util.h')
-rw-r--r--lib/util.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/util.h b/lib/util.h
index 28315429..78d90626 100644
--- a/lib/util.h
+++ b/lib/util.h
@@ -35,6 +35,11 @@
#define FALLTHROUGH // -fallthrough
#endif
+// Along the lines of Q_DISABLE_COPY
+#define DISABLE_MOVE(_ClassName) \
+ _ClassName(_ClassName&&) Q_DECL_EQ_DELETE; \
+ _ClassName& operator=(_ClassName&&) Q_DECL_EQ_DELETE;
+
namespace QMatrixClient
{
// The below enables pretty-printing of enums in logs