Browse Source

mixin: use if constexpr as it should be

Michele Caini 2 years ago
parent
commit
39f6349878
1 changed files with 1 additions and 1 deletions
  1. 1 1
      src/entt/entity/mixin.hpp

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

@@ -55,7 +55,7 @@ class sigh_mixin final: public Type {
                 if constexpr(std::is_same_v<typename underlying_type::value_type, typename underlying_type::entity_type>) {
                     destruction.publish(reg, *it);
                 } else {
-                    if(underlying_type::traits_type::in_place_delete) {
+                    if constexpr(underlying_type::traits_type::in_place_delete) {
                         if(const auto entt = *it; entt != tombstone) {
                             destruction.publish(reg, entt);
                         }