December 2022

Boost 1.81.0: Major release now available

Just in time for the holidays, a major new Taylor Swift album Boost library release just dropped:

Boost verison 1.81.0 released

Release managers: Marshall Clow and Glen Fernandes

From the announcement:

New Libraries

  • URL:A library for parsing, modifying, and printing URLs using only C++11, from Vinnie Falco and Alan de Freitas. Features include fast compilation, strong invariants, and strict compliance using a memory-friendly approach.

Updated Libraries

  • Asio:
    • Added the consign completion token adapter, which can be used to attach additional values to a completion handler.
    • Added any_completion_handler<>, which can be used to type-erase completion handlers.
    • Added experimental::co_composed to enable lightweight implementations of user-defined asynchronous operations using C++20 coroutines.
    • Add range-based experimental::make_parallel_group() overloads.
    • Added any_completion_executor, a type-erased wrapper for executors that are associated with completion handlers.
    • Added missing context query to use_future's executor.
    • Added nothrow constructor overloads to execution::any_executor<> and any_io_executor.
    • Optimised representation of empty execution::any_executor objects to improve the performance of copy and move operations.
    • Added an associated_cancellation_slot specialisation for std::reference_wrapper.
    • Changed I/O objects to return their executors by const reference.
    • Changed associated to use deduced return types for all two-argument get functions.
    • Fixed spawn implementation to catch unhandled exceptions and rethrow them outside of the spawned "thread".
    • Fixed spawn to ensure the completion handler is dispatched through the correct executor.
    • Fixed cleanup of of terminal-state spawn "thread" objects.
    • Fixed spawn and co_spawn implementations to dispatch cancellation handlers on the correct executor.
    • Changed semantics of 'dispatch' to mean the executor is used as-is.
    • Deprecated the execution::execute customisation point and sender/receiver facilities.
    • Added a C++11 parallel_group example.
    • Fixed example code to not use the deprecated resolve conversions.
    • Fixed an ambiguity in experimental::channel_traits specialisations.
    • Added a specialised channel implementation for the for R(error_code) signature.
    • Made cancelled() public on the async_compose 'self' object.
    • Added io_executor_type and get_io_executor to the async_compose 'self' object.
    • Fixed implementation of release() for Windows overlapped handles.
    • Enabled deferred awaiting for experimental::coro, regularised experimental::use_coro, and fixed allocator handling.
    • Cleaned up experimental::promise and made it an asynchronous operation object.
    • Constrained post/defer overloads on ability to require blocking.never.
    • Changed descriptor implementation to fall back to fcntl if ioctl fails with ENOTTY when setting non-blocking mode.
    • Fixed Xcode deprecation warnings related to use of sprintf.
    • Fixed the arguments passed to select_reactor::run when it is run on an internal thread.
    • Fixed compilation errors when BOOST_ASIO_DISABLE_SMALL_BLOCK_RECYCLING is defined.
    • Updated detection of C++20 coroutine support on clang 14 and later.
    • Changed standard library feature detection to always enable std::invoke_result when targeting C++17 or later.
    • Fixed detection of return type deduction with MSVC.
    • Updated the asynchronous operation requirements to relax the requirements on the associated executor.
    • Added io_uring to the implementation notes.
    • Consult the Revision History for further details.
  • Beast:
    • Add buffers_generator
    • Add beast::http::message_generator
    • Added buffer_ref, so beast buffers can be used with asio.
    • Support for per-operation cancellation
    • C++20 awaitable examples.
    • websocket per-message compression options
    • websocket timeout option api
    • multiple content length error
    • Support for default-completion and rebind
  • Container Hash:
    • Major update.
    • The specializations of boost::hash have been removed; it now always calls hash_value.
    • Support for BOOST_HASH_NO_EXTENSIONS has been removed. The extensions are always enabled.
    • All standard containers are now supported. This includes std::forward_list and the unordered associative containers.
    • User-defined containers (types that have begin() and end() member functions that return iterators) are now supported out of the box.
    • Described structs and classes (those annotated with BOOST_DESCRIBE_STRUCT or BOOST_DESCRIBE_CLASS) are now supported out of the box.
    • hash_combine has been improved.
    • The performance (and quality, as a result of the above change) of string hashing has been improved. boost::hash for strings now passes SMHasher in 64 bit mode.
    • The documentation has been substantially revised to reflect the changes.
  • Core:
    • empty_value members are now marked as constexpr.
    • Added fclose_deleter, a deleter that calls std::fclose on a pointer to std::FILE.
    • Bit manipulation utilities in boost/core/bit.hpp now explicitly require unsigned integers on input. (#129)
    • bit_width now returns int instead of a value of the input argument type. This follows resolution of LWG3656.
  • Describe:
    • To allow the inclusion of enumerators.hppbases.hpp, and members.hpp when the option -pedantic is used, the invocation of BOOST_DESCRIBE_ENUM has been moved from modifiers.hpp into a separate header, modifier_description.hpp. As a consequence, modifiers.hpp no longer includes enum.hpp. Code that has been relying on this implicit inclusion may fail, and will need to be fixed to include enum.hpp.
  • DLL:
    • Fixed path_from_handle implementation for Windows platforms, thanks to @SaltfishAmi for the bug report 57.
  • Filesystem:
    • Deprecated: path construction, assignment and appending from containers of characters, such as std::vector<char> or std::list<wchar_t>, is deprecated in v3 and removed in v4. Please use string types or iterators instead.
    • Deprecated: boost/filesystem/path_traits.hpp header is deprecated and will be removed in a future release. The header contained implementation details of path and should not be used in user's code.
    • Previously deprecated APIs will now generate compilation warnings on use. To suppress these warnings, BOOST_FILESYSTEM_ALLOW_DEPRECATED macro can be defined when compiling user's code.
    • Fixed compilation due to a missing include on POSIX systems that do not support *at APIs. (#250)
    • On Windows prior to 10, added a workaround for network share filesystem that produces ERROR_INVALID_PARAMETER when constructing directory iterators. (PR#246#245)
    • On Windows, fixed weakly_canonical failing with an ERROR_INVALID_FUNCTION error code if the path started with the "\\?\" prefix. (#247)
    • Added support for std::string_viewboost::string_view and boost::container::string (as well as respective wchar_t counterparts) in path constructors, assignment and appending operations. (#208)
    • path constructors, assignment and appending operations taking a pair of iterators will no longer accept iterators with value types that are not one of the supported path character types.
    • On Windows, improved compatibility of directory_iterator with various mounted filesystems and Wine releases prior to 7.21. (#255#266)
    • On Windows, deduplicated files are now reported as regular files rather than reparse files. (#262)
  • Fusion:
    • Added fusion::identity_view (PR#240)
    • Added support for associative sequences on fusion::transform_view (PR#239)
    • Fixed compilation for the case when fusion::reverse_view used with an associative sequence (PR#237)
    • Fixed Clang 13 -Wdeprecated-copy warnings (PR#261)
    • A small dependency reorganization. Now boost::ref and boost::noncopyable are used from Boost.Core (PR#249)
    • Added CI testing on Linux and MacOS for clang and gcc, fixed CI testing on Windows (PR#245PR#236)
    • Improved docs and fixed typos (#234PR#235PR#238)
  • Geometry:
    • Solved issues
      • #1048 Index: Fix dangling references when Indexable is returned by value by IndexableGetter
      • #1076 Union: in rare cases it might miss one polygon
      • #1081 Union: due to precision it might miss interior rings
    • Bugfixes
      • #1063 Intersection: fix a bug in intersection of simple spherical polygons
      • #1064 Formulas: fix a consistency issue in geodesic direct formulas
      • #1088 Point: Fix regression for custom point types
      • Various fixes for missing include files, warnings, C++20 compilation errors and documentation
  • Histogram:
    • Major update.
    • Added new accumulators::fraction to compute fractions, their variance, and confidence intervals
    • Added interval computers for fractions: utility::clopper_pearsonutility::wilson_intervalutility::jeffreys_intervalutility::wald_interval which can compute intervals with arbitrary confidence level
    • Added utility::confidence_level and utility::deviation types to pass confidence levels as probabilities or in multiples of standard deviation for all interval computers, respectively
    • Fixed internal sub_array and span in C++20
  • Iterator:
    • function_output_iterator now supports perfect forwarding of the assigned values to the wrapped function object. (PR#73)
    • Fixed compilation of constructing a function_input_iterator from result of post-incrementing another function_input_iterator. (#75)
    • The result of post-incrementing an iterator based on iterator_facade now supports operator->(it++)->foo is equivalent to (*it++).foo, which was supported before.
  • JSON:
    • Added object::stable_erase.
    • Added parse overload for std::istream and operator>> for value.
    • Added rvalue ref-qualified accessors for value.
    • Conversion traits were redesigned.
    • Added conversion support for described classes and enums, std::optionalstd::variant, and null-like types (including std::nullptr_tstd::nullopt_t, and std::monotype).
    • Added non-throwing conversion from value to user types.
  • LexicalCast:
    • Fixed compilation while casting volatile arithmetic types. Thanks to Giovanni Cerretani for the bug report #50.
    • Removed usage of deprecated headers. Thanks to Michael Ford for the PR PR#53.
  • Locale:
    • Major update with some breaking changes.
    • C++11 support is now required, support for C++03 and earlier is dropped
    • Some enums have been converted to enum classes - Avoids name clashes
    • Replace -sICU_LINK_LOCALE & -sICU_LINK by fine-grained configuration options as done in Boost.RegEx
    • Fix detection of libiconv allowing Boost.Locale to be build (again) on some platforms
    • Remove use of and support for std::auto_ptr
    • Make the codecvt using wchar_t on Windows assume/use UTF-16 enconding
    • Performance improvements: Make basic_formatdate_time & hold_ptr movable, Fix use of format cache
    • Make Boost.Locale compatible with more ICU versions (especially the tests)
    • Fix RTTI definitions for some classes (visibility issues)
    • Fix compatibility of the ICU backend with some libc++ versions
    • Fix return value of some operators to correctly return non-const *this
    • Fix int-overflow on negative roll of years in date_time
    • Handle or suppress many warnings which makes the build log cleaner
    • Add support for more Windows codepages
    • Fix support for Windows codepages like ISO-2022-JP
  • Nowide:
    • Fix build failure of tests on MSVC
  • Stacktrace:
    • The library does not use COM initialization any more. Thanks to Alex Guteniev for the bug report, clarifications and PR PR#123!
    • The library now may use BOOST_STACKTRACE_BACKTRACE_INCLUDE_FILE macro value while detecting the libbacktrace availability in b2, thanks to Ben Gemmill for the bug report #115.
    • Added BOOST_STACKTRACE_BACKTRACE_FORCE_STATIC macro to force a single backtrace_state static instance while using the libbacktrace. Thanks to the Rasmus Thomsen for the bug report #118!
    • Avoid unresolved references when including only the boost/stacktrace/stacktrace.hpp header. Thanks to the Long Deng for the bug report #116.
    • Optimized stacktrace printing by not calling strlen on Windows platforms. Thanks to Alex Guteniev for the bug report #122
  • PFR:
    • Improved detection of aggregate initializables in C++14 mode, thanks to Denis Mikhailov for the PR PR#97.
    • Suppress clang-tidy warnings, thanks to Alexander Malkov for the PRs PR#109PR#104.
    • Use fold expressions if they are supported by the compiler. Thanks to Jean-Michaël Celerier for the PR PR#96.
  • STLInterfaces:
    • Fix two ill-formed iterator_interface operators in pre-C++20 iterators with a const value_type.
  • System:
    • The macro BOOST_SYSTEM_DISABLE_THREADS can now be defined to disable the use of <mutex> (e.g. on single-threaded libstdc++).
    • Added value_typeerror_typein_place_valuein_place_error to result<>.
    • Added emplace to result<>.
  • Unordered:
    • Major update.
    • Added fast containers boost::unordered_flat_map and boost::unordered_flat_set based on open addressing.
    • Added CTAD deduction guides for all containers.
    • Added missing constructors as specified in LWG issue 2713.
  • Variant:
    • Avoid recursive inclusion of headers, thanks to Nathan Sidwell for the bug report #101.
    • Removed usage of deprecated headers, thanks to Michael Ford for the PR PR#96.
    • Fixed compilation on clang in C++23 mode, thanks to Ed Catmur for the PR PR#98.
  • Variant2:
    • Added support for boost::json::value_from and boost::json::value_to.

 

PVS-Studio 7.22: Visual Studio Code, Qt Creator, .NET 7

PVS-Studio 7.22 has been released. It includes plugins for Visual Studio Code and Qt Creator, support of .NET 7 projects analysis, enhanced Best Warnings filter and new diagnostic rules.

PVS-Studio 7.22: Visual Studio Code, Qt Creator, .NET 7

by Sergey Vasiliev

From the article:

New plugins provide even more options for cross-platform work. Now you can use them to work with logs: view warnings, filter them, sort them in a grid, etc. You can't run the analysis yet — we plan to add this feature in future releases.

PVS-Studio and RPCS3: the best warnings in one click

Best Warnings — the analyzer's mode that displays 10 most interesting warnings in the output window. We invite you to take a look at the updated Best Warnings mode on the example of the RPCS3 project check.

PVS-Studio and RPCS3: the best warnings in one click

by Alexander Kurenev

From the article:

Best Warnings is a special mechanism for the first acquaintance with the PVS-Studio static analyzer. The full analyzer's log can contain thousands of warnings. Therefore, if you want to evaluate the work of the analyzer and not waste time and effort on viewing a large report that was issued by a not yet configured analyzer, use the Best Warnings mechanism. Open the analyzer's log in the PVS-Studio plugin for Visual Studio and enable Best Warnings.

2022-12 Mailing Available

The 2022-12 mailing of new standards papers is now available.

 

WG21 Number Title Author Document Date Mailing Date Previous Version Subgroup
P0901R10 Size feedback in operator new Chris Kennelly 2022-11-09 2022-12 P0901R9 EWG Evolution
P1018R18 C++ Language Evolution status  pandemic edition  2022/07–2022/11 JF Bastien 2022-11-11 2022-12 P1018R17 EWG Evolution,All of WG21
P1018R19 C++ Language Evolution status JF Bastien 2022-11-15 2022-12 P1018R18 EWG Evolution,All of WG21
P1028R4 SG14 status_code and standard error object Niall Douglas 2022-10-28 2022-12 P1028R3 LEWG Library Evolution
P1202R5 Asymmetric Fences David Goldblatt 2022-11-11 2022-12 P1202R4 LWG Library
P1264R2 Revising the wording of stream input operations Louis Dionne 2022-12-04 2022-12 P1264R1 LWG Library
P1478R8 Byte-wise atomic memcpy Hans Boehm 2022-11-14 2022-12 P1478R7 All of WG21
P1619R2 Functions for Testing Boundary Conditions on Integer Operations Lisa Lippincott 2022-11-08 2022-12 P1619R1 LEWG Library Evolution
P2164R8 views::enumerate Corentin Jabot 2022-11-11 2022-12 P2164R7 LWG Library
P2167R3 Improved Proposed Wording for LWG 2114 (contextually convertible to bool) Daniel Krügler 2022-11-02 2022-12 P2167R2 LWG Library
P2248R7 Enabling list-initialization for algorithms Giuseppe D'Angelo 2022-11-13 2022-12 P2248R6 SG6 Numerics,SG9 Ranges,LEWG Library Evolution
P2396R1 Concurrency TS 2 fixes David Goldblatt 2022-11-10 2022-12 P2396R0 LWG Library
P2434R0 Nondeterministic pointer provenance S. Davis Herring 2022-11-16 2022-12   SG22 Compatability,EWG Evolution
P2539R4 Should the output of std::print to a terminal be synchronized with the underlying stream? Victor Zverovich 2022-11-08 2022-12 P2539R3 LWG Library
P2546R3 Debugging Support René Ferdinand Rivera Morell 2022-11-15 2022-12 P2546R2 LEWG Library Evolution
P2548R2 copyable_function Michael Florian Hava 2022-11-08 2022-12 P2548R1 LEWG Library Evolution
P2548R3 copyable_function Michael Florian Hava 2022-11-11 2022-12 P2548R2 LEWG Library Evolution
P2548R4 copyable_function Michael Florian Hava 2022-11-12 2022-12 P2548R3 LEWG Library Evolution,LWG Library
P2552R1 On the ignorability of standard attributes Timur Doumler 2022-11-15 2022-12 P2552R0 EWG Evolution,CWG Core
P2559R1 Plan for Concurrency Technical Specification Version 2 Bryce Adelstein Lelbach 2022-11-16 2022-12 P2559R0 LEWG Library Evolution,LWG Library
P2564R1 consteval needs to propagate up Hal Finkel 2022-11-10 2022-12 P2564R0 EWG Evolution
P2564R2 consteval needs to propagate up Hal Finkel 2022-11-10 2022-12 P2564R1 EWG Evolution
P2564R3 consteval needs to propagate up Barry Revzin 2022-12-04 2022-12 P2564R2 CWG Core
P2570R1 Contract predicates that are not predicates Andrzej Krzemieński 2022-11-14 2022-12 P2570R0 SG21 Contracts
P2588R2 Relax std::barrier phase completion step guarantees Gonzalo Brito 2022-11-07 2022-12 P2588R1 LEWG Library Evolution
P2589R1 static operator[] Nevin Liber 2022-11-10 2022-12 P2589R0 CWG Core
P2602R2 Poison Pills are Too Toxic Barry Revzin 2022-11-07 2022-12 P2602R1 LEWG Library Evolution
P2614R2 Deprecate numeric_limits::has_denorm Matthias Kretz 2022-11-08 2022-12 P2614R1 LWG Library
P2615R1 Meaningful exports S. Davis Herring 2022-11-15 2022-12 P2615R0 EWG Evolution,CWG Core
P2616R1 Making std::atomic notification/wait operations usable in more situations Lewis Baker 2022-11-09 2022-12 P2616R0 SG1 Concurrency and Parallelism
P2616R2 Making std::atomic notification/wait operations usable in more situations Lewis Baker 2022-11-15 2022-12 P2616R1 SG1 Concurrency and Parallelism
P2640R2 Modules: Inner-scope Namespace Entities: Exported or Not? Nathan Sidwell 2022-11-15 2022-12 P2640R1 EWG Evolution
P2644R1 Final Fix of Broken Range based for Loop Rev 1 Nicolai Josuttis 2022-11-13 2022-12 P2644R0 CWG Core
P2647R1 Permitting static constexpr variables in constexpr functions Barry Revzin 2022-11-08 2022-12 P2647R0 EWG Evolution
P2649R0 2022-10 Library Evolution Poll Outcomes Bryce Adelstein Lelbach 2022-11-11 2022-12   LEWG Library Evolution
P2650R0 2022-11 Library Evolution Polls Bryce Adelstein Lelbach 2022-11-17 2022-12   LEWG Library Evolution
P2652R1 Disallow user specialization of allocator_traits Pablo Halpern 2022-11-11 2022-12 P2652R0 LWG Library
P2653R1 Update Annex E based on Unicode 15.0 UAX 31 Steve Downey 2022-10-20 2022-12 P2653R0 SG16 Unicode,CWG Core
P2655R1 common_reference_t of reference_wrapper Should Be a Reference Type Hui Xie 2022-11-11 2022-12 P2655R0 SG9 Ranges,LEWG Library Evolution
P2657R1 C++ is the next C++ Jarrad J. Waterloo 2022-11-14 2022-12 P2657R0 EWG Evolution
P2658R1 temporary storage class specifiers Jarrad J. Waterloo 2022-11-14 2022-12 P2658R0 EWG Evolution
P2659R1 A Proposal to Publish a Technical Specification for Contracts Brian Bi 2022-11-14 2022-12 P2659R0 SG21 Contracts,EWG Evolution
P2664R0 Proposal to extend std::simd with permutation API Daniel Towner 2022-10-21 2022-12   SG1 Concurrency and Parallelism,LEWG Library Evolution,LWG Library,Direction Group
P2674R1 A trait for implicit lifetime types Timur Doumler 2022-11-11 2022-12 P2674R0 CWG Core,LWG Library
P2679R1 Fixing std::start_lifetime_as and std::start_lifetime_as_array Timur Doumler 2022-11-11 2022-12 P2679R0 CWG Core,LWG Library
P2681R0 More Stats Functions Richard Dosselmann 2022-11-07 2022-12   SG6 Numerics,SG19 Machine Learning
P2693R0 Formatting thread::id and stacktrace Corentin Jabot 2022-11-11 2022-12   LEWG Library Evolution
P2695R0 A proposed plan for contracts in C++ Timur Doumler 2022-11-17 2022-12   SG21 Contracts,EWG Evolution
P2696R0 Introduce Cpp17Swappable as additional convenience requirements Daniel Krügler 2022-11-07 2022-12   LWG Library
P2697R0 Interfacing bitset with string_view Michael Florian Hava 2022-11-12 2022-12   LEWG Library Evolution
P2698R0 Unconditional termination is a serious problem Bjarne Stroustrup 2022-11-18 2022-12   SG21 Contracts
P2700R0 Questions on P2680 "Contracts for C++: Prioritizing Safety" Timur Doumler 2022-11-29 2022-12   SG21 Contracts
P2701R0 Translating Linker Input Files to Module Metadata Files Daniel Ruoso 2022-11-08 2022-12   SG15 Tooling
P2702R0 Specifying Importable Headers Daniel Ruoso 2022-11-08 2022-12   SG15 Tooling
P2703R0 C++ Standard Library Ready Issues to be moved in Kona, Nov. 2022 Jonathan Wakely 2022-11-07 2022-12   All of WG21
P2704R0 C++ Standard Library Immediate Issues to be moved in Kona, Nov. 2022 Jonathan Wakely 2022-11-20 2022-12   All of WG21
P2705R0 C++ Library Fundamentals TS Issues to be moved in Kona, Nov. 2022 Jonathan Wakely 2022-11-07 2022-12   All of WG21
P2706R0 Drafting for US 26-061: Redundant specification for defaulted functions Jason Merrill 2022-11-08 2022-12   CWG Core
P2708R0 No Future Fundamentals TSes Alisdair Meredith 2022-11-10 2022-12   LEWG Library Evolution
P2708R1 No Future Fundamentals TSes Alisdair Meredith 2022-11-10 2022-12 P2708R0 LWG Library
P2709R0 Core Language Working Group "ready" Issues for the November, 2022 meeting Jens Maurer 2022-11-11 2022-12   All of WG21
P2710R0 Core Language Working Group NB comment resolutions for the November, 2022 meeting Jens Maurer 2022-11-11 2022-12   All of WG21
P2711R0 Making multi-param (and other converting) constructors of views explicit Ville Voutilainen 2022-11-09 2022-12   LEWG Library Evolution,LWG Library
P2711R1 Making multi-param constructors of views explicit Ville Voutilainen 2022-11-11 2022-12 P2711R0 LWG Library
P2712R0 Classification of Contract-Checking Predicates Joshua Berne 2022-11-14 2022-12   SG21 Contracts
P2718R0 Wording for P2644R1 Fix for Range-based for Loop Joshua Berne 2022-11-11 2022-12   CWG Core
P2722R0 Slides: Beyond operator() (P2511R2 presentation) Zhihao Yuan 2022-11-12 2022-12   LEWG Library Evolution
P2723R0 Zero-initialize objects of automatic storage duration JF Bastien 2022-11-15 2022-12   SG12 Undefined and Unspecified Behavior,SG22 Compatability,EWG Evolution
P2725R0 std::integral_constant Literals Zach Laine 2022-11-18 2022-12   LEWGI SG18: LEWG Incubator,LEWG Library Evolution
P2726R0 Better std::tuple Indexing Zach Laine 2022-11-18 2022-12   LEWGI SG18: LEWG Incubator,LEWG Library Evolution
P2727R0 std::iterator_interface Zach Laine 2022-11-20 2022-12   LEWGI SG18: LEWG Incubator,LEWG Library Evolution

The 2023 Call for Speakers opens -- C++ on Sea

Whether you're a first-time speaker, or an old pro, we have a place for you at C++ on Sea in 2023. We'd love to hear from all parts of the community, so if you have something to say - please let us know!

The 2023 Call for Speakers opens

From the article:

The call runs until 8th January 2023. If you're reading this at the start of December that might sound like a long way off, yet - but don't be fooled! Due to time dilation caused by the end of year holiday season, it can sneak up much faster than you expect. So don't delay.

Mike Shah's Modern C++ YouTube Series -- Mike Shah

Mike Shah's Modern C++ YouTube series has recently posted the 100th video. 

The freely available YouTube series adds 1-2 videos a week on Modern C++ or other related C++ topics.

Modern C++ YouTube Series

by Mike Shah

About the videos

The series can be watched from start to finish, or otherwise as a complement to those studying C++ from a text to learn about specific C++ language features.