diff options
Diffstat (limited to 'boost/align/detail/assume_aligned_clang.hpp')
-rw-r--r-- | boost/align/detail/assume_aligned_clang.hpp | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/boost/align/detail/assume_aligned_clang.hpp b/boost/align/detail/assume_aligned_clang.hpp index d72b4cae86..2ba41c6970 100644 --- a/boost/align/detail/assume_aligned_clang.hpp +++ b/boost/align/detail/assume_aligned_clang.hpp @@ -1,6 +1,6 @@ /* (c) 2015 Glen Joseph Fernandes -glenjofe at gmail dot com +<glenjofe -at- gmail.com> Distributed under the Boost Software License, Version 1.0. @@ -9,11 +9,9 @@ http://boost.org/LICENSE_1_0.txt #ifndef BOOST_ALIGN_DETAIL_ASSUME_ALIGNED_CLANG_HPP #define BOOST_ALIGN_DETAIL_ASSUME_ALIGNED_CLANG_HPP -#include <stdint.h> - -#if defined(__has_builtin) && __has_builtin(__builtin_assume) +#if __has_builtin(__builtin_assume_aligned) #define BOOST_ALIGN_ASSUME_ALIGNED(ptr, alignment) \ -__builtin_assume((uintptr_t(ptr) & ((alignment) - 1)) == 0) +(ptr) = __builtin_assume_aligned((ptr), (alignment)) #else #define BOOST_ALIGN_ASSUME_ALIGNED(ptr, alignment) #endif |