diff --git a/deps/ox/src/ox/model/typenamecatcher.hpp b/deps/ox/src/ox/model/typenamecatcher.hpp index 3a593879..fdb62c9e 100644 --- a/deps/ox/src/ox/model/typenamecatcher.hpp +++ b/deps/ox/src/ox/model/typenamecatcher.hpp @@ -61,6 +61,13 @@ constexpr Str getModelTypeName(T *val) noexcept { return nc.name; } +template +consteval auto requireModelTypeName() noexcept { + constexpr auto name = getModelTypeName(); + static_assert(ox_strcmp(name, "") != 0, "TypeName is required"); + return name; +} + template constexpr auto ModelTypeName_v = getModelTypeName();