From fc8eebf3676b247e8ee284b0d49def6ef914793e Mon Sep 17 00:00:00 2001 From: Michele Caini Date: Fri, 26 May 2023 08:49:15 +0200 Subject: [PATCH] snapshot: use component_traits instead of is_empty_v --- src/entt/entity/snapshot.hpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/entt/entity/snapshot.hpp b/src/entt/entity/snapshot.hpp index feb9a37bd..90541758f 100644 --- a/src/entt/entity/snapshot.hpp +++ b/src/entt/entity/snapshot.hpp @@ -250,7 +250,7 @@ public: archive(length); - if constexpr(std::is_empty_v) { + if constexpr(Registry::template storage_for_type::traits_type::page_size == 0u) { while(length--) { archive(entt); const auto entity = storage.contains(entt) ? entt : storage.emplace(entt); @@ -426,7 +426,7 @@ class basic_continuous_loader { archive(length); - if constexpr(std::is_empty_v) { + if constexpr(Registry::template storage_for_type::traits_type::page_size == 0u) { while(length--) { archive(entt); restore(entt);