Parcourir la source

stl: std::is_move_assignable_v

skypjack il y a 1 jour
Parent
commit
10bfb24bf1

+ 1 - 1
src/entt/core/any.hpp

@@ -75,7 +75,7 @@ class basic_any: private internal::basic_any_storage<Len, Align> {
         case info:
         case info:
             return &type_id<Type>();
             return &type_id<Type>();
         case transfer:
         case transfer:
-            if constexpr(std::is_move_assignable_v<Type>) {
+            if constexpr(stl::is_move_assignable_v<Type>) {
                 // NOLINTNEXTLINE(bugprone-casting-through-void)
                 // NOLINTNEXTLINE(bugprone-casting-through-void)
                 *const_cast<Type *>(elem) = stl::move(*static_cast<Type *>(const_cast<void *>(other)));
                 *const_cast<Type *>(elem) = stl::move(*static_cast<Type *>(const_cast<void *>(other)));
                 return other;
                 return other;

+ 1 - 1
src/entt/entity/component.hpp

@@ -14,7 +14,7 @@ namespace entt {
 namespace internal {
 namespace internal {
 
 
 template<typename Type>
 template<typename Type>
-struct in_place_delete: std::bool_constant<!(std::is_move_constructible_v<Type> && std::is_move_assignable_v<Type>)> {};
+struct in_place_delete: std::bool_constant<!(std::is_move_constructible_v<Type> && stl::is_move_assignable_v<Type>)> {};
 
 
 template<>
 template<>
 struct in_place_delete<void>: stl::false_type {};
 struct in_place_delete<void>: stl::false_type {};

+ 1 - 1
src/entt/entity/storage.hpp

@@ -298,7 +298,7 @@ private:
     }
     }
 
 
     void swap_or_move([[maybe_unused]] const std::size_t from, [[maybe_unused]] const std::size_t to) override {
     void swap_or_move([[maybe_unused]] const std::size_t from, [[maybe_unused]] const std::size_t to) override {
-        static constexpr bool is_pinned_type = !(std::is_move_constructible_v<Type> && std::is_move_assignable_v<Type>);
+        static constexpr bool is_pinned_type = !(std::is_move_constructible_v<Type> && stl::is_move_assignable_v<Type>);
         // use a runtime value to avoid compile-time suppression that drives the code coverage tool crazy
         // use a runtime value to avoid compile-time suppression that drives the code coverage tool crazy
         ENTT_ASSERT((from + 1u) && !is_pinned_type, "Pinned type");
         ENTT_ASSERT((from + 1u) && !is_pinned_type, "Pinned type");
 
 

+ 1 - 0
src/entt/stl/type_traits.hpp

@@ -16,6 +16,7 @@ using std::is_default_constructible_v;
 using std::is_invocable_r_v;
 using std::is_invocable_r_v;
 using std::is_lvalue_reference_v;
 using std::is_lvalue_reference_v;
 using std::is_member_object_pointer_v;
 using std::is_member_object_pointer_v;
+using std::is_move_assignable_v;
 using std::is_nothrow_move_constructible_v;
 using std::is_nothrow_move_constructible_v;
 using std::is_pointer_v;
 using std::is_pointer_v;
 using std::is_same_v;
 using std::is_same_v;