]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
crimson/common: assert_moveable() doesn't depend on 3rd party's always_false<>.
authorRadoslaw Zarzynski <rzarzyns@redhat.com>
Tue, 21 Sep 2021 21:28:02 +0000 (21:28 +0000)
committerRadoslaw Zarzynski <rzarzyns@redhat.com>
Tue, 21 Sep 2021 21:28:02 +0000 (21:28 +0000)
Signed-off-by: Radoslaw Zarzynski <rzarzyns@redhat.com>
src/crimson/common/utility.h

index 42c199a959dfad227102b204fa0ddcfdae04a097..6fc50bb1c1a10cd1cc7a1f8e5e78e2d4a0053b38 100644 (file)
@@ -5,12 +5,16 @@
 
 #include <type_traits>
 
+namespace _impl {
+  template <class T> struct always_false : std::false_type {};
+};
+
 template <class T>
 void assert_moveable(T& t) {
     // It's fine
 }
 template <class T>
 void assert_moveable(const T& t) {
-    static_assert(always_false<T>::value, "unable to move-out from T");
+    static_assert(_impl::always_false<T>::value, "unable to move-out from T");
 }