From 16e38518471b9b875993bbb5554c31fe29766d11 Mon Sep 17 00:00:00 2001 From: Roland Bock Date: Fri, 15 Nov 2013 09:57:30 +0100 Subject: [PATCH] Prevent template constructor to overload default copy cosntructors --- include/sqlpp11/detail/serializable.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/include/sqlpp11/detail/serializable.h b/include/sqlpp11/detail/serializable.h index 8746a20c..99c78454 100644 --- a/include/sqlpp11/detail/serializable.h +++ b/include/sqlpp11/detail/serializable.h @@ -38,7 +38,9 @@ namespace sqlpp template struct serializable_t { - template + template::type, serializable_t>::value, int>::type = 0 // prevent accidental overload for copy constructor + > serializable_t(T&& t): _impl(std::make_shared<_impl_t::type>>(std::forward(t))) {}