1
0
forked from boostorg/core
Commit Graph

617 Commits

Author SHA1 Message Date
Glen Fernandes 31117ef800 Implement pointer_in_range 2024-04-08 09:56:16 -04:00
Braden Ganetsky a973490f53 Fix deprecated warning ignores in allocator_access.hpp, and add compile test for pmr allocator 2024-03-17 20:12:06 -05:00
Andrey Semashev 0fb4d92d83 Moved checked deleters into internal namespace to block unintended ADL.
This prevents adding namespace boost to ADL when the deleters are used
in template parameters, e.g. in std::unique_ptr.
2024-02-07 15:12:36 +03:00
Ruben Perez 59c0fb69f0 Constructor from std::string_view is now constexpr
close #163
2024-02-06 23:15:26 +01:00
Andrey Semashev 0a35bb6a20 Move functor to its own namespace to block bringing boost::core to ADL. 2024-02-02 05:23:00 +03:00
Andrey Semashev 95f0b35c36 Move fclose_deleter and null_deleter to their own namespaces to block ADL.
This prevents bringing namespace boost into ADL when the deleters are used
in template parameters, e.g. in std::unique_ptr.
2024-02-02 05:17:19 +03:00
Andrey Semashev 80e12e1116 Added a new boost/core/functor.hpp header.
The feader defines a new functor class template that can be used to wrap
raw functions into a function object class. This is useful, for example,
for integrating std::unique_ptr and unique_resource with custom deleters
implemented as raw functions (e.g. in C libraries).
2024-01-26 20:51:02 +03:00
Peter Dimov e4adc769aa Disable use of std::launder under msvc-14.1. Fixes #160. 2024-01-04 04:07:34 +02:00
Peter Dimov 6c95750f37 Use BOOST_GCC instead of BOOST_GCC_VERSION 2023-11-30 10:33:08 +02:00
Andrey Semashev a9f1407d84 Added a sanity check to prevent duplicate definition of BOOST_CORE_HAS_BUILTIN_BIT_CAST. 2023-11-25 16:04:12 +03:00
Andrey Semashev db0fd77af1 Added support for __builtin_bswap16. 2023-11-25 16:04:12 +03:00
Daniel Richard G 0120dbfe65 Fix Intel compiler build 2023-10-05 20:26:24 -04:00
Andrey Semashev 5f6fe65eb2 Merge pull request #149 from boostorg/feature/invoke_swap
Rename `boost::swap` to `boost::core::invoke_swap`, deprecate `boost::swap`
2023-08-25 14:50:06 +03:00
Peter Dimov c7134904e2 Android doesn't support pthread_setcancelstate. Fixes #150. 2023-07-25 18:03:51 +03:00
Andrey Semashev 9fc2a2f1ac Renamed boost::swap to boost::core::invoke_swap, deprecated boost::swap.
The rename allows to avoid forming an infinite recursion in compile time
(because of noexcept specification that needs to resolve the unqualified call
to swap) or run time (in case if the boost::swap function is the only one
suitable for the passed arguments).

To avoid the compile-time recursion, removed noexcept specification from
boost::swap. The specification is still present in boost::core::invoke_swap.

Deprecated boost::swap and associated headers. boost::core::invoke_swap
is defined in a new boost/core/invoke_swap.hpp header.

Updated docs and tests. Removed tests that check inclusion of deprecated
headers.

Fixes https://github.com/boostorg/core/issues/148.
2023-07-12 12:17:07 +03:00
Peter Dimov 216999e552 Avoid -Wsign-conversion warning in checked_delete.hpp 2023-06-25 13:46:53 +03:00
Peter Dimov 66890c3f3d Use SwitchToThread instead of Sleep(0) is sp_thread_yield; the general consensus is that it's newer and 'smarter' 2023-06-18 21:54:13 +03:00
Peter Dimov 0e71b6158d Add noexcept to yield primitives 2023-06-02 04:27:12 +03:00
Peter Dimov 23ef6d3531 Disable cancelation around nanosleep in sp_thread_sleep 2023-06-02 03:57:38 +03:00
Peter Dimov 57151ab82e Update sp_thread_pause.hpp 2023-06-02 02:05:36 +03:00
Peter Dimov 4e769d1cdd Add boost/core/yield_primitives.hpp 2023-06-01 23:08:32 +03:00
Peter Dimov 5a3b4df5de Use __builtin_bit_cast when available 2023-06-01 02:38:57 +03:00
Peter Dimov 85527c4045 More -Wconversion fixes 2023-05-31 20:22:15 +03:00
Peter Dimov 266fbe6449 Fix -Wconversion warnings 2023-05-31 18:53:35 +03:00
Peter Dimov 06fef712c9 Use MS _byteswap intrinsics 2023-05-30 21:12:25 +03:00
Peter Dimov f41b8f38c4 Use __builtin_bswap under GCC and Clang 2023-05-30 19:22:00 +03:00
Peter Dimov b591214103 Add byteswap to bit.hpp 2023-05-30 19:09:09 +03:00
Peter Dimov 6c7edac9b1 Fix 32 bit constexpr failures 2023-05-30 04:32:23 +03:00
Peter Dimov b2fe98edf8 Make bit manipulation functions constexpr on MSVC 19.25+. Closes #109. 2023-05-30 02:56:37 +03:00
Peter Dimov 36fa78f53c Add support for incomplete classes to type_name<>. Refs #145. 2023-05-21 05:52:33 +03:00
Peter Dimov 5eb54d1d36 Fix type_name<> for cv-qualified member pointers without variadic templates. Refs #145. 2023-05-21 05:33:21 +03:00
Peter Dimov 5904fb5636 Disable call to ::_seterrormode when WINAPI_FAMILY is defined to something other than WINAPI_FAMILY_DESKTOP_APP. Refs #143. 2023-04-15 19:36:12 +03:00
Glen Fernandes c4e420f69d Use boost::data in boost::span 2023-02-22 09:40:54 -05:00
Glen Fernandes 379899ef15 Move identity from functional to core 2023-02-20 23:02:30 -05:00
Peter Dimov 0be25e19cc Add load_construct_data_adl, save_construct_data_adl 2023-02-21 02:04:39 +02:00
Peter Dimov 38037b45f1 Add boost::core::split_member 2023-02-20 21:00:26 +02:00
Peter Dimov 89c5a78129 Add boost/core/serialization.hpp, serialization_nvp_test, serialization_split_free_test 2023-02-20 20:06:19 +02:00
Glen Fernandes 249c5bece2 Implement data and size functions 2023-02-17 15:27:36 -05:00
Glen Fernandes edc0d935c0 Implement make_span 2023-01-28 13:07:33 -05:00
Glen Fernandes 7736b0b8ce span support for initializer_list 2023-01-28 12:20:59 -05:00
Peter Dimov 1aa287e413 Avoid the inclusion of <new> 2023-01-26 19:37:46 +02:00
Peter Dimov 8c65a5b0e8 Work around g++ 4.6 failure 2023-01-26 19:18:44 +02:00
Peter Dimov 99515c341e Add boost::core::memory_resource 2023-01-26 18:09:35 +02:00
Peter Dimov 42b3a3f111 Use BOOST_CORE_ALIGNOF in boost/core/max_align.hpp 2023-01-26 03:17:05 +02:00
Peter Dimov c092532a71 Merge branch 'develop' into feature/max-align 2023-01-26 03:06:45 +02:00
Peter Dimov 39cf1e65a3 Add BOOST_CORE_ALIGNOF 2023-01-25 20:10:31 +02:00
Peter Dimov 3edd3aa982 Define and use BOOST_CORE_HAS_FLOAT128 2023-01-25 19:38:20 +02:00
Peter Dimov ece7a9ad9c Update max_align_test.cpp 2023-01-25 01:52:18 +02:00
Peter Dimov 5632ee0367 Test __SIZEOF_FLOAT128__ as well, for g++ -m32 2023-01-25 01:41:01 +02:00
Peter Dimov 8052abb15c Add boost::core::max_align(_t) 2023-01-24 21:06:07 +02:00