summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorDan Goodliffe <dan@randomdan.homeip.net>2021-08-02 21:12:30 +0100
committerDan Goodliffe <dan@randomdan.homeip.net>2021-08-02 21:12:30 +0100
commit0024796587b21df96e3264a24cab7384291a1b00 (patch)
tree02921f1576e553dc1553ee0e8a0b2a79e75d6065 /lib
parentMake BitSet copyable (diff)
downloadmygrate-0024796587b21df96e3264a24cab7384291a1b00.tar.bz2
mygrate-0024796587b21df96e3264a24cab7384291a1b00.tar.xz
mygrate-0024796587b21df96e3264a24cab7384291a1b00.zip
Assert DbValue is copyable and moveable
Diffstat (limited to 'lib')
-rw-r--r--lib/dbTypes.cpp18
1 files changed, 18 insertions, 0 deletions
diff --git a/lib/dbTypes.cpp b/lib/dbTypes.cpp
index c848045..56e7a86 100644
--- a/lib/dbTypes.cpp
+++ b/lib/dbTypes.cpp
@@ -18,3 +18,21 @@ namespace std {
return std::visit(write {strm}, v);
}
}
+
+static_assert(std::is_copy_assignable_v<MyGrate::Date>);
+static_assert(std::is_copy_assignable_v<MyGrate::Time>);
+static_assert(std::is_copy_assignable_v<MyGrate::DateTime>);
+static_assert(std::is_copy_assignable_v<MyGrate::Blob>);
+static_assert(std::is_copy_assignable_v<timespec>);
+static_assert(std::is_copy_assignable_v<MyGrate::BitSet>);
+static_assert(std::is_copy_assignable_v<MyGrate::DbValueV>);
+static_assert(std::is_copy_assignable_v<MyGrate::DbValue>);
+
+static_assert(std::is_move_assignable_v<MyGrate::Date>);
+static_assert(std::is_move_assignable_v<MyGrate::Time>);
+static_assert(std::is_move_assignable_v<MyGrate::DateTime>);
+static_assert(std::is_move_assignable_v<MyGrate::Blob>);
+static_assert(std::is_move_assignable_v<timespec>);
+static_assert(std::is_move_assignable_v<MyGrate::BitSet>);
+static_assert(std::is_move_assignable_v<MyGrate::DbValueV>);
+static_assert(std::is_move_assignable_v<MyGrate::DbValue>);