0
0
mirror of https://github.com/rbock/sqlpp11.git synced 2024-11-16 04:47:18 +08:00

Add argumentless overload for get_sql_name()

Comes handy with template metaprogramming.
This commit is contained in:
Marcell Egyed 2024-09-11 10:19:59 +02:00 committed by Roland Bock
parent a710e8bd89
commit fc23782369

View File

@ -130,9 +130,15 @@ namespace sqlpp
return {c};
}
template <typename T>
constexpr const char* get_sql_name(const T& /*unused*/)
{
return name_of<T>::template char_ptr<void>();
template <typename T>
constexpr const char* get_sql_name()
{
return name_of<T>::template char_ptr<void>();
}
template <typename T>
constexpr const char* get_sql_name(const T& /*unused*/)
{
return get_sql_name<T>();
}
} // namespace sqlpp