From c41a181ca947b80dd8e065f31d911799aad4eead Mon Sep 17 00:00:00 2001 From: Roland Bock Date: Wed, 21 Aug 2013 19:30:56 +0200 Subject: [PATCH] Improved early type checking in stand-alone functions --- include/sqlpp11/functions.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/include/sqlpp11/functions.h b/include/sqlpp11/functions.h index 1107b5b9..c38001b5 100644 --- a/include/sqlpp11/functions.h +++ b/include/sqlpp11/functions.h @@ -39,6 +39,8 @@ namespace sqlpp template\ struct NAME##_t\ {\ + static_assert(CONSTRAINT::type>::value, #NAME "() argument has constraint: " #CONSTRAINT);\ + static_assert(is_expression_t::type>::value, #NAME "() argument has contraint: is_expression_t");\ using _operand = typename operand_t::type;\ \ struct _op\