summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2022-10-22 16:02:38 +0200
committerStanislaw Halik <sthalik@misaki.pl>2022-10-22 16:02:38 +0200
commitaa03952cb2a889f8d81a70ed4bd0b4ae69e5ab8d (patch)
treeed3cddb43ce68623f80a975deecdabb8609f72ae
parenta9fe1476f1508619fc7d5f994164e04e0dfc184a (diff)
add macros
-rw-r--r--compat/defs.hpp14
1 files changed, 13 insertions, 1 deletions
diff --git a/compat/defs.hpp b/compat/defs.hpp
index 1bd0f181..de922df2 100644
--- a/compat/defs.hpp
+++ b/compat/defs.hpp
@@ -16,6 +16,10 @@
constexpr type(const type&) noexcept = default; \
constexpr type& operator=(const type&) noexcept = default
+#define fm_DECLARE_DEFAULT_COPY_ASSIGNMENT_(type) \
+ type(const type&) noexcept = default; \
+ type& operator=(const type&) noexcept = default
+
#define fm_DECLARE_DELETED_COPY_ASSIGNMENT(type) \
type(const type&) = delete; \
type& operator=(const type&) = delete
@@ -28,6 +32,14 @@
constexpr type(type&&) noexcept = default; \
constexpr type& operator=(type&&) noexcept = default
+#define fm_DECLARE_DEFAULT_MOVE_ASSIGNMENT_(type) \
+ type(type&&) noexcept = default; \
+ type& operator=(type&&) noexcept = default
+
#define fm_DECLARE_DEFAULT_MOVE_COPY_ASSIGNMENTS(type) \
- fm_DECLARE_DEFAULT_MOVE_ASSIGNMENT(type); \
+ fm_DECLARE_DEFAULT_MOVE_ASSIGNMENT(type); \
fm_DECLARE_DEFAULT_COPY_ASSIGNMENT(type)
+
+#define fm_DECLARE_DEFAULT_MOVE_COPY_ASSIGNMENTS_(type) \
+ fm_DECLARE_DEFAULT_MOVE_ASSIGNMENT_(type); \
+ fm_DECLARE_DEFAULT_COPY_ASSIGNMENT_(type)