|
|
@@ -32,10 +32,14 @@ template<typename Type>
|
|
|
|
|
|
template<typename Type>
|
|
|
[[nodiscard]] constexpr auto stripped_type_name() noexcept {
|
|
|
+#if defined ENTT_PRETTY_FUNCTION
|
|
|
const std::string_view full_name{pretty_function<Type>()};
|
|
|
auto first = full_name.find_first_not_of(' ', full_name.find_first_of(ENTT_PRETTY_FUNCTION_PREFIX) + 1);
|
|
|
auto value = full_name.substr(first, full_name.find_last_of(ENTT_PRETTY_FUNCTION_SUFFIX) - first);
|
|
|
return value;
|
|
|
+#else
|
|
|
+ return std::string_view{};
|
|
|
+#endif
|
|
|
}
|
|
|
|
|
|
template<typename Type, auto = stripped_type_name<Type>().find_first_of('.')>
|