Skip to content

Commit ae5472d

Browse files
committed
Update contrib/restricted/boost/core to 1.85.0
1bb2acda6377c988e483392dfbb76ef5b0a6adec
1 parent 788be07 commit ae5472d

File tree

3 files changed

+30
-3
lines changed

3 files changed

+30
-3
lines changed

contrib/restricted/boost/core/include/boost/core/bit.hpp

Lines changed: 19 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,12 +47,19 @@
4747
# if __has_builtin(__builtin_bit_cast)
4848
# define BOOST_CORE_HAS_BUILTIN_BIT_CAST
4949
# endif
50+
# if __has_builtin(__builtin_bswap16)
51+
# define BOOST_CORE_HAS_BUILTIN_BSWAP16
52+
# endif
5053
#endif
5154

52-
#if defined(BOOST_MSVC) && BOOST_MSVC >= 1926
55+
#if !defined(BOOST_CORE_HAS_BUILTIN_BIT_CAST) && (defined(BOOST_MSVC) && BOOST_MSVC >= 1926)
5356
# define BOOST_CORE_HAS_BUILTIN_BIT_CAST
5457
#endif
5558

59+
#if !defined(BOOST_CORE_HAS_BUILTIN_BSWAP16) && (defined(BOOST_GCC) && BOOST_GCC >= 40800)
60+
# define BOOST_CORE_HAS_BUILTIN_BSWAP16
61+
#endif
62+
5663
namespace boost
5764
{
5865
namespace core
@@ -825,11 +832,22 @@ BOOST_CONSTEXPR inline boost::uint8_t byteswap_impl( boost::uint8_t x ) BOOST_NO
825832
return x;
826833
}
827834

835+
#if defined(BOOST_CORE_HAS_BUILTIN_BSWAP16)
836+
837+
BOOST_CONSTEXPR inline boost::uint16_t byteswap_impl( boost::uint16_t x ) BOOST_NOEXCEPT
838+
{
839+
return __builtin_bswap16( x );
840+
}
841+
842+
#else
843+
828844
BOOST_CONSTEXPR inline boost::uint16_t byteswap_impl( boost::uint16_t x ) BOOST_NOEXCEPT
829845
{
830846
return static_cast<boost::uint16_t>( x << 8 | x >> 8 );
831847
}
832848

849+
#endif
850+
833851
#if defined(__GNUC__) || defined(__clang__)
834852

835853
BOOST_CXX14_CONSTEXPR inline boost::uint32_t byteswap_impl( boost::uint32_t x ) BOOST_NOEXCEPT

contrib/restricted/boost/core/include/boost/core/checked_delete.hpp

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,10 @@ template<class T> inline void checked_array_delete(T * x) BOOST_NOEXCEPT
6060
delete [] x;
6161
}
6262

63+
// Block unintended ADL
64+
namespace checked_deleters
65+
{
66+
6367
template<class T> struct checked_deleter
6468
{
6569
typedef void result_type;
@@ -83,6 +87,11 @@ template<class T> struct checked_array_deleter
8387
}
8488
};
8589

90+
} // namespace checked_deleters
91+
92+
using checked_deleters::checked_deleter;
93+
using checked_deleters::checked_array_deleter;
94+
8695
} // namespace boost
8796

8897
#endif // #ifndef BOOST_CORE_CHECKED_DELETE_HPP

contrib/restricted/boost/core/ya.make

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,9 @@ LICENSE(
99

1010
LICENSE_TEXTS(.yandex_meta/licenses.list.txt)
1111

12-
VERSION(1.84.0)
12+
VERSION(1.85.0)
1313

14-
ORIGINAL_SOURCE(https://github.com/boostorg/core/archive/boost-1.84.0.tar.gz)
14+
ORIGINAL_SOURCE(https://github.com/boostorg/core/archive/boost-1.85.0.tar.gz)
1515

1616
PEERDIR(
1717
contrib/restricted/boost/assert

0 commit comments

Comments
 (0)