stl: std::is_move_constructible_v

This commit is contained in:
skypjack
2026-04-14 14:07:41 +02:00
parent 71f3780ba7
commit 04dda74792
3 changed files with 3 additions and 2 deletions

View File

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

View File

@@ -298,7 +298,7 @@ private:
}
void swap_or_move([[maybe_unused]] const stl::size_t from, [[maybe_unused]] const stl::size_t to) override {
static constexpr bool is_pinned_type = !(std::is_move_constructible_v<Type> && stl::is_move_assignable_v<Type>);
static constexpr bool is_pinned_type = !(stl::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
ENTT_ASSERT((from + 1u) && !is_pinned_type, "Pinned type");

View File

@@ -34,6 +34,7 @@ using std::is_lvalue_reference_v;
using std::is_member_object_pointer_v;
using std::is_member_pointer_v;
using std::is_move_assignable_v;
using std::is_move_constructible_v;
using std::is_nothrow_constructible_v;
using std::is_nothrow_copy_constructible_v;
using std::is_nothrow_default_constructible_v;