Skip to content

Releases: microsoft/STL

VS 2022 17.5

09 Mar 05:27
c873cf0

Choose a tag to compare

  • Merged C++23 features:
    • P2322R6 #3099 ranges::fold_left, ranges::fold_right, etc.
    • P2465R3 #3108 Standard Library Modules std And std.compat
      • Initially supported for MSVC only; see tracking issue #1694 for lists of known compiler bugs and upcoming fixes.
      • Build system support is a work in progress; currently, build systems must be manually taught to compile std.ixx so you can reference std.ifc and link std.obj. (Similarly for building std.compat.ixx into std.compat.ifc and std.compat.obj.)
      • IntelliSense support is a work in progress; STL test coverage is not yet enabled.
      • Will be supported for Clang after compiler support for modules is available; see Clang's C++20 implementation status.
    • P2508R1 #3074 basic_format_string, format_string, wformat_string
  • Merged partial C++23 features:
    • P2278R4 cbegin Should Always Return A Constant Iterator:
      • The "Iterators" section, including basic_const_iterator, make_const_iterator(), and make_const_sentinel(). #3043
    • P2321R2 zip:
      • views::zip. #3035
      • Note: views::zip_transform, views::adjacent, and views::adjacent_transform are the parts that remain to be implemented.
  • Merged LWG issue resolutions:
    • LWG-3711 #2949 Missing preconditions for slide_view constructor
    • LWG-3788 #3130 jthread::operator=(jthread&&) postconditions are unimplementable under self-assignment
  • Fixed bugs:
    • Fixed compiler warnings when using Standard Library Header Units. #3069
    • Removed a non-Standard member function locale::c_str(). #3088
    • Fixed narrowing warnings when calling piecewise_constant_distribution<float>::densities() and piecewise_linear_distribution<float>::densities(). #3107
    • Fixed compiler errors when calling ranges::is_permutation with predicates that return highly unusual boolean-testable types. #3113
    • Fixed compiler errors when building the Standard Library Modules with static RTTI disabled. #3115
      • Now, building std.ixx with /GR- /D_HAS_STATIC_RTTI=0 will succeed, and std::any will simply be unavailable (as it inherently requires static RTTI).
      • Additionally, including <any> with static RTTI disabled will emit a warning message but not an error, and the feature-test macro __cpp_lib_any will indicate (by its absence) that the feature is unavailable.
    • Fixed compiler errors in reference_wrapper, thread, and variant involving incomplete types. #3101 #3148
    • When chrono::time_zone::get_info() throws an exception, fixed it to report GetLastError() as intended, instead of "The operation completed successfully." #3122
    • Fixed incorrect results returned by ellint_2(). #3077
    • Fixed error_category's default constructor to be constexpr. #3139 #3176
    • Fixed all headers to avoid emitting the off-by-default "warning C5262: implicit fall-through occurs here; are you missing a break statement? Use [[fallthrough]] when a break statement is intentionally omitted between cases". #3162
    • Fixed compiler errors in certain <ranges> scenarios by properly constraining movable-box's copy constructors. #3171
  • Improved performance:
    • Added support for unwrapping to move_sentinel. #3098
    • Improved the performance of uniform_int_distribution by implementing Daniel Lemire's algorithm Fast Random Integer Generation in an Interval. #3012
    • Optimized gcd() to avoid a redundant shift. #3127
    • Optimized locale::classic() for a 10x speedup (times, not percent). #3048
    • Added an attribute to move(), forward(), move_if_noexcept(), and forward_like() that will allow the MSVC compiler to intrinsically implement them without emitting function calls. #3182
  • Improved throughput:
    • Significantly improved compile times for <variant> visit(). #3070
    • <format> now includes fewer headers. #3128
    • Moved random number generator machinery out of <xutility>, one of the STL's central internal headers. #3157
  • Enhanced behavior:
    • Clarified get_future()'s [[nodiscard("message")]]. #3068
    • The internal headers <xatomic.h>, <xbit_ops.h>, and <xerrc.h> are now core headers. #3116
    • Improved <format>'s compiler error messages for unformattable types. #3080
  • Improved test coverage:
    • Added test coverage for <variant> visit() invoking pointers to members. #3070
    • Expanded test coverage for forward_like(). #3072
    • Updated test coverage for views::as_rvalue. #3089
    • Expanded test coverage for bind_front() and bind_back(). #3117
    • Updated our LLVM submodule reference, including new tests, and updates to the any/optional/variant shared test code. #2976
    • Fixed bogus test code discovered by Clang 15. #3135
    • Fixed the off-by-default "exhaustive" mode of the parallel is_partitioned() test. #3174
  • Code cleanups:
    • Various cleanups (described in detail in the PRs, not repeated here). #3082 #3083 #3084 #3085 #3086 #3090 #3091 #3092 #3093 #3177 #3178
    • Improved Python scripts. #3123
    • Removed compiler bug workarounds. #3155
    • Moved <atomic> implementation details, preparing for later changes. #3124
    • Removed unnecessary partial specializations of common_type for the STL's internal 128-bit integer-class types. #3153
  • Infrastructure improvements:
    • The PR/CI system now uses spot VMs again. #3071
    • Configured Azure Pipelines to avoid running checks for draft PRs. #3078
    • Added GitHub Actions to allow contributors to move their PR cards in the Code Reviews project. #2584
    • Updated dependencies. #3104 #3155
      • Updated build compiler to VS 2022 17.4 Preview 3.
      • Updated Boost.Math to 1.80.0 (now also used by the MSVC-internal build). #3077
      • Updated Clang to 15.0.1 (now required).
      • Updated CMake to 3.24 (now required).
      • Updated Google Benchmark to 1.7.0. #3151
      • Updated Python to 3.10.8.
  • Updated _MSVC_STL_UPDATE. #3073 #3147

VS 2022 17.4

09 Mar 05:26
af8adfa

Choose a tag to compare

  • Merged C++23 features:
  • Merged LWG issue resolutions:
    • LWG-3564 #2961 transform_view::iterator<true>::value_type and iterator_category should use const F&
    • LWG-3617 #2966 function/packaged_task deduction guides and deducing this
    • LWG-3656 #2880 Inconsistent bit operations returning a count
    • LWG-3671 #2905 atomic_fetch_xor missing from stdatomic.h
    • LWG-3672 #2907 common_iterator::operator->() should return by value
    • LWG-3683 #2879 operator== for polymorphic_allocator cannot deduce template argument in common cases
    • LWG-3701 #2957 Make formatter<remove_cvref_t<const charT[N]>, charT> requirement explicit
    • LWG-3707 #2883 chunk_view::outer-iterator::value_type::size should return unsigned type
    • LWG-3710 #2878 The end of chunk_view for input ranges can be const
    • LWG-3712 #2943 chunk_view and slide_view should not be default_initializable
    • LWG-3715 #2946 view_interface::empty is overconstrained
    • LWG-3719 #2902 Directory iterators should be usable with default sentinel
    • LWG-3721 #2906 Allow an arg-id with a value of zero for width in std-format-spec
    • LWG-3724 #2903 decay-copy should be constrained
  • Merged proposed resolutions for LWG issues (not yet accepted for the C++ Working Draft, but we've chosen to implement this speculatively):
    • LWG-3705 #2741 Hashability shouldn't depend on basic_string's allocator
  • Fixed bugs:
    • Fixed linker errors when using <any> with our unofficially supported mode to disable exceptions. #2193
    • Fixed compiler errors when using <format> with the new compiler option /presetPadding by adding a compiler bug workaround. #2746
    • Fixed division by complex zero to behave consistently with other implementations. #2758
    • Fixed a memory leak in <syncstream>. #2763
    • Fixed compiler errors when formatting long or unsigned long values with formatter. #2768
    • Fixed a binary compatibility break in the unordered associative containers, which could cause memory corruption when linking code that was built with different versions of the STL. #2774
      • Original Versions: VS 2015 through VS 2019 16.2 inclusive.
      • Modified Versions: VS 2019 16.3 through VS 2022 17.3 inclusive.
      • Fixed Versions: VS 2022 17.4 and later.
      • The bincompat break happened when mixing Original with Modified code. All other mixing is safe: Original with Original, Modified with Modified, Fixed with Fixed, Original with Fixed, and Modified with Fixed.
    • Fixed a bug in the unordered associative containers, specific to user-defined allocators, where the containers sometimes called deallocate() with null pointers. User-defined allocators aren't required to tolerate that, so the containers now avoid such calls. #2790
    • Fixed a bug in deque, specific to rarely-used fancy pointers, where some fancy pointers weren't being destroyed. #2775
    • <chrono> formatting now accepts %x ("The locale's date representation") for year_month_day, year_month_day_last, year_month_weekday, and year_month_weekday_last. #2762
    • std::filesystem::directory_entry's constructors, assign(), and replace_filename() now call refresh() as required by the Standard and will propagate any errors (via exceptions or error_codes), except that "file not found" is not considered an error. #1343
    • Added a compiler bug workaround to construct_at(), allowing immovable objects to be emplaced via copy elision. #2624
    • Fixed leap second validation when parsing time_points. #2705
    • lerp() now avoids overflowing to infinity when it can calculate the correct result with a fallback approach. #1918
    • Fixed a debugger visualization issue, specific to Clang in C++20 mode (or later), where the debugger wouldn't display the contents of a list, forward_list, or ordered/unordered associative container. #2782
    • Fixed the visualizers for the non-Standard stdext::hash_map container family. #2784
    • Fixed the visualizers for make_shared() and allocate_shared(). #2811
    • put_time() (and the time_put::do_put() machinery powering it) now avoids modifying errno when it succeeds. #2049
    • Added a compiler bug workaround to fix compiler errors with source_location::current() in certain scenarios. #2824
    • Fixed compiler errors when using <format> to print durations with extremely small periods (e.g. femtoseconds, attoseconds). #2814
    • Fixed "istreambuf_iterator is not dereferenceable" assertions when attempting to use time_get::get() or get_time() to parse certain formats when there's insufficient input. #2851
      • For example, with the format "%X", the input "3:04:05" succeeds. The input "3:04" previously asserted/crashed; now it sets ios_base::failbit | ios_base::eofbit as required by the Standard.
    • ...
Read more

VS 2022 17.3

09 Mar 05:26
60decd0

Choose a tag to compare

  • Merged C++23 features:
  • Merged partial C++23 features:
    • P2321R2 zip:
      • Changes to tuple, pair, and vector<bool>::reference. #2687
  • Merged LWG issue resolutions:
    • LWG-3121 #2640 tuple constructor constraints for UTypes&&... overloads
    • LWG-3525 #2639 uses_allocator_construction_args fails to handle types convertible to pair
    • LWG-3570 #2418 basic_osyncstream::emit should be an unformatted output function
    • LWG-3571 #2418 flush_emit should set badbit if the emit call fails
  • Merged proposed resolutions for LWG issues (not yet accepted for the C++ Working Draft, but we've chosen to implement this speculatively):
    • LWG-3234 #2703 Sufficient Additional Special Math Overloads
    • LWG-3627 #2607 Inconsistent specifications for std::make_optional overloads
  • Fixed bugs:
    • Fixed vector<bool> to properly invalidate iterators during reallocation, which fixes compiler errors with constexpr usage of vector<bool>. #2441
    • empty_view rvalues are now considered borrowed_ranges as required by the Standard. #2576
    • Added compiler bug workarounds to is_convertible and common_reference, so contiguous_iterator<const volatile int*> is now true. #2592
    • Added missing constraints to functions that were implied by "Effects: Equivalent to" Standardese: make_any(), make_optional(), shared_ptr::operator=(), shared_ptr::reset(), and weak_ptr::operator=().
    • Fixed filesystem::path's comparison operators and some other member functions being IF-NDR (ill-formed, no diagnostic required) in C++23 mode. #2457
      • This fixed a regression that was introduced by #2000 implementing P1989R2 Range Constructor For string_view in VS 2022 17.0.
    • Fixed C++20 <chrono> parsing to fail when the input is insufficient to supply the entire format string. #2523
      • For example, the input "23:59" is insufficient for the format string "%H:%M:%S".
    • Fixed an out-of-bounds read in ranges::find() with unreachable_sentinel. #2434
    • Added compiler bug workarounds for CUDA (involving [[nodiscard]] friend) to fix spurious cases of "warning C5240: 'nodiscard': attribute is ignored in this syntactic position". #2622
    • Removed ExecutionPolicy overloads of copy_backward() and move_backward() that were mistakenly implemented. They don't appear in the Standard because they would be useless. #2627
    • Added compiler bug workarounds for Clang (involving the ordering of constrained and unconstrained destructors) to fix compiler errors in <ranges> machinery. #2630
    • Fixed a bug affecting <future>'s use of <ppltasks.h> in Desktop XAML apps. #2654
    • Fixed a bug that prevented C++20 <chrono> from parsing fractional seconds as floating-point durations. #2638
    • Fixed <bit>'s countl_zero() returning incorrect results on ARM64 for 8-bit and 16-bit types. #2647
    • Added macroization guards to the STL's usage of compiler-specific custom attributes. #2649
    • Fixed get_time() and time_get's 2-digit year logic. #2666
    • Fixed system_category().message() to behave correctly instead of returning "???" when the user language and system language are different. #2669
    • Fixed the ARM64EC implementations of atomic_thread_fence() and atomic<8-byte type>::store(). #2702
    • Fixed compiler errors in atomic<shared_ptr<T[]>>, atomic<shared_ptr<T[N]>>, atomic<weak_ptr<T[]>>, and atomic<weak_ptr<T[N]>>. #1339
    • Added overloads of <cmath>'s lerp() for arithmetic types. #2113
    • Fixed filesystem::directory_entry to work with FAT32 and exFAT. #2373
    • <filesystem> now handles special system files like hiberfil.sys. #2715
    • filesystem::copy_file() now tolerates other processes having opened the source file or the target file for reading or writing (as much as possible, depending on the choice of copy_options). #2718
    • Fixed the visualizers for shared_ptr<void>, weak_ptr<void>, and unique_ptr<void, Deleter>. #2706
    • Fixed compiler errors in move_only_function when compiling <functional> in /std:c++latest mode with /Zc:alignedNew-. #2712
    • Implemented C++20's removal of the explicit specialization for allocator<void>. #2726
      • Note that allocator<void> is still supported, it just uses the primary template now.
    • Fixed "unresolved external symbol" linker errors in certain scenarios involving separately compiled third-party libraries. #2734 #2738
      • On x64, these errors mentioned __imp___std_init_once_begin_initialize and __imp___std_init_once_complete.
      • On x86, these errors mentioned __imp____std_init_once_begin_initialize@16 and __imp____std_init_once_complete@12.
      • This fixed a regression that was introduced by #2381 in VS 2022 17.2.
      • This fix was backported to VS 2022 17.2.5.
  • Improved performance:
    • Optimized rotl() and rotr() in <bit> for 8-bit and 16-bit integers by using compiler intrinsics. #2611
    • Optimized the vectorized implementation of reverse() for 32-bit trivial types. #2383
    • Improved <format> performance when the execution character set isn't self-synchronizing, by caching expensive calls to get codepage info. #2600
    • Added vectorized implementations of find(), count(), ranges::find(), and ranges::count(), with speedups ranging from 2.0x to 27.6x (times, not percent). #2434
    • Slightly improved the performance of <charconv> floating-point from_chars(). #2623
  • Improved throughput:
    • Used if constexpr instead of tag dispatch, overloads, or specializations in:
      • is_permutation(), sample(), rethrow_if_nested(), and default_searcher. #2219
      • <map> and <set>'s common machinery. #2287
      • polymorphic_allocator. #2471
      • basic_string_view and basic_string's find_first_of(), find_last_of(), find_first_not_of(), and find_last_not_of(). #2479 #2660
      • <regex>. #2484
      • Parallel inclusive_scan() and transform_inclusive_scan(). #2662
      • scoped_allocator_adaptor's operator==(). #2677
      • function, move_only_function, and bind(). #2668
      • vector<bool>::insert(). #2694
    • Replaced tag dispatch with SFINAE in subtract_with_carry_engine's internal machinery. #2693
    • Split <chrono> into a smaller internal header, improving throughput when other headers need only pre-C++20 <chrono> machinery. #2604
  • Enhanced behavior:
    • Changed <deque> to use scope guards instead of `thro...
Read more

VS 2022 17.2

09 Mar 05:25
4bb41db

Choose a tag to compare

  • Merged C++20 Defect Reports:
    • P2216R3 #2221 std::format Improvements
    • P2418R2 #2323 Add Support For std::generator-like Types To std::format
    • With a final bit of work to implement an integer-class type (per P1522R1) for iota_view, declare <ranges> and <format> stable and make them fully available under /std:c++20. #2518
  • Merged C++23 features:
  • Merged LWG issue resolutions:
    • LWG-2762 #2376 unique_ptr operator*() should be noexcept
    • LWG-2774 #2098 std::function construction vs assignment
    • LWG-3146 #2409 Excessive unwrapping in std::ref/cref
    • LWG-3392 #2421 ranges::distance() cannot be used on a move-only iterator with a sized sentinel
    • LWG-3470 #2414 convertible-to-non-slicing seems to reject valid case
    • LWG-3471 #2567 polymorphic_allocator::allocate does not satisfy Cpp17Allocator requirements
    • LWG-3480 #2340 directory_iterator and recursive_directory_iterator are not C++20 ranges
    • LWG-3519 #2208 Incomplete synopses for <random> classes
    • LWG-3543 #2424 Definition of when counted_iterators refer to the same sequence isn't quite right
    • LWG-3557 #2406 The static_cast expression in convertible_to has the wrong operand
    • LWG-3563 #2426 keys_view example is broken
    • LWG-3574 #2410 common_iterator should be completely constexpr-able
    • LWG-3580 #2417 iota_view's iterator's binary operator+ should be improved
    • LWG-3589 #2425 The const lvalue reference overload of get for subrange does not constrain I to be copyable when N == 0
    • LWG-3590 #2404 split_view::base() const & is overconstrained
    • LWG-3591 #2411 lazy_split_view<input_view>::inner-iterator::base() && invalidates outer iterators
    • LWG-3592 #2411 lazy_split_view needs to check the simpleness of Pattern
    • LWG-3593 #2448 Several iterators' base() const & and lazy_split_view::outer-iterator::value_type::end() missing noexcept
    • LWG-3595 #2410 Exposition-only classes proxy and postfix-proxy for common_iterator should be fully constexpr
    • LWG-3598 #2560 system_category().default_error_condition(0) is underspecified
    • LWG-3610 #2542 iota_view::size sometimes rejects integer-class types
    • LWG-3612 #2586 Inconsistent pointer alignment in std::format
    • LWG-3618 #2566 Unnecessary iter_move for transform_view::iterator
    • LWG-3621 #2543 Remove feature-test macro __cpp_lib_monadic_optional
    • LWG-3648 #2587 format should not print bool with 'c'
    • LWG-3654 #2528 basic_format_context::arg(size_t) should be noexcept
    • LWG-3657 #2564 std::hash<std::filesystem::path> is not enabled
    • LWG-3660 #2549 iterator_traits<common_iterator>::pointer should conform to [iterator.traits]
    • LWG-3661 #2544 constinit atomic<shared_ptr<T>> a(nullptr); should work
  • Merged proposed resolutions for LWG issues (not yet accepted for the C++ Working Draft, but we've chosen to implement this speculatively):
  • Fixed bugs:
    • Fixed Clang compiler errors when using ranges::join_view. #2352
    • Fixed several runtime correctness bugs in std::string. #2305
    • Fixed a memory leak affecting a specific scenario in P0408R7 Efficient Access To basic_stringbuf's Buffer. #2361
    • Each call to ranges::clamp now correctly performs at most three projections. #1898
    • The STL no longer rejects Clang in CUDA mode, nor the cl /showIncludes /D__CUDACC__ ... command used by CUDA's msbuild integration to gather dependencies. #2075
    • Fixed allocator::is_always_equal to be deprecated, not removed, in C++20 mode. (It was deprecated by LWG-3170.) #2423
    • Fixed begin()/end() crashing for empty valarrays, which also affected range-based for-loops. #2435
    • Fixed regression in ranges::distance (from LWG-3392 which broke ranges::distance(some_array, s)) by speculatively implementing LWG-3664. #2522
    • Fixed basic_string::resize_and_overwrite() to no longer emit "warning C4018: signed/unsigned mismatch" when given certain user-defined function objects. #2525
    • Increased __cpp_lib_concepts to its final value for C++20, 202002L. #2559
      • It should have been updated in VS 2019 16.6 when P1964R2 "Replacing boolean With boolean-testable" was implemented by #565. The presence of that release (or any later release) can be detected by inspecting our implementation-specific macro _MSVC_STL_UPDATE. Coincidentally, the value of _MSVC_STL_UPDATE for VS 2019 16.6 was also 202002L.
    • Fixed numerous tiny bugs discovered by the libcxx test suite. #2499
    • Fixed a bug in <format> that sporadically caused incorrect output when formatting floating-point values in hex or scientific notation with extremely large precisions. #2569
    • Fixed a bug in <charconv> from_chars() float tiebreaking that produced incorrect results. This affected decimal strings that were at the exact midpoint of consecutive float values, within a narrow range (the smallest and largest affected values were "32768.009765625" and "131071.98828125"), where the tiebreaker rule wanted to round to "even" and "even" happened to be "down", but the implementation incorrectly rounded "up". (double was unaffected.) #2366
    • promise<T> now compiles when !is_default_constructible_v<T>. #2568
    • Moving from an optional<const T> now behaves like moving from a const T: it selects T's copy constructor. #2460
    • Fixed a bug in <format> that incorrectly accepted volatile arguments; the Standard currently says that they should be rejected. #2579
  • Improved performance:
    • Optimized rotl() and rotr() in <bit> for 32-bit and 64-bit integers by using compiler intrinsics. [#2369](https:...
Read more

VS 2022 17.1

09 Mar 05:24
3c2fd04

Choose a tag to compare

  • Merged C++20 Defect Reports:
  • Merged C++23 features:
  • Merged LWG issue resolutions:
    • P2259R1 #2059 Repairing Input Range Adaptors And counted_iterator
      • Completed by implementing the input range adaptors part.
    • LWG-3422 #2260 Issues of seed_seq's constructors
    • LWG-3506 #1994 Missing allocator-extended constructors for priority_queue
    • LWG-3520 #2200 iter_move and iter_swap are inconsistent for transform_view::iterator
    • LWG-3522 #1994 Missing requirement on InputIterator template parameter for priority_queue constructors
    • LWG-3527 #2194 uses_allocator_construction_args handles rvalue pairs of rvalue references incorrectly
    • LWG-3528 #2160 make_from_tuple can perform (the equivalent of) a C-style cast
    • LWG-3536 #2037 Should chrono::from_stream() assign zero to duration for failure?
    • LWG-3546 #1991 common_iterator's postfix-proxy is not quite right
    • LWG-3549 #2198 view_interface is overspecified to derive from view_base
    • LWG-3554 #2261 chrono::parse needs const charT* overloads
  • Fixed bugs:
    • Fixed <complex> exp() and polar() for infinity and NaN inputs. #1584
    • Fixed compiler errors when comparing common_iterators of different types for equality. #2066
    • Attempting to actually call declval() now emits a static_assert citing the paragraph of the Standard that forbids this. (Previously, declval() was declared but not defined, which was too permissive.) #2101
    • Fixed basic_streambuf::seekoff() and basic_streambuf::seekpos() to work with custom pos_types. #2121
    • Restored our guarantee beyond the Standard that string_view is trivially move constructible. #2128
      • This fixed a regression that was introduced by #2000 implementing P1989R2 Range Constructor For string_view in VS 2022 17.0.
    • Fixed a bug where vector and string would terminate via noexcept instead of throwing length_error as desired when a size_t would be truncated to an allocator's narrower size_type. #2139
    • <istream> and <ostream> now properly catch and rethrow internal IO exceptions. #2033
    • Fixed <format> to correctly print hexfloats with large precisions. #2157
    • Fixed compiler errors when using constexpr vectors with certain user-defined allocators. #2161
    • Fixed silent bad codegen in ranges::stable_sort(), where for certain inputs it would neither sort nor permute the range. ranges::inplace_merge() was also affected. #2188
    • subtract_with_carry_engine's textual representation is now correct. #2088
    • Fixed a deadlock in the overload of condition_variable_any::wait_until taking stop_token. #2220
    • u8streampos, u16streampos, and u32streampos are now declared by <iosfwd> as required by the Standard after P0482R6 and P1148R0 were accepted. #2223
    • Fixed ARM64EC compiler errors in <limits>. #2306
    • Fixed heap corruption in fstream when calling putback() followed by close(). #2189
    • Fixed views::reverse to work properly with ranges::reverse_view lvalues. #2313
    • Fixed a bug where the STL's DLL was using Windows Vista's APIs for critical sections and condition variables, instead of the more efficient APIs that were introduced in Windows 7. This was specific to /MD (dynamic release) and the STL's GitHub CMake build system; it did not affect the legacy build system that's currently used for official builds of the MSVC toolset. #2314
    • Fixed a bug affecting older CPUs where the STL generated the newer tzcnt instruction instead of the fallback bsf instruction. This affected <bit>'s countr_zero() and countr_one(), <numeric>'s gcd() and lcm(), and vector<bool>'s optimized implementations of find() and relational/spaceship operators. #2333
    • Fixed minor conformance issues in basic_string. These changes were specified by P1148R0 "Cleaning Up [strings]", which was almost a pure rewording paper without normative impact. Oops! #2222
    • Fixed ranges::find_end() to return correct values for bidirectional common ranges. #2270
    • Fixed compiler errors affecting ranges::sort(), ranges::search(), and other ranges machinery. #2290
    • Fixed array<T, 0>, allowing it to compile when T is not default constructible. #2296
    • Fixed allocator::allocate_at_least() which was improperly annotated with __declspec(allocator). #2328
  • Improved performance:
    • Optimized steady_clock::now() when QueryPerformanceFrequency() is exactly 10 MHz, which is very common for modern PCs. #2086
    • Improved codegen for x86 atomic loads. #2110
    • Optimized the fallback implementation of popcount(), which is used when compiler intrinsics are unavailable (and is also used at compile time). #2079
    • Slightly improved codegen when <format> prints a pointer in hexadecimal. #2097
    • Optimized <ranges> non-propagating-cache for trivially destructible types. #2118
    • Improved ARM64 codegen for popcount(), using compiler intrinsics. #2127
    • Extended the memcpy(), `...
Read more

VS 2022 17.0

09 Mar 05:24
a9321cf

Choose a tag to compare

  • Merged C++20 Defect Reports:
    • P2325R3 #2012 Views Should Not Be Required To Be Default Constructible
    • P2328R1 #2038 join_view Should Join All views Of ranges
    • P2367R0 #2026 Remove Misuses Of List-Initialization From Clause 24 Ranges
  • Enabled C++20 features for Clang: #2064
  • Merged C++23 features:
    • P0401R6 #2036 Providing Size Feedback In The Allocator Interface
    • P1048R1 #1950 is_scoped_enum
    • P1132R7 #1998 out_ptr(), inout_ptr()
    • P1679R3 #1478 contains() For basic_string/basic_string_view
    • P1682R3 #1828 to_underlying() For Enumerations
    • P1951R1 #2009 Default Template Arguments For pair's Forwarding Constructor
    • P1989R2 #2000 Range Constructor For string_view
    • P2162R2 #2006 Inheriting From variant
    • P2166R1 #1995 Prohibiting basic_string And basic_string_view Construction From nullptr
      • This is a common source-breaking change - code that previously had undefined behavior at runtime will now be rejected with compiler errors.
    • P2186R2 #2010 Removing Garbage Collection Support
  • Merged LWG issue resolutions:
    • LWG-3430 #1968 std::fstream & co. should be constructible from string_view
    • LWG-3494 #1877 Allow ranges to be conditionally borrowed
    • LWG-3502 #1878 elements_view should not be allowed to return dangling references
    • LWG-3518 #2080 Exception requirements on char trait operations unclear
    • LWG-3533 #1993 Make base() const & consistent across iterator wrappers that support input_iterators
    • LWG-3541 #1992 indirectly_readable_traits should be SFINAE-friendly for all types
    • LWG-3548 #2007 shared_ptr construction from unique_ptr should move (not copy) the deleter
    • LWG-3553 #1990 Useless constraint in split_view::outer-iterator::value_type::begin()
    • LWG-3555 #1989 {transform,elements}_view::iterator::iterator_concept should consider const-qualification of the underlying range
  • Merged partial LWG issue resolutions:
    • P2259R1 #1939 Repairing Input Range Adaptors And counted_iterator
      • The counted_iterator part is implemented; the input range adaptors part is not yet implemented.
  • Fixed bugs:
    • Fixed time_put::do_put to avoid crashing when the invalid parameter handler has been changed to not end execution. #1563
    • Fixed a compiler error in ranges::take_view. #1844
    • Fixed improper partitioning of forward ranges in the parallel algorithms. #1753
    • Fixed an unintentionally dllexported symbol in the import library. #1927
    • Fixed a bug in which ranges::unique_copy would fail to compile with a non-input output iterator. #1933
    • Fixed a compiler error when calling format_to() in a specialization of formatter (see #1961 for an example). #1874
    • Fixed compiler errors when calling views::drop and views::take with types that aren't integers, but are convertible to integers (e.g. integral_constant). #1958
    • Fixed a compiler error when calling constexpr vector::emplace(position, args...). #1962
    • Fixed jthread to provide native_handle(). #1966
    • Fixed filesystem::remove() to delete read-only files, as required by the Standard. #1559
    • Fixed mersenne_twister_engine: #1631
      • Fixed the seeding algorithm to follow N4892 [rand.eng.mers]/8, avoiding an all-zero state. (This is a runtime special case.)
      • Fixed the engine's behavior when m == n or n == 1. (This is a compile-time special case, which doesn't affect mt19937 and mt19937_64 at all.)
      • Fixed operator<<() to avoid printing a trailing space after the engine's textual representation.
    • Fixed <chrono> to adjust for leap seconds when formatting file_time. #1879
    • Fixed chrono::from_stream() to allow a year and a day-of-year to be parsed to a time_point. #1940
    • Fixed filesystem::u8path() to accept char8_t sources. #1943
    • Fixed <chrono> to parse subseconds for time_points. #1987
      • Also fixed the parsing of local_time with a UTC offset.
    • Fixed <chrono> formatting to correctly estimate string widths (see N4892 [format.string.std]/9). #2017
    • Fixed a major regression in the _ITERATOR_DEBUG_LEVEL == 2 machinery, where a multithreaded program in debug mode could crash when one thread is modifying a container and another thread is destroying iterators. #2060
      • This regression affected all Standard modes (C++14/17/20/23) and was introduced by #1546 in VS 2019 16.10.
      • Fixed in both VS 2019 16.11.4 and VS 2022 17.0.
    • Fixed a compiler error in pmr::map<K, pair<A, B>>::operator[]. #2023
    • Fixed compiler errors in basic_string's getline() and operator>>() caused by the source-breaking change C++23 P2266R1 "Simpler Implicit Move", first implemented in Clang 13. #2025
    • bit_ceil() now enforces its precondition during constexpr evaluation, as required by the Standard. #2041
    • clog is no longer tied to cout, and similarly for wclog and wcout, following the Standard. #2056
    • In <ranges>, when filter_view, drop_view, drop_while_view, and reverse_view store a cached position into an underlying view, they now properly invalidate that cached position when the underlying view is moved from. #1931
  • Improved performance:
    • Slightly improved debug codegen for vector<bool>, basic_string, and map/multimap/set/multiset's empty() member functions. #1836
    • Fixed bloated codegen for <format>. #1874
    • Dramatically improved the performance of std::find() and std::count() for vector<bool>, with measured speedups between 19x and 26x (times, not percent). #1131
    • Extended our memcmp/memcpy/memchr optimizations to ranges with contiguous iterators and unreachable sentinels. #1810
    • <format> now detects when it's writing to a back_insert_iterator for a basic_string or a vector, and performs a faster call to insert() at the end() of the container. #1894
    • std::byte now activates the "trivially swappable" optimization in reverse() and variant::swap(), so it'll have the same performance as unsigned char. #2044
    • Extended the vectorization optimization in std::swap_ranges() to ranges::swap_ranges(), and enhanced it to work for arbitrary contiguous iterators. #2048
    • Reduced debug codegen size; an internal assertion macro was emitting completely unused, potentially long strings for function names. #2054
  • Improved throughput:
    • <format> and <chrono> now avoid including `<arr...
Read more

VS 2019 16.9

09 Mar 05:21
e604b6c

Choose a tag to compare

  • Merged C++20 features:
    • P0339R6 #1311 polymorphic_allocator<>
    • P0660R10 #1196 <stop_token> And jthread
    • P0768R1 #1370 Library Support For The Spaceship Comparison Operator <=>
      • This feature was mostly implemented in VS 2019 16.0; it's now complete with the addition of the spaceship customization point objects strong_order, weak_order, partial_order, compare_strong_order_fallback, compare_weak_order_fallback, and compare_partial_order_fallback.
    • P1007R3 #1306 assume_aligned()
    • P1020R1 #1315 Smart Pointer Creation With Default Initialization
    • P1771R1 #1495 #1514 [[nodiscard]] For Constructors
  • Merged partial C++20 features:
    • P0355R7 <chrono> Calendars And Time Zones:
      • #1341 operator<<(basic_ostream&, const duration&)
    • P0896R4 Ranges:
      • #1092 #1265 #1268 common_iterator
      • #1271 views::take and views::drop now handle basic_string_view as specified in P1739R4.
      • #1313 ranges::construct_at and ranges::destroy_at
      • #1164 algorithms ranges::uninitialized_default_construct, ranges::uninitialized_default_construct_n, ranges::uninitialized_value_construct, ranges::uninitialized_value_construct_n, ranges::uninitialized_fill, ranges::uninitialized_fill_n, ranges::uninitialized_copy, ranges::uninitialized_copy_n, ranges::uninitialized_move_n
      • #1281 Changes to the stream iterators (istream_iterator, ostream_iterator, istreambuf_iterator, and ostreambuf_iterator) to model the C++20 iterator concepts
      • #1366 view ranges::drop_while_view
      • #1406 view ranges::elements_view
      • #1334 view ranges::istream_view
      • #1372 view ranges::take_while_view
      • #1305 views::common
      • #1375 views::counted
    • P1502R1 Standard Library Header Units:
      • #1388 #1396 Added test coverage. This found blocking compiler bugs that are being fixed; see #1694 for their current status.
  • Merged LWG issue resolutions:
    • LWG-3036 #1455 polymorphic_allocator::destroy is extraneous
    • LWG-3117 #1493 Missing packaged_task deduction guides
    • LWG-3170 #1501 is_always_equal added to std::allocator makes the standard library treat derived types as always equal
    • LWG-3211 #1460 std::tuple<> should be trivially constructible
    • LWG-3448 #1458 transform_view's sentinel<false> not comparable with iterator<true>
    • LWG-3460 #1452 Unimplementable noop_coroutine_handle guarantees
    • LWG-3464 #1483 istream::gcount() can overflow
  • Fixed bugs:
    • Fixed the invocable_r family of type traits to handle C++17 deferred temporary materialization. #1282
    • Fixed a compiler error in atomic_ref<[u]int8_t>::operator--(int). #1303
    • Removed non-Standard implicitly converting constructors from complex. #1294
    • Enabled constexpr destruction of memory_resource. #1314
    • std::filesystem::create_directories() now throws an exception (or fails with an error_code) when called with an empty path. #1285
    • Fixed compiler errors (with clang-tidy and IntelliSense-in-Clang-mode) caused by intrin0.h including intrin.h, which no longer happens. #1300
    • Fixed undefined behavior and incorrect results in geometric_distribution, poisson_distribution, binomial_distribution, and gamma_distribution. #1159
    • Fixed incorrect results (infinity and NaN) in normal_distribution, lognormal_distribution, fisher_f_distribution, and student_t_distribution. #1228
    • Fixed bind_front() to determine its return type from the decayed types of its arguments. #1293
    • Fixed pow(complex, arithmetic) to strictly follow the Standard's rules and return correct results. #1299
    • Fixed _Node_handle - the internal class template that reifies the Standard's node-handle family of exposition-only types - to destroy contained values with an allocator rebound to the value type instead of to the type of the node. #1310
    • Fixed overflow when converting extreme relative times (like duration::max()) to absolute times in condition_variable_any::wait_for(), condition_variable::wait_for(), recursive_timed_mutex::try_lock_for(), shared_timed_mutex::try_lock_for(), shared_timed_mutex::try_lock_shared_for(), this_thread::sleep_for(), and timed_mutex::try_lock_for(). #1371
    • Fixed a compiler error when compiling <experimental/generator> in /kernel mode. #1373
    • Fixed std::atomic_init; C++20 deprecated it (which we previously implemented) and changed its effects to be equivalent to a relaxed store (which we previously missed). #1090
    • Fixed get_time() to correctly handle format specifications without delimiters; for example, "20201029" can now be parsed with "%Y%m%d". #1280
      • This fix was incomplete; it was completed by #1620 in VS 2019 16.10.
    • Fixed the ordered associative containers (map, multimap, set, multiset) so that their move constructors and move assignment operators don't attempt to swap their comparators (which could fail to compile, especially for lambdas which aren't assignable). #1357
    • Fixed a crash when a user-defined class, deriving from streambuf, threw an exception from its constructor. #1358
    • Fixed two lines in ranges machinery that mistakenly said noexcept(noexcept(is_nothrow_v)) (which is always noexcept(true)). Now they say noexcept(is_nothrow_v) as intended. #1417
    • Marked hash<coroutine_handle<>>::operator() as const, required by the Standard. #1423
    • Fixed several issues in complex sqrt() and log(): #935
      • Fixed sqrt() overflow for huge inputs.
      • Fixed sqrt() inaccuracy for tiny inputs, due to internal underflow.
      • Fixed log() inaccuracy for tiny inputs, due to internal underflow.
      • Improved accuracy of log() when |z| ~= 1.
      • Fixed log(complex<float>{1, 0}) for certain combinations of compile-time and run-time settings; now it correctly returns 0.
      • These correctness fixes have a moderate performance cost, partially mitigated by using hardware FMA when available on x86/x64/arm64.
    • Fixed an AddressSanitizer new-delete-type-mismatch issue in valarray. #1496
    • Fixed linker errors on ARM and ARM64 when using atomic waits. #1507
    • Fixed the exception specification for basic_string_view's (iterator, sentinel) constructor. #1510
    • Fixed regex_traits::transform() to accept arbitrary forward iterators instead of requiring raw pointers. #1494
    • Fixed a static_assert that was preventing atomic_ref<const T> from compiling. #1500
    • Fixed a compiler error when compiling <atomic> in C++20 mode with Clang targeting ARM64. #1509
  • Improved performance:
    • Removed unused code for Windows XP (and Server 2003) support, slightly improving runtime performance and decreasing...
Read more

VS 2019 16.8

09 Mar 05:20
be0441c

Choose a tag to compare

  • Merged C++20 features:
    • P0019R8 #843 atomic_ref
    • P0528R3 #1029 Atomic Compare-And-Exchange With Padding Bits (for MSVC; Clang support is pending compiler intrinsics, see LLVM-46685)
    • Completed P0553R4 and P0556R3 #795 by adding MSVC support for the functions in <bit> that were previously only supported when compiling with Clang (bit_ceil, bit_floor, bit_width, countl_one, countl_zero, countr_one, countr_zero, has_single_bit, popcount, rotl, and rotr).
    • Completed P0811R3 #1048 midpoint(), lerp() by adding constexpr support and improving handling of infinite arguments.
    • P0912R5 #894 #961 #1204 Library Support For Coroutines
    • P1001R2 #1111 execution::unseq
    • P1032R1 #491 #861 Miscellaneous constexpr
    • P1065R2 #703 constexpr INVOKE
    • Completed P1135R6 The C++20 Synchronization Library:
      • This feature adds a new satellite DLL "atomic_wait".
      • #593 #1143 #1179 std::atomic::wait
      • P1644R0 #1136 Adding wait/notify To atomic<shared_ptr<T>>, atomic<weak_ptr<T>>
      • #1057 <barrier>, <latch>, and <semaphore>
  • Merged partial C++20 features:
    • P0896R4 Ranges:
      • #888 algorithm ranges::move
      • #892 algorithm ranges::is_permutation
      • #896 algorithm ranges::search
      • #904 algorithms ranges::fill and ranges::fill_n
      • #905 algorithms ranges::generate and ranges::generate_n
      • #914 algorithm ranges::search_n
      • #915 algorithms ranges::is_sorted and ranges::is_sorted_until
      • #916 algorithms ranges::min, ranges::max, ranges::minmax, ranges::clamp, ranges::min_element, ranges::max_element, and ranges::minmax_element
      • #917 algorithms ranges::lower_bound, ranges::upper_bound, ranges::equal_range, and ranges::binary_search
      • #918 algorithm ranges::swap_ranges
      • #925 concepts std::permutable and std::sortable
      • #930 algorithms ranges::is_heap, ranges::is_heap_until, ranges::make_heap, ranges::push_heap, ranges::pop_heap, and ranges::sort_heap
      • #941 algorithm ranges::transform
      • #976 algorithms ranges::is_partitioned, ranges::partition, ranges::partition_copy, and ranges::partition_point
      • #983 algorithms ranges::replace, ranges::replace_copy, and ranges::replace_copy_if
      • #984 algorithm ranges::replace_if
      • #1005 algorithms ranges::remove, ranges::remove_if, ranges::remove_copy, and ranges::remove_copy_if
      • #1026 algorithm ranges::copy_backward
      • #1028 algorithm ranges::reverse (vectorized like std::reverse)
      • #1039 algorithms ranges::unique and ranges::unique_copy
      • #1044 Concept mergeable, and algorithms ranges::includes, ranges::set_difference, ranges::set_intersection, ranges::set_symmetric_difference, and ranges::set_union
      • #1052 algorithms ranges::sample and ranges::shuffle
      • #1053 algorithm ranges::move_backward
      • #1063 algorithm ranges::nth_element
      • #1073 algorithms ranges::rotate and ranges::rotate_copy
      • #1076 range access function ranges::ssize
      • #1081 algorithm ranges::lexicographical_compare
      • #1083 iterator adaptor counted_iterator
      • #1095 algorithm ranges::reverse_copy (vectorized like std::reverse_copy)
      • #1099 algorithms ranges::next_permutation and ranges::prev_permutation
      • #1101 algorithm ranges::merge
      • #1127 algorithm ranges::sort
      • #1132 view ranges::ref_view
      • #1137 algorithm ranges::uninitialized_move
      • #1201 range factories views::empty and views::single
      • #1229 range adaptors views::all and views::reverse
      • #1231 algorithms ranges::partial_sort and ranges::partial_sort_copy
      • #1245 P1391R4 Range Constructor For string_view
      • #1252 range adaptor views::filter
      • #1253 range adaptors views::drop and views::take
      • #1258 range adaptor views::transform
  • Merged LWG issue resolutions:
    • LWG-1203 #1225 More useful rvalue stream insertion
    • LWG-2597 #884 std::log misspecified for complex numbers
    • LWG-3070 #923 path::lexically_relative causes surprising results if a filename can also be a root-name
  • Fixed bugs:
    • variant no longer emits warnings about narrowing/sign conversions when determining which alternative should be activated for a given initializer. (Warnings can still be emitted by the chosen initialization; that's intentional and desirable.) #858
    • condition_variable_any now correctly unlocks-and-relocks the lock argument to timed wait functions when given a non-positive relative timeout or absolute time in the past. #685
    • std::pow is now templated to handle integral and floating-point types as required by C++11 and later. For example, std::pow(float, int) previously returned float and now returns double. #903
    • Removed a bogus overload of ranges::copy_n that wasn't supposed to exist and wouldn't have compiled. #957
    • filesystem_error now transcodes wide characters with no equivalent in the current locale to replacement characters instead of failing and throwing system error. #1010
    • Fixed 0 <=> partial_ordering::unordered to return the correct value, and improved <compare> codegen. #1049
    • discrete_distribution no longer yields invalid results when its parameters sum very close to, but not equal to 1. #1025
    • move_iterator::current is no longer inadvertently a protected data member - it has become properly private and been renamed. #1080
    • Range algorithms no longer mishandle pointer-to-member predicates and projections when they are larger than void*. #1091
    • The slice_array, gslice_array, mask_array, and indirect_array helpers defined in <valarray> now have proper copy constructors and copy assignment operators. #988
    • Fixed a bug in ranges::iter_swap that would cause it to sometimes drop one of the "swapped" values on the floor. #1072
    • weak_ptr conversions now preserve control blocks for expired objects. #1104
    • Fixed <bit>'s countl_zero to correctly use the bsr instruction as a fallback for old CPUs ...
Read more

VS 2019 16.7

09 Mar 05:19
0e4c641

Choose a tag to compare

  • Merged C++20 features:
    • P0415R1 #367 constexpr For <complex> (Again)
    • P0476R2 #583 <bit> bit_cast
    • P0586R2 #621 Integer Comparison Functions
    • P0674R1 #309 make_shared() For Arrays
      • LWG-3005 Destruction order of arrays by make_shared/allocate_shared only recommended?
      • LWG-3007 allocate_shared should rebind allocator to cv-unqualified value_type for construction
    • P0718R2 #601 atomic<shared_ptr<T>>, atomic<weak_ptr<T>>
    • P0722R3 #692 Efficient Sized delete For Variable Sized Classes (library support types)
    • P1023R0 #599 constexpr For std::array Comparisons
    • P1115R3 #566 erase()/erase_if() Return size_type
    • P1831R1 #634 Deprecating volatile In The Standard Library
    • P1871R1 #607 disable_sized_sentinel_for; renames disable_sized_sentinel to disable_sized_sentinel_for.
    • P1956R1 #524 <bit> has_single_bit(), bit_ceil(), bit_floor(), bit_width()
    • P1976R2 #500 Explicit Constructors For Fixed-Extent span From Dynamic-Extent Ranges
    • P2116R0 #587 Removing tuple-Like Protocol Support From Fixed-Extent span
  • Merged partial C++20 features:
    • P0768R1 #515 Library Support For The Spaceship Comparison Operator <=>; includes lexicographical_compare_three_way.
    • P0784R7 #501 Library Support For More constexpr Containers; includes construct_at.
    • P0896R4 Ranges:
      • #385 function objects ranges::equal_to, ranges::not_equal_to, ranges::less, ranges::less_equal, ranges::greater, and ranges::greater_equal
      • #734 ranges::subrange and ranges::view_interface
      • #759 changes to reverse_iterator to better adapt C++20 iterators
      • #787 similar changes to move_iterator, implement move_sentinel
      • #815 algorithm ranges::find_end
      • #821 algorithm ranges::find_first_of
      • #822 algorithm ranges::adjacent_find
    • P1135R6 The C++20 Synchronization Library; includes atomic_flag::test and lock-free integral types. #684
    • P1614R2 #385 Adding Spaceship <=> To The Library; includes concepts three_way_comparable and three_way_comparable_with, type trait compare_three_way_result (with _t variant), and function object compare_three_way.
  • Merged LWG issue resolutions:
    • LWG-3149 #635 DefaultConstructible should require default initialization
    • LWG-3255 #506 span's array constructor is too strict
    • LWG-3320 #548 span::cbegin/cend methods produce different results than std::[ranges::]cbegin/cend
    • LWG-3329 #512 totally_ordered_with both directly and indirectly requires common_reference_with
    • LWG-3330 #513 Include <compare> from most library headers
    • LWG-3390 #567 make_move_iterator() cannot be used to construct a move_iterator for a move-only iterator
  • Merged proposed resolutions for LWG issues that were eventually accepted at the November 2020 virtual plenary meeting:
    • LWG-3420 #786 cpp17-iterator should check that the type looks like an iterator first
    • LWG-3446 #834 indirectly_readable_traits ambiguity for types with both value_type and element_type
  • Fixed bugs:
    • operator/ and operator% for chrono::duration now properly SFINAE away when common_type_t<Rep1, Rep2> can't be formed. #573
    • <filesystem> directory_iterator now properly handles "." and ".." on network drives. #494
    • <filesystem> space() no longer requires read permissions for every directory along the path in some cases, and resolves symbolic links. #552
    • <filesystem> now considers ERROR_BAD_NETPATH as a "file does not exist" condition. #616
    • filesystem::path::path(const Source&) is now properly removed from overload resolution when Source is a non-iterator with member value_type even in C++20 mode. #631
    • The CMake release build now correctly uses the compiler flags in VCLIBS_RELEASE_OPTIONS. #608
    • Enabled the implementation of LWG-2899 in /clr mode now that the fix for the compiler bug triggered by such (VSO-1006185) has been released. #417
    • Fixed a bug specific to Clang 10 in <system_error> and removed the _SILENCE_CLANG_CONCEPTS_MESSAGE barrier in <concepts> now that we've worked with Clang developers to ensure Clang 10 and the STL play well together with Concepts enabled. #622
    • __cpp_lib_int_pow2 is no longer incorrectly defined when the compiler lacks support for the intrinsics necessary to implement has_single_bit, bit_ceil, bit_floor, and bit_width. Also, __cpp_lib_bitops is no longer defined when the compiler is EDG-imitating-MSVC, so IntelliSense properly reflects the non-availability of operations not yet supported by MSVC. #695
    • Fixed a 43-year-old bug in boyer_moore_searcher by implementing a 40-year-old fix. #724
    • std::function now handles over-aligned types. #698
    • <cvt/sjis_0208> now correctly recognizes bad second bytes. #755
    • Fixed several bugs in complex's Sufficient Additional Overloads. #791
      • arg(real) now behaves like arg(complex), instead of always returning 0.
      • conj(real) now behaves like conj(complex), returning an imaginary part of negative zero.
      • proj(real) now behaves like proj(complex), mapping negative infinity to positive infinity.
      • conj and proj now return complex.
      • norm now upgrades integers to double before squaring, instead of after.
    • <filesystem> now consistently handles nonexistent network paths when the Windows API emits ERROR_INVALID_NAME. #800
    • Fixed a race condition in the parallel adjacent_find algorithm that could cause it to return a result other than the first under heavy load. #816
  • Enhanced behavior:
    • Strengthened noexcept for array iterators, also improving the behavior of span construction from array iterators. #627
    • Removed a static_assert in <atomic> that prevented certain (completely conforming) usage from compiling until users defined the macro _ENABLE_ATOMIC_ALIGNMENT_FIX. Note: MSVC's STL has generated correct code for such usage since VS 2015 Update 2, so this change doesn't degrade correctness in any way - it merely removes an annoying compilation roadblock that warned about potential ODR violations when mixing code compiled with ancient toolsets that generated incorrect code for such usage in the first place. #723
    • Enabled bit_cast for IntelliSense now that front-end support is available. #733
    • complex's real(T) and imag(T) setters now properly return void. #367
    • Fixed Clang warnings in STL headers (when they aren't suppressed by Clang's treatment of "system headers") and enhanced test coverage to remain clean. #755
    • We now detect compiler support for consteval by testing __cpp_consteval. [#765](https://github.c...
Read more

VS 2019 16.6

09 Mar 05:17
2b2746d

Choose a tag to compare

  • Merged C++20 features:
    • P0122R7 #142 #474 <span>
      • P1024R3 Enhancing span Usability
      • P1085R2 Removing span Comparisons
      • P1227R2 Unsigned span::size()
      • P1394R4 Range Constructor For span
      • P1872R0 span Should Have size_type, Not index_type
      • LWG-3101 span's Container constructors need another constraint
      • LWG-3102 Clarify span iterator and const_iterator behavior
      • LWG-3103 Errors in taking subview of span should be ill-formed where possible
      • LWG-3144 span does not have a const_pointer typedef
      • LWG-3198 Bad constraint on std::span::span()
      • LWG-3274 Missing feature test macro for <span>
      • LWG-3369 span's deduction-guide for built-in arrays doesn't work
    • P0202R3 #425 constexpr For <algorithm> And exchange()
      • LWG-3256 Feature testing macro for constexpr algorithms
    • P0357R3 #393 Supporting Incomplete Types In reference_wrapper
    • P0619R4 #380 Removing C++17-Deprecated Features In C++20
    • P0879R0 #425 constexpr For Swapping Functions
    • P0883R2 #390 Fixing Atomic Initialization
    • P0935R0 #415 Eradicating Unnecessarily Explicit Default Constructors
    • P1006R1 #397 constexpr For pointer_traits<T*>::pointer_to()
    • P1165R1 #467 Consistently Propagating Stateful Allocators In basic_string's operator+()
    • P1423R3 #470 char8_t Backward Compatibility Remediation
    • P1645R1 #399 constexpr For <numeric> Algorithms
    • P1964R2 #565 Replacing boolean With boolean-testable
    • P2091R0 #565 Fixing Issues With Range Access CPOs
    • P2102R0 #565 Making "Implicit Expression Variations" More Explicit
  • Merged partial C++20 features:
    • P0768R1 Library Support For The Spaceship Comparison Operator <=>
      • #402 Deprecated std::rel_ops.
    • P0896R4 Ranges:
      • #389 some Ranges concepts, including P1456R1 Move-Only Views and P1870R1 safe_range.
      • #432 P2091R0 Issues With Range Access CPOs.
      • #565 algorithms ranges::all_of, ranges::any_of, ranges::copy, ranges::copy_if, ranges::copy_n, ranges::count, ranges::count_if, ranges::equal, ranges::find, ranges::find_if, ranges::find_if_not, ranges::for_each, ranges::for_each_n, ranges::mismatch, and ranges::none_of.
      • #589 changes to std::back_insert_iterator, std::front_insert_iterator, and std::insert_iterator necessary to model the Ranges iterator concepts.
  • Merged LWG issue resolutions:
  • Added test suites (not yet running):
  • Fixed bugs:
    • complex acos(), acosh(), and asinh() now return correct results. #401
    • complex pow() is now overloaded correctly. #383
    • Fixed std::filesystem::remove() on ReFS. #407
    • Avoided using iter[idx] in all algorithms, because it's problematic with some unusual but Standard-conforming iterators. #464
    • <system_error> now maps ERROR_BROKEN_PIPE to errc::broken_pipe. #406
    • Fixed a compiler error when compiling with the Intel C++ Compiler, because it hadn't implemented C++20 conditional explicit in C++14/17 mode. #424
      • Note: The Intel C++ Compiler remains unsupported by MSVC.
    • Fixed the visualizers for atomic and atomic_flag. #315
  • Improved performance:
    • Significantly improved performance of string + null terminated and null terminated + string operator+ overloads in <string>. #467
    • Reduced memory consumption of system_category().message(). #457
    • Optimized is_permutation() and operator== for unordered multi-containers. #423
  • Improved throughput:
    • Significantly improved compile times for <iterator> and <array>. Note that this is a source-breaking change for user code that expected STL headers to include other headers in certain ways. #355
  • Code cleanups:
    • src/syserror.cpp now uses range-for and static_cast. #481
    • Changed macro constants to constexpr variables. #487
    • Cleaned up the implementation of sort(). #449
    • Added static_assert is_sorted() for lookup tables. #451
    • Removed compiler workarounds. #410 #452 #453 #454
    • Added compiler workarounds. #475
    • Updated the STL's required compiler to MSVC 19.25. #430
    • Enabled clang-format for slightly more code. #458
  • Infrastructure improvements:
    • Fixed errors when building the STL with Boost 1.72. #447 #428
    • Improved how the CI builds boost-math. #450
  • Updated _MSVC_STL_UPDATE. #429 #486