1 // (C) Copyright John Maddock 2012
2 // (C) Copyright Peter Dimov 2014
4 // Use, modification and distribution are subject to the
5 // Boost Software License, Version 1.0. (See accompanying file
6 // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
8 // See http://www.boost.org/libs/config for more information.
10 // MACRO: BOOST_NO_CXX11_STD_ALIGN
11 // TITLE: C++11 <memory> doesn't have a working std::align
12 // DESCRIPTION: The compiler does not support the function std::align added to <memory>
16 namespace boost_no_cxx11_std_align {
22 void * ptr = buffer + 1;
23 std::size_t space = sizeof( buffer ) - 1;
25 void * p2 = std::align( 4, 2, ptr, space );
27 if( p2 == 0 ) return 1;
28 if( p2 != ptr ) return 1;
29 if( (size_t)p2 % 4 ) return 1;