////
Distributed under 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)
Official repository: https://github.com/boostorg/website-v2-docs
////

== Version 1.91.0

boost_at:/doc/libs/1_91_0/[Documentation]

// Formatting reference: https://docs.asciidoctor.org/asciidoc/latest/syntax-quick-reference/
// Boost-specific macros: https://github.com/cppalliance/asciidoctor-boost?tab=readme-ov-file#macros
// Please keep the list of libraries sorted in lexicographical order.

== General Notes

* boost_phrase:library[StaticAssert,/libs/static_assert/] has been merged into boost_phrase:library[Config,/libs/config/]. This includes code, tests and documentation. For backward compatibility git submodule, CMake and b2 targets of StaticAssert are still available; the targets simply introduce a dependency on Config. Eventually, the submodule and targets will be removed. Users are recommended to update their dependencies on StaticAssert to replace it with Config. No C++ code modifications are necessary. Most Boost libraries have been updated accordingly.

== New Libraries

// Example:
//
// * boost_phrase:library[Accumulators,/libs/accumulators]:
// ** Framework for incremental calculation, and collection of statistical
// accumulators, from Eric Niebler.

* boost_phrase:library[Decimal,/libs/decimal]:
** An implementation of IEEE754 Decimal Floating Point Numbers, from Matt Borland and Christopher Kormanyos.

== Updated Libraries

// Example:
//
// * boost_phrase:library[Interprocess,/libs/interprocess/]:
// ** Added anonymous shared memory for UNIX systems.
// ** Conform to `std::pointer_traits` requirements (boost_gh:pr[interprocess,32]).
// ** Fixed `named_condition_any` fails to notify (boost_gh:issue[interprocess,62]).

* boost_phrase:library[Any,/libs/any/]:
** Fixed `import std` detection in CMake.
** Simplified implementation of `boost::anys::basic_any`.

* boost_phrase:library[Asio,/libs/asio/]
** Added optional binary versioning via an inline namespace, allowing multiple Asio versions to coexist in the same process without symbol conflicts.
** Changed the default Windows mutex implementation from `CRITICAL_SECTION` to `SRWLOCK`.
** Added a "slim" mutex implementation based on `std::atomic`, reducing state size for strands, sockets, and other descriptors.
** Added support for compilation under Cygwin64, including without `__USE_W32_SOCKETS`.
** Added the ability to override `BOOST_ASIO_DECL` before including Asio headers.
** Fixed `MSG_NOSIGNAL` handling on NetBSD.
** Fixed the build with recent Boost versions that no longer support linking against `boost_system`.
** Fixed compatibility with musl libc on older Android.
** Fixed detection of `std::aligned_alloc` on older Apple platforms.
** Fixed a warning in `serial_port_base::character_size::store` with MSVC.
** Clarified the IPv4 vs IPv6 semantics of `ip::multicast::outbound_interface` in the documentation.
** Updated TLS v1.3 context initialisation to correctly detect LibreSSL support.
** Fixed compatibility with recent OpenSSL API changes around `X509` constness.
** Consult the boost_at:/doc/libs/1_91_0/doc/html/boost_asio/history.html[Revision History] for further details.

* boost_phrase:library[Atomic,/libs/atomic/]:
** Fixed compilation of `thread_pause` on PowerPC with Apple compilers. (boost_gh:issue[atomic,79])

* boost_phrase:library[Beast,/libs/beast/]:
** Fixed typecast warnings in `inflate_with_eb`.
** Enforced 8KB sanity limit on chunk headers.
** Made OpenSSL an optional dependency for tests.
** Removed dependency on Boost.StaticAssert.
** Added `HTTP2-Settings` to HTTP field enum.

* boost_phrase:library[Charconv,/libs/charconv/]:
** Fixed overflow in `to_chars` of negative 128-bit integers whose absolute value is less than 2^64

* boost_phrase:library[Core,/libs/core/]:
** The header `boost/is_placeholder.hpp` has been moved from Bind to Core. (https://github.com/boostorg/core/issues/90[#90])

* boost_phrase:library[Describe,/libs/describe/]:
** Under {cpp}20, described nested enums now work when the enclosing class is still incomplete. (Thanks to Julien Blanc.)
** Made `enum_to_string` constexpr. (Thanks to Julien Blanc.)

* boost_phrase:library[DynamicBitset,/libs/dynamic_bitset/]:
** Added a missing friend declaration for `operator-( const bit_iterator_base< Iter > & lhs, const bit_iterator_base< Iter > & rhs )`.
** Fixed compilation with standard library implementations which use raw pointers as iterators.
** Fixed `from_block_range()` to prevent it from setting any bit in the unused part of the bitset.

* boost_phrase:library[Exception,/libs/exception/]:
** Added customizable serialization API, built-in support for Boost.JSON and nlohmann/json.

* boost_phrase:library[Filesystem,/libs/filesystem/]:
** Boost.Filesystem now defines and uses its own platform macros `BOOST_FILESYSTEM_POSIX_API` and `BOOST_FILESYSTEM_WINDOWS_API`. The old `BOOST_POSIX_API` and `BOOST_WINDOWS_API` macros are still defined by Boost.System. Boost.Filesystem will check that the two sets of macros are in sync and by default will fail to compile if not. The compilation error can be reduced to a warning by defining `BOOST_FILESYSTEM_ALLOW_SYSTEM_API_MISMATCH` to 1 or disabled entirely by defining it to 2. Note that in this case the error code values reported by Boost.Filesystem will not match the error category.
** On POSIX platforms not supporting `openat` and related APIs, fixed an error reported by `recursive_directory_iterator` increment when the iterator encounters a dangling symlink and following symlinks is disabled.
** *Breaking change for Cygwin users.* The library now treats Cygwin as a POSIX platform. This has several user-facing consequences, in particular:
*** The `path::value_type` type has changed from `wchar_t` to `char`. As on other POSIX platforms, wide character paths will be converted to the narrow character encoding using the locale set by `path::imbue`. Note that since Cygwin is running on top of Windows, it will also perform character code conversion internally. It is important that locale in the Cygwin environment is configured correctly.
*** Path syntax now follows POSIX conventions, Windows-specific paths (e.g. UNC paths, drive names and path prefixes) are not supported.
*** Certain Windows-specific parts of the API will become inaccessible. Since reparse points are a Windows-only feature, `file_type::reparse_file` will not be reported for files. Reparse point handling is dependent on Cygwin runtime behavior.
*** Cygwin has its own implementation of symlinks that is incompatible with native Windows symlinks. Boost.Filesystem will now create and operate on Cygwin symlinks.
*** Error codes reported by Boost.Filesystem will now use POSIX `errno` values.
** On DragonFly BSD, NetBSD and Solaris, Boost.Filesystem default path locale now uses UTF-8 for path character encoding.
** On Linux, use `read`/`write` loop implementation of `copy_file` and `copy` for configfs, securityfs, cgroup and cgroup2 filesystems, in addition to the previously blacklisted filesystems.

* boost_phrase:library[JSON,/libs/json/]:
** Changed `value` construction from `std::initializer_list` to use `value_from`.

* boost_phrase:library[LEAF,/libs/leaf/]:
** Added customizable serialization API, built-in support for Boost.JSON and nlohmann/json.
** Added support for using LEAF error objects across DLL boundaries on Windows (off by default).
** Refinements in the internal TLS API (e.g. Win32, embedded).
** Improvements in the diagnostics system and in the  `on_error` implementation.
** Implementation quality improvements (e.g. more precise use of `noexcept`).
** Removed the deprecated `verbose_diagnostic_info` (replaced by `diagnostic_details`).

* boost_phrase:library[LexicalCast,/libs/lexical_cast/]:
** Implemented initial version of C++20 module `boost.lexical_cast`.

* boost_phrase:library[Log,/libs/log/]:
** Enabled building interprocess communication support on Cygwin by default.

* boost_phrase:library[Math,/libs/math/]:
** Added `find_non_centrality` finding function for `non_central_f_distribution`
** Added parameter finding function for `non_central_t_distribution`
** Added function for the log of the incomplete gamma function, `lgamma_q`
** Added function for the log of the lower incomplete gamma function, `lgamma_p`
** Added `domain()` function for `pchip`
** Fixed broken CUDA support in the logistic distribution
** Fixed incorrect floating point traits for Windows on ARM64
** Fixed incorrect result `ibeta` for large arguments
** Fixed incorrect `ellint_2` for N * PI / 2 for phi argument.
** Require user to explicitly enable CUDA rather than assuming based off presence of NVCC

* boost_phrase:library[MultiIndex,/libs/multi_index/]:
** *Breaking change:* All type lists accepted or provided by the library (`indexed_by`,
`tag`, nested typedefs `index_specifier_type_list`, `index_type_list`, `iterator_type_list`
and `const_iterator_type_list`) are no longer based on boost_at:/libs/mpl[Boost.MPL] but
instead they are now boost_at:/libs/mp11/doc/html/mp11.html#definitions[Boost.Mp11 lists].
As a result, Boost.MultiIndex doesn't depend anymore on Boost.MPL. It is expected that
most user code won't be impacted by this change, but the previous behavior may be restored,
however, by globally defining the macro `BOOST_MULTI_INDEX_ENABLE_MPL_SUPPORT`. Legacy
support for Boost.MPL may be eventually deprecated and removed in the future.
** *Breaking change:* `composite_key` and associated class templates
(`composite_key_equal_to`, `composite_key_compare`, `composite_key_hash`) have been made
variadic (previously the maximum number of template arguments was limited by
`BOOST_MULTI_INDEX_LIMIT_COMPOSITE_KEY_SIZE`). This change should be transparent to users,
with the exception that `composite_key::key_extractors` returns a `std::tuple` instead of
a `boost::tuple` (and similarly for the rest of affected class templates).
** Removed internal workarounds and fallbacks to support pre-C++11 compilers.

* boost_phrase:library[MSM,/libs/msm/]:
** New features (`backmp11`):
*** Improve support for the `deferred_events` property in hierarchical state machines (https://github.com/boostorg/msm/issues/173[#173])
*** Support conditional deferral with the `deferred_events` property (https://github.com/boostorg/msm/issues/155[#155])
*** Simplified functor signatures (https://github.com/boostorg/msm/issues/175[#175])
*** Merge queued and deferred events into a single event pool (https://github.com/boostorg/msm/issues/168[#168])
*** Small object optimization for events in the event pool (https://github.com/boostorg/msm/issues/172[#172])
*** Improve runtime performance with a `flat_fold` dispatch strategy (https://github.com/boostorg/msm/issues/180[#180])
*** Further optimize compilation, with up to 25% faster compile times and lower RAM consumption compared to version 1.90
** Bug fixes (`backmp11`):
*** Incorrect `FSM` type in calls to `on_entry(...)` and `on_exit(...)` (https://github.com/boostorg/msm/issues/167[#167])
*** Completion events fire too often (https://github.com/boostorg/msm/issues/166[#166])
*** Transitions in hierarchical state machines are not selected correctly (favor_compile_time) (https://github.com/boostorg/msm/issues/200[#200])
*** `state_machine` cannot be moved (https://github.com/boostorg/msm/issues/205[#205])
** **Breaking change (`backmp11`)**: Direct access to the event pool is changed from `public` to `protected`,
because manipulating it outside of the library code can lead to undefined behavior.
* boost_phrase:library[OpenMethod,/libs/openmethod/]:
** Inter-operation with `boost::intrusive_ptr`.
* boost_phrase:library[Optional,/libs/optional/]:
** For compilers with full C++11 support (including "unrestricted  unions" and ref-qualifiers)
  changed the implementation from aligned storage to union storage. This enables the gradual
  `constexpr` support:

*** In C++11, some constructors and `const`-qualified accessors become usable
      in compile-time contexts (are _core constant expressions_) for types
      satisfying certain constraints.
*** In C++14 even some mutating operations become core constant expressions (those
      that do not require changing the state of `optional` from not having a value to
      having a value), for co-operating types.
*** In C++17 all constructors (including copy and move) become core constant expressions for co-operating types.

+

This addresses issues https://github.com/boostorg/optional/issues/132[#132] and https://github.com/boostorg/optional/issues/143[#143].

** *Breaking change.* Abandoned the mechanism for customizing
  `swap`. Hardly anyone knows about this mechanism and it was never documented.

** Applied a couple of small changes to get closer to the interface of `std::optional`:
  *** Enabled syntax `o = {}` for putting optional objects to no-value state.
  *** Enabled syntax `o.value_or({})`, which uses a default-constructed `T`.
  *** Construct `o = u`, where `o` is of type `optional<T>` and `u` is of type `U` convertible to `T`,
    does not create a temporary `T`.

** Added a conversion from `optional<T>&` to `optional<T&>`. This addresses https://github.com/boostorg/optional/issues/142[#142].

** `none_t` is now `std::equality_comparable`, which means that `none_t` and `optional<T>`
  model concept `std::equality_comparable_with` (for `std::equality_comparable` `T`),
  which means that you can `std::ranges::find(rng, boost::none)` for a range of optional objects.

** *Warning.* In the future releases we intend to introduce the range interface
  in `optional`, so that `std::ranges::range<optional<T>>` will be `true`.
  This will affect the overload resolution in programs in certain cases that make decisions based
  on predicates such as `std::ranges::range`. For instance, the following code
  will start behaving differently:

+

  template <typename T>
  void serialize(T const& v)
  {
    if constexpr (std::ranges::range<T>)
      serialize_as_range(v);
    else if constexpr (custom::is_optional_like<T>)
      serialize_as_optional(v);
    else
      serialize_as_value(v);
  }


* boost_phrase:library[PFR,/libs/pfr/]:
** Added experimental C++26 Reflection based implementation. Define `BOOST_PFR_USE_CPP26_REFLECTION`
   macro to `1` to enable.
** `boost::pfr::for_each_field*()` functions now work well with stateful visitors.

* boost_phrase:library[Random,/libs/random/]:
** Fixed unsigned types in `binomial_distribution` being inadvertently unsupported.

* boost_phrase:library[Redis,/libs/redis/]:
** Added built-in support for **Sentinel** deployments, which can be configured
   using `config::sentinel`. The library handles master/replica discovery,
   error detection, and reconnection automatically
   (boost_gh:pr[redis,345], boost_gh:pr[redis,391], boost_gh:issue[redis,237]).
** Added **`generic_flat_response`**, a high-performance replacement for
   `flat_response` that uses contiguous memory and performs zero allocations
   in steady state. Many thanks to Nikolai Vladimirov for the PR
   (boost_gh:pr[redis,340], boost_gh:pr[redis,356], boost_gh:pr[redis,358],
   boost_gh:pr[redis,378], boost_gh:pr[redis,383], boost_gh:issue[redis,263]).
** General improvements to **server push handling**:
*** Added support for subscription tracking, which restores
    active subscriptions after each reconnection. Can be accessed using
    `request::subscribe`, `request::psubscribe`, `request::unsubscribe`
    and `request::punsubscribe`
    (boost_gh:pr[redis,375], boost_gh:issue[redis,367]).
*** Added `push_parser`, a view that facilitates parsing
    PubSub-related messages (boost_gh:pr[redis,390], boost_gh:issue[redis,349]).
*** **`connection::async_receive`** and **`connection::receive`** are now **deprecated**.
    Users should prefer `async_receive2`, which allows for faster batch processing
    (boost_gh:pr[redis,381], boost_gh:pr[redis,340], boost_gh:issue[redis,331]).
*** **`consume_one`** is now **deprecated**. Users should prefer
    `generic_flat_response::clear`, instead. See the PubSub examples for more details.
*** Improved the documentation and examples.
** **`config::username`**, **`config::password`**, **`config::client_name`** and
   **`config::database_index`** are now **deprecated**. Users should prefer `config::setup`, instead.
   Added `request::hello` and `request::hello_setname` to simplify composing
   setup requests (boost_gh:pr[redis,392]).
** Log message levels have been adjusted to be more relevant:
   `level::error` for configuration and network errors,
   `level::info` for successful connection attempts,
   and `level::debug` for verbose output
   (boost_gh:pr[redis,389], boost_gh:issue[redis,395]).
** Added `request::append()` to concatenate request objects
   (boost_gh:pr[redis,342], boost_gh:issue[redis,341]).
** Fixed a problem causing `request::push_range` to generate invalid commands
   when passed a range with `std::tuple` elements
   (boost_gh:pr[redis,363], boost_gh:issue[redis,360]).
** Removed `<ostream>` from public headers to make them more lightweight
   (boost_gh:pr[redis,364], boost_gh:issue[redis,361]).

* boost_phrase:library[Stacktrace,/libs/stacktrace/]:
** Removed the compile time check for a possibly incompatible runtime. As a result
   there are no false positives and the `from_exception` functionality just works
   out-of-the-box. Rare cases of incompatible/leaking runtimes are now reported at runtime.
** Disable `from_exception` on cygwin (boost_gh:pr[stacktrace,219]). Many thanks to David McFarland
   for the PR!
** Removed the `has_addr2line` link with C++ Standard Library to simplify builds with non
   system-default `libstdc++.so`

* boost_phrase:library[System,/libs/system/]:
** The return type of `operator|(result<T&>, U)` has been changed to non-reference.
** Pointers to members in `r & f` are now supported (by using `boost::compat::invoke`).
** A CMake config file is now installed, even though the library is header-only. This
   avoids breaking third-party `CMakeLists.txt` files that contain
   `find_package(Boost COMPONENTS system ...)`.
** `error_code` is now even more `constexpr` under {cpp}20 and later.
** Added `unsafe_value` to `result`.
** Changed `result<>::operator*` and `result<>::operator\->` to throw when `!has_value()`,
   instead of having that as a precondition. The old behavior is now spelled `unsafe_value()`.
** Added `boost/system/unwrap_and_invoke.hpp`.

* boost_phrase:library[Test,/libs/test/]:
** Add friend operators for proper comparisons of `std::optional` with GCC < 10

* boost_phrase:library[TypeIndex,/libs/type_index/]:
** Optimized CTTI type comparisons starting from C++20.
** `ctti_type_index::name()` now returns pretty value by default in C\+\+14 and more modern C\+\+ standards.
   Reduced the size of library binaries.

* boost_phrase:library[Unordered,/libs/unordered/]:
** Fixed the returned value of range insertion in concurrent containers (boost_gh:pr[unordered,344]).

* boost_phrase:library[UUID,/libs/uuid/]:
** Added `from_chars` to `boost/uuid/uuid_io.hpp`.
** Added a `noexcept` `operator()` overload to `string_generator`.
** `string_generator` now supports the Unicode character types in addition to `char` and `wchar_t`.
** Most `uuid` accessors, operations, and `to_chars` are now `constexpr` when possible (on {cpp}14 and higher and on recent compilers).
** Added SIMD implementation of `to_chars`, which can offer up to 5.5x performance improvement in UUID formatting. (Andrey Semashev)
** Added SIMD implementation of `from_chars`, which can offer up to 13x performance improvement in UUID parsing. (Andrey Semashev)
** Added `uuid_from_string` to `boost/uuid/uuid_io.hpp`.
** Added a dedicated `invalid_uuid` exception class, derived from `std::runtime_error` for backward compatibility.

* boost_phrase:library[URL,/libs/url/]:
** Features:
*** All parse functions are now `constexpr` under {cpp}20, enabling compile-time URL parsing and validation (boost_gh:pr[url,976]).
*** Added `get_or` for query containers, returning a default value when a key is not present (boost_gh:pr[url,953]).
*** Added standalone `decode` and `decoded_size` free functions (boost_gh:pr[url,952]).
*** Added user-provided `RangeRule` support for `grammar::range`, allowing custom grammar rules (boost_gh:pr[url,950]).
*** Specialized `std::ranges::enable_borrowed_range` for all view types (boost_gh:pr[url,966]).
*** Added EBO and default construction for `token_rule_t` (boost_gh:pr[url,964]).
*** Added natvis visualizers for segments (boost_gh:pr[url,962]).
** Performance:
*** Internal URL offsets changed from `size_t` to `uint32_t`, reducing object size on 64-bit platforms (boost_gh:pr[url,969]).
** Fixes:
*** `normalize_path` ambiguity from dot-dot cancellation (boost_gh:pr[url,986]).
*** `parse_query` guard for empty `string_view` inputs (boost_gh:pr[url,949]).
*** `params_iter_impl::decrement()` decoded size for values containing `=` (boost_gh:pr[url,978]).
*** `decode_view::remove_prefix`/`remove_suffix` assertion (boost_gh:pr[url,978]).
*** `decode_view` completeness for `pct_string_view::operator*()` (boost_gh:pr[url,963]).
*** Example router is now move-only (boost_gh:pr[url,959]).
*** GCC false-positive `-Wmaybe-uninitialized` in `tuple_rule` (boost_gh:pr[url,981]).
*** Security review by Laurel Lye Systems Engineering: three rounds of assessment, 21 confirmed fixes, public interface boundary tests and fuzz tests added (boost_gh:pr[url,982], boost_gh:pr[url,988]).
** Documentation:
*** Added design rationale page (boost_gh:pr[url,987]).
*** Documented plus scheme convention (boost_gh:pr[url,970]).
*** Removed legacy QuickBook documentation.

* boost_phrase:library[Variant2,/libs/variant2/]:
** `holds_alternative<T>` and `get<T>` have been relaxed to no longer require `T` to occur exactly once in the list of alternatives. It now must occur at least once.

== Compilers Tested

// Edit this section as appropriate

Boost's primary test compilers are:

* Linux:
** Clang, C++03: 3.4, 3.5, 3.6, 3.7, 3.8, 3.9, 12.0.0, 13.0.0, 14.0.0, 15.0.0
** Clang, C++11: 3.4, 11.0.0, 13.0.0, 14.0.0, 15.0.0
** Clang, C++14: 3.5, 3.6, 3.7, 3.8, 3.9, 4.0, 5.0, 12.0.0, 13.0.0, 14.0.0, 15.0.0
** Clang, C++17: 6.0.1, 7.0.0, 8.0.0, 9.0.0, 10.0.0, 11.0.0, 12.0.0, 13.0.0, 14.0.0, 15.0.0
** Clang, C++20: 11.0.0, 12.0.0, 13.0.0, 14.0.0, 15.0.0
** GCC, C++03: 4.6.3, 11, 12
** GCC, C++11: 4.7.3, 4.8.5, 11, 12
** GCC, C++14: 5.4.0, 6.4.0, 7.3.0, 8.0.1, 9.1.0, 11, 12
** GCC, C++17: 7.3.0, 8.0.1, 9.1.0, 11, 12
** GCC, C++20: 8.0.1, 9.1.0, 10, 11, 12
* OS X:
** Apple Clang, C++03: 11.0.3
** Apple Clang, C++11: 11.0.3
** Apple Clang, C++14: 11.0.3
** Apple Clang, C++17: 11.0.3
** Apple Clang, C++20: 11.0.3
* Windows:
** Visual C++: 10.0, 11.0, 12.0, 14.0, 14.1, 14.2, 14.3

== Acknowledgements

// Edit this section as appropriate

Marshall Clow, Glen Fernandes and Ion Gaztañaga managed this release.
