EnTT 3.13.0
Loading...
Searching...
No Matches
family.hpp
1#ifndef ENTT_CORE_FAMILY_HPP
2#define ENTT_CORE_FAMILY_HPP
3
4#include "../config/config.h"
5#include "fwd.hpp"
6
7namespace entt {
8
16template<typename...>
17class family {
18 inline static ENTT_MAYBE_ATOMIC(id_type) identifier{};
19
20public:
23
25 template<typename... Type>
26 // at the time I'm writing, clang crashes during compilation if auto is used instead of family_type
27 inline static const value_type value = identifier++;
28};
29
30} // namespace entt
31
32#endif
Dynamic identifier generator.
Definition family.hpp:17
id_type value_type
Unsigned integer type.
Definition family.hpp:22
EnTT default namespace.
Definition dense_map.hpp:21
std::uint32_t id_type
Alias declaration for type identifiers.
Definition fwd.hpp:13