From 5e92b9113f41860ae36a47421fc2e6641f2a6cc7 Mon Sep 17 00:00:00 2001 From: skypjack Date: Wed, 28 Jan 2026 12:27:55 +0100 Subject: [PATCH] component_traits: refine internal checks --- src/entt/entity/component.hpp | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/src/entt/entity/component.hpp b/src/entt/entity/component.hpp index 87def9c51..080643ba8 100644 --- a/src/entt/entity/component.hpp +++ b/src/entt/entity/component.hpp @@ -1,6 +1,7 @@ #ifndef ENTT_ENTITY_COMPONENT_HPP #define ENTT_ENTITY_COMPONENT_HPP +#include #include #include #include "../config/config.h" @@ -11,25 +12,25 @@ namespace entt { /*! @cond ENTT_INTERNAL */ namespace internal { -template +template struct in_place_delete: std::bool_constant && std::is_move_assignable_v)> {}; template<> struct in_place_delete: std::false_type {}; template -struct in_place_delete> - : std::true_type {}; +requires Type::in_place_delete +struct in_place_delete: std::true_type {}; -template +template struct page_size: std::integral_constant * ENTT_PACKED_PAGE> {}; template<> struct page_size: std::integral_constant {}; template -struct page_size> - : std::integral_constant {}; +requires std::is_convertible_v +struct page_size: std::integral_constant {}; } // namespace internal /*! @endcond */