From 1c3d02c4698e8f05527400cf76a6d03b4ff76129 Mon Sep 17 00:00:00 2001 From: Andrey Semashev Date: Sat, 15 Jun 2013 13:48:07 +0000 Subject: [PATCH] Added BOOST_NO_CXX11_ALIGNAS, BOOST_ALIGNMENT and BOOST_NO_ALIGNMENT macros. [SVN r84794] --- doc/macro_reference.qbk | 70 ++++++++++++------- include/boost/config/compiler/borland.hpp | 5 +- include/boost/config/compiler/clang.hpp | 26 ++++--- include/boost/config/compiler/codegear.hpp | 3 +- include/boost/config/compiler/common_edg.hpp | 19 ++--- include/boost/config/compiler/cray.hpp | 5 +- include/boost/config/compiler/digitalmars.hpp | 5 +- include/boost/config/compiler/gcc.hpp | 30 ++++---- include/boost/config/compiler/gcc_xml.hpp | 11 +-- include/boost/config/compiler/hp_acc.hpp | 19 ++--- include/boost/config/compiler/metrowerks.hpp | 21 +++--- include/boost/config/compiler/mpw.hpp | 9 +-- include/boost/config/compiler/pathscale.hpp | 5 +- include/boost/config/compiler/pgi.hpp | 1 + include/boost/config/compiler/sunpro_cc.hpp | 21 +++--- include/boost/config/compiler/vacpp.hpp | 23 +++--- include/boost/config/compiler/visualc.hpp | 41 +++++------ include/boost/config/suffix.hpp | 40 +++++++---- test/all/Jamfile.v2 | 9 ++- test/boost_no_cxx11_alignas.ipp | 36 ++++++++++ test/config_info.cpp | 1 + test/config_test.cpp | 10 +++ test/no_cxx11_alignas_fail.cpp | 37 ++++++++++ test/no_cxx11_alignas_pass.cpp | 37 ++++++++++ 24 files changed, 331 insertions(+), 153 deletions(-) create mode 100644 test/boost_no_cxx11_alignas.ipp create mode 100644 test/no_cxx11_alignas_fail.cpp create mode 100644 test/no_cxx11_alignas_pass.cpp diff --git a/doc/macro_reference.qbk b/doc/macro_reference.qbk index acc36d54..d52682d0 100644 --- a/doc/macro_reference.qbk +++ b/doc/macro_reference.qbk @@ -576,6 +576,7 @@ that are not yet supported by a particular compiler or library. [table [[Macro ][Description ]] +[[`BOOST_NO_CXX11_ALIGNAS`][The compiler does not support the `alignas` keyword.]] [[`BOOST_NO_CXX11_ALLOCATOR`][The standard library does not provide a C++11 version of `std::allocator` in .]] [[`BOOST_NO_CXX11_ATOMIC_SP`][The standard library does not support atomic smart pointer operations.]] [[`BOOST_NO_CXX11_HDR_ARRAY`][The standard library does not provide header .]] @@ -601,36 +602,36 @@ that are not yet supported by a particular compiler or library. [[`BOOST_NO_CXX11_AUTO_DECLARATIONS`][The compiler does not support type deduction for variables declared with the `auto` keyword (`auto var = ...;`). -]] +]] [[`BOOST_NO_CXX11_AUTO_MULTIDECLARATIONS`][The compiler does not support type deduction for multiple variables declared with the `auto` keyword (`auto var = ..., *ptr = ...;`). -]] +]] [[`BOOST_NO_CXX11_CHAR16_T`][The compiler does not support type `char16_t`. -]] +]] [[`BOOST_NO_CXX11_CHAR32_T`][The compiler does not support type `char32_t`. -]] +]] [[`BOOST_NO_CXX11_TEMPLATE_ALIASES`][The compiler does not support template aliases. -]] +]] [[`BOOST_NO_CXX11_CONSTEXPR`][The compiler does not support `constexpr`. -]] +]] [[`BOOST_NO_CXX11_DECLTYPE`][The compiler does not support `decltype`. -]] +]] [[`BOOST_NO_CXX11_DECLTYPE_N3276`][The compiler does not support the extension to `decltype` described in [@http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2011/n3276.pdf N3276], accepted in Madrid, March 2011. -]] +]] [[`BOOST_NO_CXX11_DEFAULTED_FUNCTIONS`][The compiler does not support -defaulted (`= default`) functions. -]] +defaulted (`= default`) functions. +]] [[`BOOST_NO_CXX11_DELETED_FUNCTIONS`][The compiler does not support -deleted (`= delete`) functions. -]] +deleted (`= delete`) functions. +]] [[`BOOST_NO_CXX11_EXPLICIT_CONVERSION_OPERATORS`][The compiler does not support -explicit conversion operators (`explicit operator T()`). +explicit conversion operators (`explicit operator T()`). ]] [[`BOOST_NO_CXX11_EXTERN_TEMPLATE`][The compiler does not support explicit instantiation forward declarations for templates (`extern template ...`). @@ -639,49 +640,49 @@ explicit instantiation forward declarations for templates (`extern template ...` default template arguments for function templates. ]] [[`BOOST_NO_CXX11_LAMBDAS`][The compiler does not support Lambdas. -]] +]] [[`BOOST_NO_CXX11_LOCAL_CLASS_TEMPLATE_PARAMETERS`][The compiler does not allow to pass local classes as template parameters (this macro intentionally does not control passing of unnamed types as template parameters, see also [@http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2008/n2657.htm N2657]). ]] [[`BOOST_NO_LONG_LONG`][The compiler does not support `long long`. -]] +]] [[`BOOST_NO_CXX11_NOEXCEPT`][The compiler does not support `noexcept`. -]] +]] [[`BOOST_NO_CXX11_NULLPTR`][The compiler does not support `nullptr`. -]] +]] [[`BOOST_NO_CXX11_RANGE_BASED_FOR`][The compiler does not support range-based for statements. -]] +]] [[`BOOST_NO_CXX11_RAW_LITERALS`][The compiler does not support raw string literals. -]] +]] [[`BOOST_NO_CXX11_RVALUE_REFERENCES`][The compiler does not support r-value references. -]] +]] [[`BOOST_NO_CXX11_SCOPED_ENUMS`][The compiler does not support scoped enumerations (`enum class`). -]] +]] [[`BOOST_NO_CXX11_STATIC_ASSERT`][The compiler does not support `static_assert`. -]] +]] [[`BOOST_NO_CXX11_STD_UNORDERED`][The standard library does not support and . -]] +]] [[`BOOST_NO_CXX11_UNICODE_LITERALS`][The compiler does not support Unicode (`u8`, `u`, `U`) literals. -]] +]] [[`BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX`][The compiler does not support the [@http://en.wikipedia.org/wiki/C%2B%2B0x#Uniform_initialization C++11 Unified Initialization Syntax]. ]] [[`BOOST_NO_CXX11_USER_DEFINED_LITERALS`][The compiler does not support user defined literals. -]] +]] [[`BOOST_NO_CXX11_VARIADIC_TEMPLATES`][The compiler does not support -variadic templates. +variadic templates. ]] [[`BOOST_NO_CXX11_VARIADIC_MACROS`][The compiler does not support -variadic macros. +variadic macros. ]] ] @@ -697,6 +698,21 @@ provide compliant C++11 support. [table [[Macro ][ Description ]] +[[`BOOST_ALIGNMENT(X)`, `BOOST_NO_ALIGNMENT`][ +Some compilers don't support the `alignas` keyword but provide other means to specify alignment +(usually, through compiler-specific attributes). The macro `BOOST_ALIGNMENT(X)` will expand to the `alignas(X)` +keyword if the compiler supports it or to some compiler-specific attribute to achieve the specified alignment. +If no such compiler-specific attribute is known then `BOOST_ALIGNMENT(X)` will expand to nothing and +`BOOST_NO_ALIGNMENT` will be defined. Unlike native `alignas`, `X` must always be a compile-time integer constant. +The macro can be used to specify alignment of types and data: +`` + struct BOOST_ALIGNMENT(16) my_data + { + char c[16]; + }; + BOOST_ALIGNMENT(8) int arr[32]; +`` +]] [[`BOOST_CONSTEXPR`][ Some compilers don't support the use of `constexpr`. This macro expands to nothing on those compilers, and `constexpr` elsewhere. For example, when defining a constexpr function or constructor replace: diff --git a/include/boost/config/compiler/borland.hpp b/include/boost/config/compiler/borland.hpp index 38ac4a9a..bf0aad48 100644 --- a/include/boost/config/compiler/borland.hpp +++ b/include/boost/config/compiler/borland.hpp @@ -155,7 +155,7 @@ # define BOOST_NO_CXX11_DECLTYPE # define BOOST_NO_CXX11_EXPLICIT_CONVERSION_OPERATORS # define BOOST_NO_CXX11_EXTERN_TEMPLATE -# define BOOST_NO_CXX11_RVALUE_REFERENCES +# define BOOST_NO_CXX11_RVALUE_REFERENCES # define BOOST_NO_CXX11_SCOPED_ENUMS # define BOOST_NO_CXX11_STATIC_ASSERT #else @@ -191,6 +191,7 @@ #define BOOST_NO_CXX11_NOEXCEPT #define BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX #define BOOST_NO_CXX11_USER_DEFINED_LITERALS +#define BOOST_NO_CXX11_ALIGNAS #if __BORLANDC__ >= 0x590 # define BOOST_HAS_TR1_HASH @@ -243,7 +244,7 @@ // all versions support __declspec: // #if defined(__STRICT_ANSI__) -// config/platform/win32.hpp will define BOOST_SYMBOL_EXPORT, etc., unless already defined +// config/platform/win32.hpp will define BOOST_SYMBOL_EXPORT, etc., unless already defined # define BOOST_SYMBOL_EXPORT #endif // diff --git a/include/boost/config/compiler/clang.hpp b/include/boost/config/compiler/clang.hpp index 89975737..15e01c68 100644 --- a/include/boost/config/compiler/clang.hpp +++ b/include/boost/config/compiler/clang.hpp @@ -1,7 +1,7 @@ // (C) Copyright Douglas Gregor 2010 // -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file +// Use, modification and distribution are subject to the +// Boost Software License, Version 1.0. (See accompanying file // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) // See http://www.boost.org for most recent version. @@ -46,15 +46,15 @@ # define BOOST_SYMBOL_VISIBLE __attribute__((__visibility__("default"))) #endif -// -// The BOOST_FALLTHROUGH macro can be used to annotate implicit fall-through -// between switch labels. -// -#if __cplusplus >= 201103L && defined(__has_warning) -# if __has_feature(cxx_attributes) && __has_warning("-Wimplicit-fallthrough") -# define BOOST_FALLTHROUGH [[clang::fallthrough]] -# endif -#endif +// +// The BOOST_FALLTHROUGH macro can be used to annotate implicit fall-through +// between switch labels. +// +#if __cplusplus >= 201103L && defined(__has_warning) +# if __has_feature(cxx_attributes) && __has_warning("-Wimplicit-fallthrough") +# define BOOST_FALLTHROUGH [[clang::fallthrough]] +# endif +#endif #if !__has_feature(cxx_auto_type) # define BOOST_NO_CXX11_AUTO_DECLARATIONS @@ -154,6 +154,10 @@ # define BOOST_NO_CXX11_USER_DEFINED_LITERALS #endif +#if !(__has_feature(cxx_alignas) || __has_extension(cxx_alignas)) +# define BOOST_NO_CXX11_ALIGNAS +#endif + // Clang always supports variadic macros // Clang always supports extern templates diff --git a/include/boost/config/compiler/codegear.hpp b/include/boost/config/compiler/codegear.hpp index 9dd97bc0..199acaf1 100644 --- a/include/boost/config/compiler/codegear.hpp +++ b/include/boost/config/compiler/codegear.hpp @@ -111,6 +111,7 @@ #define BOOST_NO_CXX11_VARIADIC_TEMPLATES #define BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX #define BOOST_NO_CXX11_USER_DEFINED_LITERALS +#define BOOST_NO_CXX11_ALIGNAS // // TR1 macros: @@ -151,7 +152,7 @@ // all versions support __declspec: // #if defined(__STRICT_ANSI__) -// config/platform/win32.hpp will define BOOST_SYMBOL_EXPORT, etc., unless already defined +// config/platform/win32.hpp will define BOOST_SYMBOL_EXPORT, etc., unless already defined # define BOOST_SYMBOL_EXPORT #endif // diff --git a/include/boost/config/compiler/common_edg.hpp b/include/boost/config/compiler/common_edg.hpp index 4b5d2d26..80610adc 100644 --- a/include/boost/config/compiler/common_edg.hpp +++ b/include/boost/config/compiler/common_edg.hpp @@ -1,10 +1,10 @@ -// (C) Copyright John Maddock 2001 - 2002. -// (C) Copyright Jens Maurer 2001. -// (C) Copyright David Abrahams 2002. -// (C) Copyright Aleksey Gurtovoy 2002. +// (C) Copyright John Maddock 2001 - 2002. +// (C) Copyright Jens Maurer 2001. +// (C) Copyright David Abrahams 2002. +// (C) Copyright Aleksey Gurtovoy 2002. // (C) Copyright Markus Schoepflin 2005. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file +// Use, modification and distribution are subject to the +// Boost Software License, Version 1.0. (See accompanying file // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) // See http://www.boost.org for most recent version. @@ -33,15 +33,15 @@ #if (__EDG_VERSION__ <= 244) && !defined(BOOST_NO_TEMPLATE_TEMPLATES) # define BOOST_NO_TEMPLATE_TEMPLATES -#endif +#endif #if (__EDG_VERSION__ < 300) && !defined(BOOST_NO_IS_ABSTRACT) # define BOOST_NO_IS_ABSTRACT -#endif +#endif #if (__EDG_VERSION__ <= 303) && !defined(BOOST_FUNCTION_SCOPE_USING_DECLARATION_BREAKS_ADL) # define BOOST_FUNCTION_SCOPE_USING_DECLARATION_BREAKS_ADL -#endif +#endif // See also kai.hpp which checks a Kai-specific symbol for EH # if !defined(__KCC) && !defined(__EXCEPTIONS) && !defined(BOOST_NO_EXCEPTIONS) @@ -96,6 +96,7 @@ #define BOOST_NO_CXX11_VARIADIC_TEMPLATES #define BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX #define BOOST_NO_CXX11_USER_DEFINED_LITERALS +#define BOOST_NO_CXX11_ALIGNAS #ifdef c_plusplus // EDG has "long long" in non-strict mode diff --git a/include/boost/config/compiler/cray.hpp b/include/boost/config/compiler/cray.hpp index 4455c5c4..3ce29f01 100644 --- a/include/boost/config/compiler/cray.hpp +++ b/include/boost/config/compiler/cray.hpp @@ -55,10 +55,11 @@ #define BOOST_NO_COMPLETE_VALUE_INITIALIZATION #define BOOST_NO_CXX11_CHAR32_T #define BOOST_NO_CXX11_CHAR16_T +#define BOOST_NO_CXX11_ALIGNAS //#define BOOST_BCB_PARTIAL_SPECIALIZATION_BUG #define BOOST_MATH_DISABLE_STD_FPCLASSIFY //#define BOOST_HAS_FPCLASSIFY -#define BOOST_SP_USE_PTHREADS -#define BOOST_AC_USE_PTHREADS +#define BOOST_SP_USE_PTHREADS +#define BOOST_AC_USE_PTHREADS diff --git a/include/boost/config/compiler/digitalmars.hpp b/include/boost/config/compiler/digitalmars.hpp index 0206dc38..0376f1c1 100644 --- a/include/boost/config/compiler/digitalmars.hpp +++ b/include/boost/config/compiler/digitalmars.hpp @@ -1,8 +1,8 @@ // Copyright (C) Christof Meerwald 2003 // Copyright (C) Dan Watkins 2003 // -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file +// Use, modification and distribution are subject to the +// Boost Software License, Version 1.0. (See accompanying file // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) // Digital Mars C++ compiler setup: @@ -87,6 +87,7 @@ #define BOOST_NO_CXX11_VARIADIC_TEMPLATES #define BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX #define BOOST_NO_CXX11_USER_DEFINED_LITERALS +#define BOOST_NO_CXX11_ALIGNAS #if (__DMC__ < 0x812) #define BOOST_NO_CXX11_VARIADIC_MACROS diff --git a/include/boost/config/compiler/gcc.hpp b/include/boost/config/compiler/gcc.hpp index 0b86dd3f..e333308a 100644 --- a/include/boost/config/compiler/gcc.hpp +++ b/include/boost/config/compiler/gcc.hpp @@ -1,12 +1,12 @@ -// (C) Copyright John Maddock 2001 - 2003. -// (C) Copyright Darin Adler 2001 - 2002. -// (C) Copyright Jens Maurer 2001 - 2002. -// (C) Copyright Beman Dawes 2001 - 2003. -// (C) Copyright Douglas Gregor 2002. -// (C) Copyright David Abrahams 2002 - 2003. -// (C) Copyright Synge Todo 2003. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file +// (C) Copyright John Maddock 2001 - 2003. +// (C) Copyright Darin Adler 2001 - 2002. +// (C) Copyright Jens Maurer 2001 - 2002. +// (C) Copyright Beman Dawes 2001 - 2003. +// (C) Copyright Douglas Gregor 2002. +// (C) Copyright David Abrahams 2002 - 2003. +// (C) Copyright Synge Todo 2003. +// Use, modification and distribution are subject to the +// Boost Software License, Version 1.0. (See accompanying file // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) // See http://www.boost.org for most recent version. @@ -104,7 +104,7 @@ // #if !defined(__MINGW32__) && !defined(linux) && !defined(__linux) && !defined(__linux__) # define BOOST_HAS_THREADS -#endif +#endif // // gcc has "long long" @@ -127,7 +127,7 @@ // #if __GNUC__ >= 4 # if (defined(_WIN32) || defined(__WIN32__) || defined(WIN32)) && !defined(__CYGWIN__) - // All Win32 development environments, including 64-bit Windows and MinGW, define + // All Win32 development environments, including 64-bit Windows and MinGW, define // _WIN32 or one of its variant spellings. Note that Cygwin is a POSIX environment, // so does not define _WIN32 or its variants. # define BOOST_HAS_DECLSPEC @@ -187,7 +187,7 @@ # define BOOST_NO_CXX11_RVALUE_REFERENCES # define BOOST_NO_CXX11_STATIC_ASSERT -// Variadic templates compiler: +// Variadic templates compiler: // http://www.generic-programming.org/~dgregor/cpp/variadic-templates.html # if defined(__VARIADIC_TEMPLATES) || (__GNUC__ > 4) || ((__GNUC__ == 4) && (__GNUC_MINOR__ >= 4) && defined(__GXX_EXPERIMENTAL_CXX0X__)) # define BOOST_HAS_VARIADIC_TMPL @@ -247,6 +247,12 @@ # define BOOST_NO_CXX11_USER_DEFINED_LITERALS #endif +// C++0x features in 4.8.n and later +// +#if __GNUC__ < 4 || (__GNUC__ == 4 && __GNUC_MINOR__ < 8) || !defined(__GXX_EXPERIMENTAL_CXX0X__) +# define BOOST_NO_CXX11_ALIGNAS +#endif + // C++0x features in 4.8.1 and later // #if (__GNUC__*10000 + __GNUC_MINOR__*100 + __GNUC_PATCHLEVEL__ < 40801) || !defined(__GXX_EXPERIMENTAL_CXX0X__) diff --git a/include/boost/config/compiler/gcc_xml.hpp b/include/boost/config/compiler/gcc_xml.hpp index 1af2fc1a..75775594 100644 --- a/include/boost/config/compiler/gcc_xml.hpp +++ b/include/boost/config/compiler/gcc_xml.hpp @@ -1,6 +1,6 @@ -// (C) Copyright John Maddock 2006. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file +// (C) Copyright John Maddock 2006. +// Use, modification and distribution are subject to the +// Boost Software License, Version 1.0. (See accompanying file // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) // See http://www.boost.org for most recent version. @@ -18,7 +18,7 @@ // #if !defined(__MINGW32__) && !defined(_MSC_VER) && !defined(linux) && !defined(__linux) && !defined(__linux__) # define BOOST_HAS_THREADS -#endif +#endif // // gcc has "long long" @@ -44,7 +44,7 @@ # define BOOST_NO_CXX11_DEFAULTED_FUNCTIONS # define BOOST_NO_CXX11_DELETED_FUNCTIONS # define BOOST_NO_CXX11_HDR_INITIALIZER_LIST -# define BOOST_NO_CXX11_SCOPED_ENUMS +# define BOOST_NO_CXX11_SCOPED_ENUMS # define BOOST_NO_SFINAE_EXPR # define BOOST_NO_CXX11_EXPLICIT_CONVERSION_OPERATORS # define BOOST_NO_CXX11_LAMBDAS @@ -55,6 +55,7 @@ # define BOOST_NO_CXX11_NOEXCEPT # define BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX # define BOOST_NO_CXX11_USER_DEFINED_LITERALS +# define BOOST_NO_CXX11_ALIGNAS #define BOOST_COMPILER "GCC-XML C++ version " __GCCXML__ diff --git a/include/boost/config/compiler/hp_acc.hpp b/include/boost/config/compiler/hp_acc.hpp index 12c791b3..f4f4b183 100644 --- a/include/boost/config/compiler/hp_acc.hpp +++ b/include/boost/config/compiler/hp_acc.hpp @@ -1,11 +1,11 @@ -// (C) Copyright John Maddock 2001 - 2003. -// (C) Copyright Jens Maurer 2001 - 2003. -// (C) Copyright Aleksey Gurtovoy 2002. -// (C) Copyright David Abrahams 2002 - 2003. -// (C) Copyright Toon Knapen 2003. +// (C) Copyright John Maddock 2001 - 2003. +// (C) Copyright Jens Maurer 2001 - 2003. +// (C) Copyright Aleksey Gurtovoy 2002. +// (C) Copyright David Abrahams 2002 - 2003. +// (C) Copyright Toon Knapen 2003. // (C) Copyright Boris Gubenko 2006 - 2007. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file +// Use, modification and distribution are subject to the +// Boost Software License, Version 1.0. (See accompanying file // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) // See http://www.boost.org for most recent version. @@ -43,7 +43,7 @@ # define BOOST_NO_DEPENDENT_TYPES_IN_TEMPLATE_VALUE_PARAMETERS # define BOOST_NO_IS_ABSTRACT # define BOOST_NO_MEMBER_TEMPLATE_FRIENDS -#endif +#endif // optional features rather than defects: #if (__HP_aCC >= 33900) @@ -119,8 +119,9 @@ #define BOOST_NO_CXX11_UNICODE_LITERALS #define BOOST_NO_CXX11_VARIADIC_TEMPLATES #define BOOST_NO_CXX11_USER_DEFINED_LITERALS +#define BOOST_NO_CXX11_ALIGNAS -/* +/* See https://forums13.itrc.hp.com/service/forums/questionanswer.do?threadId=1443331 and https://forums13.itrc.hp.com/service/forums/questionanswer.do?threadId=1443436 */ diff --git a/include/boost/config/compiler/metrowerks.hpp b/include/boost/config/compiler/metrowerks.hpp index 4ca8af8a..78555891 100644 --- a/include/boost/config/compiler/metrowerks.hpp +++ b/include/boost/config/compiler/metrowerks.hpp @@ -1,11 +1,11 @@ -// (C) Copyright John Maddock 2001. -// (C) Copyright Darin Adler 2001. -// (C) Copyright Peter Dimov 2001. -// (C) Copyright David Abrahams 2001 - 2002. -// (C) Copyright Beman Dawes 2001 - 2003. -// (C) Copyright Stefan Slapeta 2004. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file +// (C) Copyright John Maddock 2001. +// (C) Copyright Darin Adler 2001. +// (C) Copyright Peter Dimov 2001. +// (C) Copyright David Abrahams 2001 - 2002. +// (C) Copyright Beman Dawes 2001 - 2003. +// (C) Copyright Stefan Slapeta 2004. +// Use, modification and distribution are subject to the +// Boost Software License, Version 1.0. (See accompanying file // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) // See http://www.boost.org for most recent version. @@ -15,7 +15,7 @@ // locale support is disabled when linking with the dynamic runtime # ifdef _MSL_NO_LOCALE # define BOOST_NO_STD_LOCALE -# endif +# endif # if __MWERKS__ <= 0x2301 // 5.3 # define BOOST_NO_FUNCTION_TEMPLATE_ORDERING @@ -90,7 +90,7 @@ #if __MWERKS__ > 0x3206 && __option(rvalue_refs) # define BOOST_HAS_RVALUE_REFS #else -# define BOOST_NO_CXX11_RVALUE_REFERENCES +# define BOOST_NO_CXX11_RVALUE_REFERENCES #endif #define BOOST_NO_CXX11_AUTO_DECLARATIONS #define BOOST_NO_CXX11_AUTO_MULTIDECLARATIONS @@ -120,6 +120,7 @@ #define BOOST_NO_CXX11_VARIADIC_MACROS #define BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX #define BOOST_NO_CXX11_USER_DEFINED_LITERALS +#define BOOST_NO_CXX11_ALIGNAS #define BOOST_COMPILER "Metrowerks CodeWarrior C++ version " BOOST_STRINGIZE(BOOST_COMPILER_VERSION) diff --git a/include/boost/config/compiler/mpw.hpp b/include/boost/config/compiler/mpw.hpp index 7ef38efa..a935296e 100644 --- a/include/boost/config/compiler/mpw.hpp +++ b/include/boost/config/compiler/mpw.hpp @@ -1,7 +1,7 @@ -// (C) Copyright John Maddock 2001 - 2002. -// (C) Copyright Aleksey Gurtovoy 2002. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file +// (C) Copyright John Maddock 2001 - 2002. +// (C) Copyright Aleksey Gurtovoy 2002. +// Use, modification and distribution are subject to the +// Boost Software License, Version 1.0. (See accompanying file // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) // See http://www.boost.org for most recent version. @@ -69,6 +69,7 @@ #define BOOST_NO_CXX11_VARIADIC_MACROS #define BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX #define BOOST_NO_CXX11_USER_DEFINED_LITERALS +#define BOOST_NO_CXX11_ALIGNAS // // versions check: diff --git a/include/boost/config/compiler/pathscale.hpp b/include/boost/config/compiler/pathscale.hpp index 07d14609..6f820349 100644 --- a/include/boost/config/compiler/pathscale.hpp +++ b/include/boost/config/compiler/pathscale.hpp @@ -1,7 +1,7 @@ // (C) Copyright Bryce Lelbach 2011 -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file +// Use, modification and distribution are subject to the +// Boost Software License, Version 1.0. (See accompanying file // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) // See http://www.boost.org for most recent version. @@ -77,5 +77,6 @@ # define BOOST_NO_CXX11_HDR_CODECVT # define BOOST_NO_CXX11_HDR_CHRONO # define BOOST_NO_CXX11_USER_DEFINED_LITERALS +# define BOOST_NO_CXX11_ALIGNAS #endif diff --git a/include/boost/config/compiler/pgi.hpp b/include/boost/config/compiler/pgi.hpp index 64c0d753..14cb6fc6 100644 --- a/include/boost/config/compiler/pgi.hpp +++ b/include/boost/config/compiler/pgi.hpp @@ -112,6 +112,7 @@ #define BOOST_NO_CXX11_HDR_CHRONO #define BOOST_NO_CXX11_HDR_ARRAY #define BOOST_NO_CXX11_USER_DEFINED_LITERALS +#define BOOST_NO_CXX11_ALIGNAS // // version check: diff --git a/include/boost/config/compiler/sunpro_cc.hpp b/include/boost/config/compiler/sunpro_cc.hpp index 88421ee4..e59eed8e 100644 --- a/include/boost/config/compiler/sunpro_cc.hpp +++ b/include/boost/config/compiler/sunpro_cc.hpp @@ -1,10 +1,10 @@ -// (C) Copyright John Maddock 2001. -// (C) Copyright Jens Maurer 2001 - 2003. -// (C) Copyright Peter Dimov 2002. -// (C) Copyright Aleksey Gurtovoy 2002 - 2003. -// (C) Copyright David Abrahams 2002. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file +// (C) Copyright John Maddock 2001. +// (C) Copyright Jens Maurer 2001 - 2003. +// (C) Copyright Peter Dimov 2002. +// (C) Copyright Aleksey Gurtovoy 2002 - 2003. +// (C) Copyright David Abrahams 2002. +// Use, modification and distribution are subject to the +// Boost Software License, Version 1.0. (See accompanying file // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) // See http://www.boost.org for most recent version. @@ -34,7 +34,7 @@ # define BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION # endif -# if (__SUNPRO_CC <= 0x530) +# if (__SUNPRO_CC <= 0x530) // Requesting debug info (-g) with Boost.Python results // in an internal compiler error for "static const" // initialized in-class. @@ -57,7 +57,7 @@ # define BOOST_NO_INTEGRAL_INT64_T # endif -# if (__SUNPRO_CC < 0x570) +# if (__SUNPRO_CC < 0x570) # define BOOST_NO_TEMPLATE_TEMPLATES // see http://lists.boost.org/MailArchives/boost/msg47184.php // and http://lists.boost.org/MailArchives/boost/msg47220.php @@ -65,7 +65,7 @@ # define BOOST_NO_SFINAE # define BOOST_NO_ARRAY_TYPE_SPECIALIZATIONS # endif -# if (__SUNPRO_CC <= 0x580) +# if (__SUNPRO_CC <= 0x580) # define BOOST_NO_IS_ABSTRACT # endif @@ -128,6 +128,7 @@ #define BOOST_NO_CXX11_VARIADIC_MACROS #define BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX #define BOOST_NO_CXX11_USER_DEFINED_LITERALS +#define BOOST_NO_CXX11_ALIGNAS // // Version diff --git a/include/boost/config/compiler/vacpp.hpp b/include/boost/config/compiler/vacpp.hpp index 47b99031..e9dabe60 100644 --- a/include/boost/config/compiler/vacpp.hpp +++ b/include/boost/config/compiler/vacpp.hpp @@ -1,10 +1,10 @@ -// (C) Copyright John Maddock 2001 - 2003. -// (C) Copyright Toon Knapen 2001 - 2003. -// (C) Copyright Lie-Quan Lee 2001. -// (C) Copyright Markus Schoepflin 2002 - 2003. -// (C) Copyright Beman Dawes 2002 - 2003. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file +// (C) Copyright John Maddock 2001 - 2003. +// (C) Copyright Toon Knapen 2001 - 2003. +// (C) Copyright Lie-Quan Lee 2001. +// (C) Copyright Markus Schoepflin 2002 - 2003. +// (C) Copyright Beman Dawes 2002 - 2003. +// Use, modification and distribution are subject to the +// Boost Software License, Version 1.0. (See accompanying file // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) // See http://www.boost.org for most recent version. @@ -16,7 +16,7 @@ # define BOOST_NO_MEMBER_FUNCTION_SPECIALIZATIONS #endif -#if (__IBMCPP__ <= 502) +#if (__IBMCPP__ <= 502) // Actually the compiler supports inclass member initialization but it // requires a definition for the class member and it doesn't recognize // it as an integral constant expression when used as a template argument. @@ -30,9 +30,9 @@ #endif #if (__IBMCPP__ <= 1110) -// XL C++ V11.1 and earlier versions may not always value-initialize -// a temporary object T(), when T is a non-POD aggregate class type. -// Michael Wong (IBM Canada Ltd) has confirmed this issue and gave it +// XL C++ V11.1 and earlier versions may not always value-initialize +// a temporary object T(), when T is a non-POD aggregate class type. +// Michael Wong (IBM Canada Ltd) has confirmed this issue and gave it // high priority. -- Niels Dekker (LKEB), May 2010. # define BOOST_NO_COMPLETE_VALUE_INITIALIZATION #endif @@ -126,6 +126,7 @@ #if ! __C99_MACRO_WITH_VA_ARGS # define BOOST_NO_CXX11_VARIADIC_MACROS #endif +#define BOOST_NO_CXX11_ALIGNAS diff --git a/include/boost/config/compiler/visualc.hpp b/include/boost/config/compiler/visualc.hpp index 83e8e3d7..5de0ed74 100644 --- a/include/boost/config/compiler/visualc.hpp +++ b/include/boost/config/compiler/visualc.hpp @@ -1,11 +1,11 @@ -// (C) Copyright John Maddock 2001 - 2003. -// (C) Copyright Darin Adler 2001 - 2002. -// (C) Copyright Peter Dimov 2001. -// (C) Copyright Aleksey Gurtovoy 2002. -// (C) Copyright David Abrahams 2002 - 2003. -// (C) Copyright Beman Dawes 2002 - 2003. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file +// (C) Copyright John Maddock 2001 - 2003. +// (C) Copyright Darin Adler 2001 - 2002. +// (C) Copyright Peter Dimov 2001. +// (C) Copyright Aleksey Gurtovoy 2002. +// (C) Copyright David Abrahams 2002 - 2003. +// (C) Copyright Beman Dawes 2002 - 2003. +// Use, modification and distribution are subject to the +// Boost Software License, Version 1.0. (See accompanying file // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) // See http://www.boost.org for most recent version. @@ -94,7 +94,7 @@ #endif -#if _MSC_VER < 1400 +#if _MSC_VER < 1400 // although a conforming signature for swprint exists in VC7.1 // it appears not to actually work: # define BOOST_NO_SWPRINTF @@ -119,9 +119,9 @@ #endif -// MSVC (including the latest checked version) has not yet completely +// MSVC (including the latest checked version) has not yet completely // implemented value-initialization, as is reported: -// "VC++ does not value-initialize members of derived classes without +// "VC++ does not value-initialize members of derived classes without // user-declared constructor", reported in 2009 by Sylvester Hesp: // https://connect.microsoft.com/VisualStudio/feedback/details/484295 // "Presence of copy constructor breaks member class initialization", @@ -148,11 +148,11 @@ # define BOOST_HAS_GETSYSTEMTIMEASFILETIME #endif -// -// check for exception handling support: +// +// check for exception handling support: #if !defined(_CPPUNWIND) && !defined(BOOST_NO_EXCEPTIONS) -# define BOOST_NO_EXCEPTIONS -#endif +# define BOOST_NO_EXCEPTIONS +#endif // // __int64 support: @@ -242,6 +242,7 @@ #define BOOST_NO_SFINAE_EXPR #define BOOST_NO_TWO_PHASE_NAME_LOOKUP #define BOOST_NO_CXX11_USER_DEFINED_LITERALS +#define BOOST_NO_CXX11_ALIGNAS // // prefix and suffix headers: @@ -255,7 +256,7 @@ #ifndef BOOST_COMPILER // TODO: -// these things are mostly bogus. 1200 means version 12.0 of the compiler. The +// these things are mostly bogus. 1200 means version 12.0 of the compiler. The // artificial versions assigned to them only refer to the versions of some IDE // these compilers have been shipped with, and even that is not all of it. Some // were shipped with freely downloadable SDKs, others as crosscompilers in eVC. @@ -278,8 +279,8 @@ # define BOOST_COMPILER_VERSION evc9 # elif _MSC_VER < 1700 # define BOOST_COMPILER_VERSION evc10 -# elif _MSC_VER < 1800 -# define BOOST_COMPILER_VERSION evc11 +# elif _MSC_VER < 1800 +# define BOOST_COMPILER_VERSION evc11 # else # if defined(BOOST_ASSERT_CONFIG) # error "Unknown EVC++ compiler version - please run the configure tests and report the results" @@ -303,8 +304,8 @@ # define BOOST_COMPILER_VERSION 9.0 # elif _MSC_VER < 1700 # define BOOST_COMPILER_VERSION 10.0 -# elif _MSC_VER < 1800 -# define BOOST_COMPILER_VERSION 11.0 +# elif _MSC_VER < 1800 +# define BOOST_COMPILER_VERSION 11.0 # else # define BOOST_COMPILER_VERSION _MSC_VER # endif diff --git a/include/boost/config/suffix.hpp b/include/boost/config/suffix.hpp index 654284d2..5e60eb22 100644 --- a/include/boost/config/suffix.hpp +++ b/include/boost/config/suffix.hpp @@ -4,7 +4,7 @@ // Copyright (c) 2001-2003 John Maddock // Copyright (c) 2001 Darin Adler // Copyright (c) 2001 Peter Dimov -// Copyright (c) 2002 Bill Kempf +// Copyright (c) 2002 Bill Kempf // Copyright (c) 2002 Jens Maurer // Copyright (c) 2002-2003 David Abrahams // Copyright (c) 2003 Gennaro Prota @@ -146,7 +146,7 @@ # endif // -// Without partial specialization, partial +// Without partial specialization, partial // specialization with default args won't work either: // # if defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) \ @@ -676,6 +676,20 @@ namespace std{ using ::type_info; } # define BOOST_UNLIKELY(x) x #endif +// Type and data alignment specification +// +#if !defined(BOOST_NO_CXX11_ALIGNAS) +# define BOOST_ALIGNMENT(x) alignas(x) +#elif defined(_MSC_VER) +# define BOOST_ALIGNMENT(x) __declspec(align(x)) +#elif defined(__GNUC__) +# define BOOST_ALIGNMENT(x) __attribute__ ((__aligned__(x))) +#else +# define BOOST_NO_ALIGNMENT +# define BOOST_ALIGNMENT(x) +#endif + + // // Set BOOST_NO_DECLTYPE_N3276 when BOOST_NO_DECLTYPE is defined // @@ -724,7 +738,7 @@ namespace std{ using ::type_info; } # define BOOST_NO_0X_HDR_FUTURE #endif -// Use BOOST_NO_CXX11_HDR_INITIALIZER_LIST +// Use BOOST_NO_CXX11_HDR_INITIALIZER_LIST // instead of BOOST_NO_0X_HDR_INITIALIZER_LIST or BOOST_NO_INITIALIZER_LISTS #ifdef BOOST_NO_CXX11_HDR_INITIALIZER_LIST # ifndef BOOST_NO_0X_HDR_INITIALIZER_LIST @@ -913,19 +927,19 @@ namespace std{ using ::type_info; } # define BOOST_NOEXCEPT_EXPR(Expression) noexcept((Expression)) #endif // -// Helper macro BOOST_FALLTHROUGH -// Fallback definition of BOOST_FALLTHROUGH macro used to mark intended -// fall-through between case labels in a switch statement. We use a definition -// that requires a semicolon after it to avoid at least one type of misuse even -// on unsupported compilers. -// -#ifndef BOOST_FALLTHROUGH -# define BOOST_FALLTHROUGH ((void)0) -#endif +// Helper macro BOOST_FALLTHROUGH +// Fallback definition of BOOST_FALLTHROUGH macro used to mark intended +// fall-through between case labels in a switch statement. We use a definition +// that requires a semicolon after it to avoid at least one type of misuse even +// on unsupported compilers. +// +#ifndef BOOST_FALLTHROUGH +# define BOOST_FALLTHROUGH ((void)0) +#endif // // constexpr workarounds -// +// #if defined(BOOST_NO_CXX11_CONSTEXPR) #define BOOST_CONSTEXPR #define BOOST_CONSTEXPR_OR_CONST const diff --git a/test/all/Jamfile.v2 b/test/all/Jamfile.v2 index 2b8e8d34..00478016 100644 --- a/test/all/Jamfile.v2 +++ b/test/all/Jamfile.v2 @@ -226,6 +226,12 @@ test-suite "BOOST_NO_CWCHAR" : test-suite "BOOST_NO_CWCTYPE" : [ run ../no_cwctype_pass.cpp ] [ compile-fail ../no_cwctype_fail.cpp ] ; +test-suite "BOOST_NO_CXX11_RAW_LITERALS" : +[ run ../no_raw_literals_pass.cpp ] +[ compile-fail ../no_raw_literals_fail.cpp ] ; +test-suite "BOOST_NO_CXX11_ALIGNAS" : +[ run ../no_cxx11_alignas_pass.cpp ] +[ compile-fail ../no_cxx11_alignas_fail.cpp ] ; test-suite "BOOST_NO_CXX11_ALLOCATOR" : [ run ../no_cxx11_allocator_pass.cpp ] [ compile-fail ../no_cxx11_allocator_fail.cpp ] ; @@ -424,9 +430,6 @@ test-suite "BOOST_NO_POINTER_TO_MEMBER_CONST" : test-suite "BOOST_NO_CXX11_RANGE_BASED_FOR" : [ run ../no_range_based_for_pass.cpp ] [ compile-fail ../no_range_based_for_fail.cpp ] ; -test-suite "BOOST_NO_CXX11_RAW_LITERALS" : -[ run ../no_raw_literals_pass.cpp ] -[ compile-fail ../no_raw_literals_fail.cpp ] ; test-suite "BOOST_NO_UNREACHABLE_RETURN_DETECTION" : [ run ../no_ret_det_pass.cpp ] [ compile-fail ../no_ret_det_fail.cpp ] ; diff --git a/test/boost_no_cxx11_alignas.ipp b/test/boost_no_cxx11_alignas.ipp new file mode 100644 index 00000000..afd428f6 --- /dev/null +++ b/test/boost_no_cxx11_alignas.ipp @@ -0,0 +1,36 @@ +// (C) Copyright Andrey Semashev 2013 + +// Use, modification and distribution are subject to the +// Boost Software License, Version 1.0. (See accompanying file +// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org/libs/config for more information. + +// MACRO: BOOST_NO_CXX11_ALIGNAS +// TITLE: C++11 alignas keyword. +// DESCRIPTION: The compiler does not support the C++11 alignment specification with alignas keyword. + +namespace boost_no_cxx11_alignas { + +struct alignas(16) my_data1 +{ + char data[10]; +}; + +struct alignas(double) my_data2 +{ + char data[16]; +}; + +my_data1 dummy1[2]; +my_data2 dummy2; +alignas(16) char dummy3[10]; +alignas(double) char dummy4[32]; + +int test() +{ + // TODO: Test that the data is actually aligned on platforms with uintptr_t + return 0; +} + +} diff --git a/test/config_info.cpp b/test/config_info.cpp index c70ac930..21d8d7ea 100644 --- a/test/config_info.cpp +++ b/test/config_info.cpp @@ -992,6 +992,7 @@ void print_boost_macros() PRINT_MACRO(BOOST_NO_CV_VOID_SPECIALIZATIONS); PRINT_MACRO(BOOST_NO_CWCHAR); PRINT_MACRO(BOOST_NO_CWCTYPE); + PRINT_MACRO(BOOST_NO_CXX11_ALIGNAS); PRINT_MACRO(BOOST_NO_CXX11_ALLOCATOR); PRINT_MACRO(BOOST_NO_CXX11_ATOMIC_SMART_PTR); PRINT_MACRO(BOOST_NO_CXX11_AUTO_DECLARATIONS); diff --git a/test/config_test.cpp b/test/config_test.cpp index f0ef9b6d..f3165e8f 100644 --- a/test/config_test.cpp +++ b/test/config_test.cpp @@ -102,6 +102,11 @@ namespace boost_no_cwchar = empty_boost; #else namespace boost_no_cwctype = empty_boost; #endif +#ifndef BOOST_NO_CXX11_ALIGNAS +#include "boost_no_cxx11_alignas.ipp" +#else +namespace boost_no_cxx11_alignas = empty_boost; +#endif #ifndef BOOST_NO_CXX11_ALLOCATOR #include "boost_no_cxx11_allocator.ipp" #else @@ -1231,6 +1236,11 @@ int main( int, char *[] ) std::cerr << "Failed test for BOOST_NO_CWCTYPE at: " << __FILE__ << ":" << __LINE__ << std::endl; ++error_count; } + if(0 != boost_no_cxx11_alignas::test()) + { + std::cerr << "Failed test for BOOST_NO_CXX11_ALIGNAS at: " << __FILE__ << ":" << __LINE__ << std::endl; + ++error_count; + } if(0 != boost_no_cxx11_allocator::test()) { std::cerr << "Failed test for BOOST_NO_CXX11_ALLOCATOR at: " << __FILE__ << ":" << __LINE__ << std::endl; diff --git a/test/no_cxx11_alignas_fail.cpp b/test/no_cxx11_alignas_fail.cpp new file mode 100644 index 00000000..767aaa34 --- /dev/null +++ b/test/no_cxx11_alignas_fail.cpp @@ -0,0 +1,37 @@ +// This file was automatically generated on Sun Apr 28 18:36:48 2013 +// by libs/config/tools/generate.cpp +// Copyright John Maddock 2002-4. +// Use, modification and distribution are subject to the +// Boost Software License, Version 1.0. (See accompanying file +// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org/libs/config for the most recent version.// +// Revision $Id$ +// + + +// Test file for macro BOOST_NO_CXX11_ALIGNAS +// This file should not compile, if it does then +// BOOST_NO_CXX11_ALIGNAS should not be defined. +// See file boost_no_cxx11_alignas.ipp for details + +// Must not have BOOST_ASSERT_CONFIG set; it defeats +// the objective of this file: +#ifdef BOOST_ASSERT_CONFIG +# undef BOOST_ASSERT_CONFIG +#endif + +#include +#include "test.hpp" + +#ifdef BOOST_NO_CXX11_ALIGNAS +#include "boost_no_cxx11_alignas.ipp" +#else +#error "this file should not compile" +#endif + +int main( int, char *[] ) +{ + return boost_no_cxx11_alignas::test(); +} + diff --git a/test/no_cxx11_alignas_pass.cpp b/test/no_cxx11_alignas_pass.cpp new file mode 100644 index 00000000..b8b84b93 --- /dev/null +++ b/test/no_cxx11_alignas_pass.cpp @@ -0,0 +1,37 @@ +// This file was automatically generated on Sun Apr 28 18:36:48 2013 +// by libs/config/tools/generate.cpp +// Copyright John Maddock 2002-4. +// Use, modification and distribution are subject to the +// Boost Software License, Version 1.0. (See accompanying file +// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org/libs/config for the most recent version.// +// Revision $Id$ +// + + +// Test file for macro BOOST_NO_CXX11_ALIGNAS +// This file should compile, if it does not then +// BOOST_NO_CXX11_ALIGNAS should be defined. +// See file boost_no_cxx11_alignas.ipp for details + +// Must not have BOOST_ASSERT_CONFIG set; it defeats +// the objective of this file: +#ifdef BOOST_ASSERT_CONFIG +# undef BOOST_ASSERT_CONFIG +#endif + +#include +#include "test.hpp" + +#ifndef BOOST_NO_CXX11_ALIGNAS +#include "boost_no_cxx11_alignas.ipp" +#else +namespace boost_no_cxx11_alignas = empty_boost; +#endif + +int main( int, char *[] ) +{ + return boost_no_cxx11_alignas::test(); +} +