12 std::string_view
name =
"Error: unsupported compiler", prefix,
suffix;
14 name = __PRETTY_FUNCTION__;
15 prefix =
"auto type_name() [T = ";
17 #elif defined(__GNUC__)
18 name = __PRETTY_FUNCTION__;
19 prefix =
"constexpr auto type_name() [with T = ";
21 #elif defined(_MSC_VER)
23 prefix =
"auto __cdecl type_name<";
24 suffix =
">(void) noexcept";
26 name.remove_prefix(prefix.size());
27 name.remove_suffix(suffix.size());
33 static_assert(std::is_enum_v<decltype(E)>);
34 std::string_view
name =
"Error: unsupported compiler", prefix,
suffix;
36 name = __PRETTY_FUNCTION__;
37 prefix =
"auto enum_name() [E = ";
39 #elif defined(__GNUC__)
40 name = __PRETTY_FUNCTION__;
41 prefix =
"constexpr auto enum_name() [with auto E = ";
43 #elif defined(_MSC_VER)
45 prefix =
"auto __cdecl enum_name<";
46 suffix =
">(void) noexcept";
48 name.remove_prefix(prefix.size());
49 name.remove_suffix(suffix.size());
50 if (
const auto pos = name.find_last_of(
":)"); pos != std::string_view::npos) {
51 name.remove_prefix(pos + 1);
constexpr auto enum_name() noexcept
std::string suffix(SQLTypes type)
constexpr auto type_name() noexcept