Make BOOST_NO_CXX11_NON_PUBLIC_DEFAULTED_FUNCTIONS defined when BOOST_NO_CXX11_DEFAULTED_FUNCTIONS is defined.

Lack of non-public defaulted functions is implied by the lack of any defaulted functions, so define the defect macro.
This commit is contained in:
Andrey Semashev
2014-08-21 15:20:30 +04:00
parent ef0fbe981a
commit be328aa19b
2 changed files with 8 additions and 3 deletions

View File

@ -183,7 +183,7 @@
#endif #endif
// GCC 4.5 forbids declaration of defaulted functions in private or protected sections // GCC 4.5 forbids declaration of defaulted functions in private or protected sections
#if !defined(BOOST_NO_CXX11_DEFAULTED_FUNCTIONS) && (__GNUC__ == 4 && __GNUC_MINOR__ <= 5) #if __GNUC__ < 4 || (__GNUC__ == 4 && __GNUC_MINOR__ <= 5) || !defined(__GXX_EXPERIMENTAL_CXX0X__)
# define BOOST_NO_CXX11_NON_PUBLIC_DEFAULTED_FUNCTIONS # define BOOST_NO_CXX11_NON_PUBLIC_DEFAULTED_FUNCTIONS
#endif #endif

View File

@ -1,5 +1,5 @@
// Boost config.hpp configuration header file ------------------------------// // Boost config.hpp configuration header file ------------------------------//
// boostinspect:ndprecated_macros -- tell the inspect tool to ignore this file // boostinspect:ndprecated_macros -- tell the inspect tool to ignore this file
// Copyright (c) 2001-2003 John Maddock // Copyright (c) 2001-2003 John Maddock
// Copyright (c) 2001 Darin Adler // Copyright (c) 2001 Darin Adler
@ -646,6 +646,11 @@ namespace std{ using ::type_info; }
# define BOOST_ALIGNMENT(x) # define BOOST_ALIGNMENT(x)
#endif #endif
// Lack of non-public defaulted functions is implied by the lack of any defaulted functions
#if !defined(BOOST_NO_CXX11_NON_PUBLIC_DEFAULTED_FUNCTIONS) && defined(BOOST_NO_CXX11_DEFAULTED_FUNCTIONS)
# define BOOST_NO_CXX11_NON_PUBLIC_DEFAULTED_FUNCTIONS
#endif
// Defaulted and deleted function declaration helpers // Defaulted and deleted function declaration helpers
// These macros are intended to be inside a class definition. // These macros are intended to be inside a class definition.
// BOOST_DEFAULTED_FUNCTION accepts the function declaration and its // BOOST_DEFAULTED_FUNCTION accepts the function declaration and its
@ -681,7 +686,7 @@ namespace std{ using ::type_info; }
// Set BOOST_NO_DECLTYPE_N3276 when BOOST_NO_DECLTYPE is defined // Set BOOST_NO_DECLTYPE_N3276 when BOOST_NO_DECLTYPE is defined
// //
#if defined(BOOST_NO_CXX11_DECLTYPE) && !defined(BOOST_NO_CXX11_DECLTYPE_N3276) #if defined(BOOST_NO_CXX11_DECLTYPE) && !defined(BOOST_NO_CXX11_DECLTYPE_N3276)
#define BOOST_NO_CXX11_DECLTYPE_N3276 BOOST_NO_CXX11_DECLTYPE #define BOOST_NO_CXX11_DECLTYPE_N3276 BOOST_NO_CXX11_DECLTYPE
#endif #endif
// -------------------- Deprecated macros for 1.50 --------------------------- // -------------------- Deprecated macros for 1.50 ---------------------------