mirror of
https://github.com/rbock/sqlpp11.git
synced 2025-12-31 02:00:24 -06:00
Fix compile errors/warning in clang++-20
This commit is contained in:
@@ -33,8 +33,9 @@ namespace sqlpp
|
||||
struct consistent_t : std::true_type
|
||||
{
|
||||
template <typename... T>
|
||||
static constexpr void verify(T&&...)
|
||||
static constexpr int verify(T&&...)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
};
|
||||
} // namespace sqlpp
|
||||
|
||||
@@ -26,6 +26,8 @@
|
||||
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
#include <string>
|
||||
|
||||
#include <sqlpp11/type_traits.h>
|
||||
|
||||
namespace sqlpp
|
||||
|
||||
@@ -39,7 +39,6 @@
|
||||
#include <sqlpp11/mysql/update.h>
|
||||
#include <sqlpp11/serialize.h>
|
||||
#include <iostream>
|
||||
#include <sstream>
|
||||
#include <string>
|
||||
|
||||
namespace sqlpp
|
||||
@@ -281,7 +280,10 @@ namespace sqlpp
|
||||
return serialize(t, context);
|
||||
}
|
||||
|
||||
[[deprecated("Use ping_server() instead")]] bool is_valid() const
|
||||
#if SQLPP_CXX_STD >= 201402L
|
||||
[[deprecated("Use ping_server() instead")]]
|
||||
#endif
|
||||
bool is_valid() const
|
||||
{
|
||||
return _handle->ping_server();
|
||||
}
|
||||
|
||||
@@ -40,9 +40,10 @@ namespace sqlpp
|
||||
static_assert(wrong_t<T...>::value, message); \
|
||||
} \
|
||||
template <typename... T> \
|
||||
static constexpr void verify(T&&...) \
|
||||
static constexpr int verify(T&&...) \
|
||||
{ \
|
||||
static_assert(wrong_t<T...>::value, message); \
|
||||
return 0; \
|
||||
} \
|
||||
auto begin() const -> void; \
|
||||
auto end() const -> void; \
|
||||
|
||||
@@ -314,6 +314,7 @@ namespace sqlpp
|
||||
_impl::_apply(callable);
|
||||
|
||||
std::size_t index = sizeof...(FieldSpecs);
|
||||
std::ignore = index; // silence warnings in case _dynamic_field_names is empty
|
||||
for (const auto& field_name : _dynamic_field_names)
|
||||
{
|
||||
_dynamic_fields.at(field_name)._apply(callable);
|
||||
@@ -327,6 +328,7 @@ namespace sqlpp
|
||||
_impl::_apply(callable);
|
||||
|
||||
std::size_t index = sizeof...(FieldSpecs);
|
||||
std::ignore = index; // silence warnings in case _dynamic_field_names is empty
|
||||
for (const auto& field_name : _dynamic_field_names)
|
||||
{
|
||||
_dynamic_fields.at(field_name)._apply(callable);
|
||||
|
||||
Reference in New Issue
Block a user