From 13dd928ae18ef9610bc820b7b3e65629addea1d2 Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Wed, 15 Jun 2016 18:50:51 +0200 Subject: Get rid of C++11 deprecation warnings for auto_ptr, exception specs In particular, std::auto_ptr is no longer mapped in C++11. --- odb/details/config.hxx | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'odb/details/config.hxx') diff --git a/odb/details/config.hxx b/odb/details/config.hxx index c36b163..5aa35aa 100644 --- a/odb/details/config.hxx +++ b/odb/details/config.hxx @@ -16,6 +16,7 @@ # define ODB_CXX11 # if (__GNUC__ == 4 && __GNUC_MINOR__ >= 6) || __GNUC__ > 4 # define ODB_CXX11_NULLPTR +# define ODB_CXX11_NOEXCEPT # endif # define ODB_CXX11_DELETED_FUNCTION # define ODB_CXX11_EXPLICIT_CONVERSION_OPERATOR @@ -29,12 +30,15 @@ # define ODB_CXX11 # ifdef __clang__ // Pretends to be a really old __GNUC__ on some platforms. # define ODB_CXX11_NULLPTR +# define ODB_CXX11_NOEXCEPT # elif defined(__GNUC__) # if (__GNUC__ == 4 && __GNUC_MINOR__ >= 6) || __GNUC__ > 4 # define ODB_CXX11_NULLPTR +# define ODB_CXX11_NOEXCEPT # endif # else # define ODB_CXX11_NULLPTR +# define ODB_CXX11_NOEXCEPT # endif # define ODB_CXX11_DELETED_FUNCTION # define ODB_CXX11_EXPLICIT_CONVERSION_OPERATOR @@ -48,6 +52,12 @@ # endif #endif +#ifdef ODB_CXX11_NOEXCEPT +# define ODB_NOTHROW_NOEXCEPT noexcept +#else +# define ODB_NOTHROW_NOEXCEPT throw() +#endif + // no post #endif // ODB_DETAILS_CONFIG_HXX -- cgit v1.1