0
0
mirror of https://github.com/rbock/sqlpp11.git synced 2024-12-25 23:40:50 +08:00

Make current_*_t function constructors default and remove implicit name

This commit is contained in:
vaijns 2024-12-07 13:37:45 +01:00 committed by Roland Bock
parent 5b3b623d1c
commit 12a30f9112
3 changed files with 3 additions and 78 deletions

View File

@ -35,32 +35,7 @@ namespace sqlpp
{ {
using _traits = make_traits<day_point, tag::is_expression, tag::is_selectable>; using _traits = make_traits<day_point, tag::is_expression, tag::is_selectable>;
using _nodes = detail::type_vector<>; constexpr current_date_t() = default;
using _can_be_null = std::false_type;
struct _alias_t
{
static constexpr const char _literal[] = "current_date_";
using _name_t = sqlpp::make_char_sequence<sizeof(_literal), _literal>;
template <typename T>
struct _member_t
{
T current_date;
T& operator()()
{
return current_date;
}
const T& operator()() const
{
return current_date;
}
};
};
constexpr current_date_t()
{
}
current_date_t(const current_date_t&) = default; current_date_t(const current_date_t&) = default;
current_date_t(current_date_t&&) = default; current_date_t(current_date_t&&) = default;
current_date_t& operator=(const current_date_t&) = default; current_date_t& operator=(const current_date_t&) = default;

View File

@ -35,32 +35,7 @@ namespace sqlpp
{ {
using _traits = make_traits<time_of_day, tag::is_expression, tag::is_selectable>; using _traits = make_traits<time_of_day, tag::is_expression, tag::is_selectable>;
using _nodes = detail::type_vector<>; constexpr current_time_t() = default;
using _can_be_null = std::false_type;
struct _alias_t
{
static constexpr const char _literal[] = "current_time_";
using _name_t = sqlpp::make_char_sequence<sizeof(_literal), _literal>;
template <typename T>
struct _member_t
{
T current_time;
T& operator()()
{
return current_time;
}
const T& operator()() const
{
return current_time;
}
};
};
constexpr current_time_t()
{
}
current_time_t(const current_time_t&) = default; current_time_t(const current_time_t&) = default;
current_time_t(current_time_t&&) = default; current_time_t(current_time_t&&) = default;
current_time_t& operator=(const current_time_t&) = default; current_time_t& operator=(const current_time_t&) = default;

View File

@ -35,32 +35,7 @@ namespace sqlpp
{ {
using _traits = make_traits<time_point, tag::is_expression, tag::is_selectable>; using _traits = make_traits<time_point, tag::is_expression, tag::is_selectable>;
using _nodes = detail::type_vector<>; constexpr current_timestamp_t() = default;
using _can_be_null = std::false_type;
struct _alias_t
{
static constexpr const char _literal[] = "current_timestamp_";
using _name_t = sqlpp::make_char_sequence<sizeof(_literal), _literal>;
template <typename T>
struct _member_t
{
T current_timestamp;
T& operator()()
{
return current_timestamp;
}
const T& operator()() const
{
return current_timestamp;
}
};
};
constexpr current_timestamp_t()
{
}
current_timestamp_t(const current_timestamp_t&) = default; current_timestamp_t(const current_timestamp_t&) = default;
current_timestamp_t(current_timestamp_t&&) = default; current_timestamp_t(current_timestamp_t&&) = default;
current_timestamp_t& operator=(const current_timestamp_t&) = default; current_timestamp_t& operator=(const current_timestamp_t&) = default;