MSVC's implementation of the C++ Standard Library.
<mdspan>
static operator()
std::function
and packaged_task
to work with a C++23 Core Language feature, currently supported for Clang only. When MSVC and IntelliSense implement this Core feature, this will automatically "light up" the STL's CTAD for them too."1e-07"
was incorrectly parsed as 1e-06
). #3982
expected
together with any
. #4013
any
, and fixed compiler errors in any
involving incomplete types. #3965
basic_string
's copy assignment operator, specific to non-equal propagate_on_container_copy_assignment
allocators, involving ASan annotations or fancy pointers. #4031
get()
and comparison operators to handle program-defined specializations of array
. #4041
to_array()
involving incomplete types. #4042
stl_asan.lib
by disabling ASan annotations in the STL for unsupported platforms (e.g. ARM, ARM64, ARM64EC). #4058
not_fn()
to return a perfect forwarding call wrapper in C++20 mode as required by P0356R5. #4057
deque
to preserve its internal invariants when taking advantage of allocators that provide allocate_at_least()
. #4017
deque
emplace()
and insert()
to not require elements to be swappable; this change also improved performance. #4022
deque
to handle highly unusual fancy pointers. #4049
deque::shrink_to_fit()
to avoid requiring the allocator to be default constructible. #4071
allocate_shared()
for unbounded arrays to handle fancy pointers. #4074
basic_stringbuf
's Buffer to properly destroy fancy pointers. #4047
this_thread::sleep_until()
to consistently use the given time_point
's clock type, instead of also depending on the system clock. This also fixed this_thread::sleep_for()
to consistently use steady_clock
. #3914
<random>
: #4120
base_type
typedefs from discard_block_engine
, independent_bits_engine
, and shuffle_order_engine
.discard_block_engine(Engine&&)
to move-construct the base engine instead of copying it.copy()
, copy_n()
, and move()
algorithms for vector<bool>
iterators, with speedups varying from 1.8x (times, not percent) to an incredible 3200x, depending on the size and alignment of the bits being copied. #3353 #4045
priority_queue::push_range()
for small ranges. #4025
deque
by using unchecked iterators internally. #4071
basic_string
's range constructors to use memmove()
for contiguous ranges when possible. #4073
ranges::find_last
. #3925
<valarray>
binary operations, verifying that the operands have the same size. #3911
basic_istream
's ipfx()
/isfx()
and basic_ostream
's opfx()
/osfx()
member functions as they're non-Standard extensions. #4006
static_assert
s like "error STL1000: Unexpected compiler version, expected Clang 16.0.0 or newer." instead of just "Error in C++ Standard Library usage." #4020
/Wall
warnings:
/Wall
is not intended for regular production use, as it contains a large number of extremely noisy and low-value warnings. In general, the STL does not attempt to be /Wall
clean.num_get::do_get()
to tolerate 80-bit long double
by removing a static_assert
that was added in 2018. #4032
long double
remains unsupported by MSVC.source_location::function_name()
: #4055
_USE_DETAILED_FUNCTION_NAME_IN_SOURCE_LOCATION
to 0
.template <typename T> void cats()
called with cats<vector<int>>()
, MSVC's detailed info (implemented in VS 2022 17.6) is "void __cdecl cats<class std::vector<int,class std::allocator<int> >>(void)"
. Clang 17's detailed info is "void __cdecl cats(void) [T = std::vector<int>]"
. The escape hatch will return the basic info "cats"
.ranges
algorithms to be ordinary function objects. #4098
views::transform(ranges::distance)
to compile.extern "C"
functions as noexcept
. #4106 #4150
/EHs
(versus /EHsc
, where extern "C"
already implies noexcept
).basic_string
's ASan annotations when exception handling interacts with the Small String Optimization. #4118
<format>
table generator script from C++ to Python. #3994
<format>
uses the compiler macro _MSVC_EXECUTION_CHARACTER_SET
. #4076
_MSVC_STL_UPDATE
. #4003 #4062
std
and std.compat
are now available when compiling in C++20 mode. #3977
import std
in C++20. This change makes it possible for them to do so.basic_format_arg(T&&)
should use remove_cvref_t<T>
throughoutstd::expected<T, E>::value() &
assumes E
is copy constructibleatomic<shared_ptr<T>> a; a = nullptr;
lazy_split_view::
outer-iterator
's const
-converting constructor isn't setting trailing_empty_
deque(size_type)
constructor to properly destroy elements when constructing one of them throws an exception. #3720
basic_istream >> setfill(c)
. #3725
cartesian_product_view::size()
to always accept empty views. #3733
formatter<char, wchar_t>
to format the char
as a character instead of an integer. #3723
ISA_AVAILABILITY
. #3721
chrono::hh_mm_ss
formatting to accept values of 24 hours or more. #3727
condition_variable_any::wait_until()
to handle time_point
s with unsigned representations instead of waiting forever. #3761
counting_semaphore
to add compile-time enforcement of the Standard's mandates. #3747
mutex
could throw a bogus exception. #3763
char_traits
member functions to exactly match the Standard. #3739
visit_format_arg()
is called with highly unusual visitors. #3787
format()
is asked to format a floating-point value in the alternate form without a type specifier. #3815
<format>
machinery to work with /utf-8
via import std;
. #3816
constexpr basic_string
's copy assignment operator, where it wasn't starting element lifetimes for the unused capacity. #3712 #3819
function::target<FunctionType>()
on const function
objects. #3844
array<T, 0>
in constexpr
contexts. #3863
bind()
, bind_front()
, and bind_back()
function objects. #3775
noexcept
s within the implementations of filesystem::current_path()
, filesystem::current_path(error_code&)
, read_symlink(const path&)
, and read_symlink(const path&, error_code&)
. #3869 #3881
shared_ptr<void>
to not be constructible from void*
. #3873
#pragma once
from all STL headers. #3895
#pragma once
is no longer needed to improve throughput because modern compilers automatically detect the idempotency guard idiom.<stacktrace>
's internal use of snprintf()
in extreme situations. #3916
basic_string
's copy assignment operator, specific to non-equal propagate_on_container_copy_assignment
allocators. #3862
basic_string::replace()
. #3884
basic_string::assign()
and basic_string::resize_and_overwrite()
. #3956
static
, slightly improving debug codegen. #3755
mutex
and condition_variable
now avoid virtual function calls within their implementations. #3770
steady_clock::now()
when QueryPerformanceFrequency()
is exactly 24 MHz, which is very common for ARM64. #3832
filesystem::path::lexically_normal()
. #3850
basic_string
, basic_stringbuf
, basic_syncbuf
, deque
, and vector
now take advantage of allocators that provide allocate_at_least()
. #3864 #3891
<format>
slightly. #3826
bitset::to_string()
. #3838 #3904
as_const()
, to_integer()
, and to_underlying()
that allows the MSVC compiler to intrinsically implement them without emitting function calls. #3664
valarray
(access the stored size directly instead of via calling size()
) to improve debug codegen. #3968
integer_sequence
, make_integer_sequence
, index_sequence
, make_index_sequence
, and index_sequence_for
from <type_traits>
to <utility>
, which is where the Standard provides them.allocator_arg
, allocator_arg_t
, uses_allocator
, and uses_allocator_v
so that they're dragged in by slightly fewer headers. (The Standard provides them in <memory>
.)<limits>
. #3777
is_same_v
. #3933
iota_view(value)
constructor. #3731
barrier
. #3757
/W4 /analyze
clean, but does not yet attempt to be clean with respect to all additional static analysis rulesets.<ranges>
machinery used in join_view
iterators and lazy_split_view
. #3762
basic_string_view::compare(const charT*)
. #3738
locale::facet
and related base classes. #3855
<complex>
. #3880
<random>
, some functions in <valarray>
, and 3-arg hypot()
in <cmath>
. #3887
stdext::checked_array_iterator
and stdext::unchecked_array_iterator
: #3818
const
ness conversions.std::span
and gsl::span
.minmax
and ranges::minmax
, allowing MSVC code analysis and Clang -Wdangling
to detect dangling references in improper usage. #3831
views::cartesian_product
detects ranges with maximum sizes that are known at compile time. #3839
abort()
instead of terminate()
for unrecoverable conditions, when the Standard doesn't require terminate()
to be called. #3906 #3909
vector<char>
and the other character types. #3772
mutex
and recursive_mutex
. #3848
chrono::duration_cast()
to use if constexpr
, improving debug codegen. #3958
ranges::owning_view
. #3753
tellg()
while reading an LF file in text mode. #3773 #3841
Facet
is a nullptr
. #3823
filesystem::copy()
won't create a symlink to a directory. #3827
is_assignable_v
and is_nothrow_assignable_v
. #3898
views::as_const
, views::stride
, and views::zip
. #3920
override
to avoid mistakes, following the same convention as product code. #3934
is_permutation()
tests. #3967
regex_iterator
and regex_token_iterator
tests. #3990
[[noreturn]]
. #3865 #3882
typename
keywords in C++20 mode and later. #3892 #3893 #3894
enum class
for internal machinery within <condition_variable>
, <mutex>
, and <thread>
. #3897
basic_string
's implementation. #3862
<cvt/meow>
headers and their provided character encoding conversion machinery. #3924
MultiByteToWideChar()
and WideCharToMultiByte()
._MSVC_STL_UPDATE
. #3742 #3851 #3918
<stdfloat>
header containing an empty namespace std {}
, as we don't support any optional extended floating-point types.<print>
: Formatted Output
print()
With The Underlying Streamviews::enumerate
tuple
, pair
, And tuple-like Objectszip
, completed by implementing:
views::cartesian_product
std::format
Fill Character Allowancesfloat_denorm_style
, numeric_limits::has_denorm
, numeric_limits::has_denorm_loss
allocator_traits
common_reference_t
Of reference_wrapper
Should Be A Reference Type<format>
now understands Unicode 15.match_results
mutex::lock()
should not throw device_or_resource_busy
sub_match::swap
only swaps the base classINVOKE
operation and union
typespair
specially handled in uses-allocator construction?ranges::to
misuses cpp17-input-iterator
inout_ptr
and out_ptr
for empty caseuses_allocator_construction_args
should have overload for pair-like
template<size_t N> struct formatter<const charT[N], charT>
std::expected<bool, E1>
conversion constructor expected(const expected<U, G>&)
should take precedence over expected(U&&)
with operator bool
ranges::to
can still return viewschunk_view::
inner-iterator
missing custom iter_move
and iter_swap
range_common_reference_t
is missingbasic_const_iterator
's common_type
specialization is underconstrainedpair
s
std::errc
constants related to UNIX STREAMSvoidify
basic_const_iterator
should have custom iter_move
std::ranges::repeat_view<T, IntegerClass>::
iterator
may be ill-formedconst
-qualified monadic overloads for std::expected
allocate_at_least
ios_base
constants (e.g. ios_base::binary
, ios_base::failbit
, ios_base::hex
) to have the correct bitmask types. #3405
<ranges>
to avoid using list-initialization when the difference between braces and parentheses is observable. #3493
pmr::unsynchronized_pool_resource
to respect pmr::pool_options::max_blocks_per_chunk
when it's smaller than the default initial number of blocks per chunk. #3510
<regex>
and <sstream>
found by Clang/LLVM's Undefined Behavior Sanitizer (UBSan). #3452
ranges::equal
with ranges involving views::iota
. #3551
_Prevent_inheriting_unwrap
typedef. #3566
-Wzero-as-null-pointer-constant
when comparing the spaceship operator's return types (partial_ordering
, weak_ordering
, strong_ordering
) with literal 0
. #3581
bind()
function objects to have constrained function call operators, so they interact properly with is_invocable
and related scenarios. #3577
<future>
's use of <ppltasks.h>
in Desktop XAML apps) because it introduced an ole32.dll
dependency that broke multiple scenarios. #3607
views::cartesian_product
to avoid compiler errors in pathological scenarios. #3609
min_element()
, max_element()
, and minmax_element()
. #3619
shared_ptr
's operator<=>
. #3647
shared_ptr<const int>
to shared_ptr<void>
.chrono::ambiguous_local_time
's message to exactly match the Standard. #3650
chrono::duration
types. #3649
optional::transform()
to avoid terminating when the callable object throws an exception. #3668
<charconv>
floating-point from_chars()
to correctly handle two scenarios involving exponents with large absolute values. #3670
typeid(T).name()
. #3677
cartesian_product_view
. #3678
unordered_meow
containers allocating too few buckets. #3687
mutex
and recursive_mutex
construction by avoiding a Windows API call. #3522
unique_ptr
move assignment by avoiding an unnecessary branch. #3540
chrono::time_zone::to_sys
and chrono::time_zone::to_local
, with a speedup of approximately 3x (times, not percent). #3579
type_index::operator<=>
to avoid calling the comparison function twice. #3600
VZEROUPPER
instruction at the end of every AVX2 codepath in the STL's vectorized algorithms, improving performance in non-optimized debug mode when the compiler doesn't automatically insert this instruction. #3630
system_error(error_code)
and system_error(int, const error_category&)
. #3635
<optional>
and <variant>
now include fewer headers. #3624
<regex>
where it's needed. #3625
<chrono>
now avoids including <algorithm>
. #3626
<compare>
now avoids including <bit>
. #3627
<cstdlib>
for exit
, quick_exit
, etc.<initializer_list>
for initializer_list
.
initializer_list
is used implicitly when only braces appear in the source code.<functional>
for unary_function
and binary_function
.
unary_function
and binary_function
were deprecated in C++11 and removed in C++17, so it's best to stop using them completely.<memory>
for addressof
.<functional>
for less
, less_equal
, greater
, greater_equal
, equal_to
, not_equal_to
, plus
, minus
, and multiplies
.swap
via Argument-Dependent Lookup, it now does so directly; the internal helper function _Swap_adl
has been removed. #3700
bitset::reference
and test code) of MSVC's new off-by-default warning C5267 for deprecated implicit copy constructors/assignment operators. #3497
<source_location>
for Clang. #3584
xtime
type from <chrono>
. #3594
static_assert
s to containers, container adaptors, and allocator
to improve the error messages when they're given non-object types. #2436 #3660
allocator<void>
is still permitted as a special case.views::empty
, views::iota
, views::istream
, views::repeat
, and views::single
. #3553
ranges::ref_view
, ranges::subrange
, views::common
, views::filter
, views::join
, views::reverse
, and views::transform
. #3612
fill_n()
instead of fill()
when possible. #3578
libcxx/expected_results.txt
. Consequently, (1) compile-only tests (test.compile.pass.cpp
) no longer need a redundant int main() {} // COMPILE-ONLY
, and (2) we no longer need to redundantly update libcxx/skipped_tests.txt
(which has been removed) identically to libcxx/expected_results.txt
. #3484
_MSVC_STL_UPDATE
. #3518 #3643 #3680
ranges::find_last
, ranges::find_last_if
, ranges::find_last_if_not
boolean-testable
Usagecbegin
Should Always Return A Constant Iteratorios_base::noreplace
: Exclusive Mode For fstream
sviews::repeat
expected
barrier
's Phase Completion Guaranteesexplicit
operator<<
should be less templatizedstd::pointer_traits
should be SFINAE-friendlyinout_ptr
- inconsistent release()
in destructormake_error_code
and make_error_condition
are customization pointsstd::ranges::view_interface::size
returns a signed typecommon_view::end
should improve random_access_range
casemove_iterator
missing disable_sized_sentinel_for
specializationtake_view::
sentinel
should provide operator-
ranges::to
's reserve
may be ill-formedoptional
's spaceship with U
with a type derived from optional
causes infinite constraint meta-recursionbasic_const_iterator::operator==
causes infinite constraint recursionrepeat_view
's piecewise constructor is missing preconditionsvector<bool>
missing exception specificationsranges::to
is over-constrained on the destination type being a rangeiterator_category
std::basic_format_args
is_aggregate
slide_view
missing base
accessorviews::as_const
on empty_view<T>
should return empty_view<const T>
basic_const_iterator<volatile int*>::operator->
is ill-formedtime_put<wchar_t>
from the Standard Library Modules. #3232
meow.lib
and object meow.exp
" (while building meow.exe
) when using <stacktrace>
or importing the Standard Library Modules.basic_string
, which could lead to missing null terminators causing crashes and other runtime misbehavior, when linking code that was built with different versions of the STL. #3235
constexpr
basic_string
in VS 2022 17.4.ppltasks.cpp
powering std::async()
, which could lead to crashes caused by an invalid_operation
exception slamming into noexcept
. #3255
find()
, count()
, ranges::find()
, and ranges::count()
. #3247
int
-1
in a range of unsigned int
elements should consider the element 0xFFFF'FFFFu
to be equal (due to C++'s usual arithmetic conversions), but it was incorrectly considered to be non-equal.optional<T>
to work when T
has a custom visualizer. #3243
long double
to copysign()
. #3253
<string>
after fixing significant bugs. #3164
<vector>
that were failing when pmr::vector
was used with pmr::monotonic_buffer_resource
on x86.ranges
types to std::copy()
. #3270
shared_future<void>
's move assignment operator to be noexcept
as required by the Standard. #3284
<intrin.h>
, which is a header that Clang recognizes and supports. #3285
numeric_limits
to correctly report that is_signed
is true
for the STL's internal 128-bit signed-integer-class type. #3291
<stacktrace>
to correctly pass SYMOPT_FAIL_CRITICAL_ERRORS
to the Windows API. #3292
<charconv>
(and headers that include it, like <chrono>
and <format>
) to avoid emitting warning C4365 "signed/unsigned mismatch" when being compiled with /J
. #3295
/J
compiler option, as it's a recipe for One Definition Rule violations and it doesn't improve Standard conformance.ranges::cbegin
, ranges::cend
, ranges::crbegin
, ranges::crend
, and ranges::cdata
to behave like their non-const
counterparts when given array rvalues. #3316
constexpr
basic_string
to correctly start the lifetimes of its elements, avoiding compiler errors. #3334
views::istream
constraints to precisely follow the Standard. #3335
<memory>
algorithms. #3145
vector<bool, Alloc>
on 32-bit platforms with 64-bit difference_type
s to support storing more than 232 bits. #3342
ranges::prev
on an iota_view
iterator in debug mode. #3356
ranges::minmax
to avoid moving from an element twice when called with a single-element range of move_iterator
s. #3366
std.ixx
Standard Library Module. #3373
module;
introduces a global module fragment, it is required to be the first thing in the file other than comments, although MSVC doesn't enforce this rule yet.-Wdeprecated
warnings that said "out-of-line definition of constexpr static data member is redundant in C++17 and is deprecated". #3381
vformat_to()
to instantiate its machinery in a lazier way. #3403
<format>
or <chrono>
, this avoids instantiating dynamic initializers for facet IDs, and improves throughput slightly.string
s in locale::operator==()
. #3250
count()
's vectorized implementation for more eligible iterators in C++14/17 modes. #3262
find()
, count()
, ranges::find()
, and ranges::count()
for more scenarios involving pointer elements. #3267
<atomic>
for ARM64, massively improving load-acquire and store-release (measured 14.1x to 23.8x speedups - times, not percent) and significantly improving sequentially consistent stores (measured 1.58x speedup). #3399
ranges::find
now calls memchr()
in more situations (when the vectorized implementation isn't available). #3386
/clr
for C++11 multithreading (mutex
, condition_variable
, future
, etc.) and C++17 parallel algorithms. Additionally, the STL now allows /clr
to be used in C++20 mode. #3194 #3201
/clr
scenarios.error_category
and error_code
. #3204
source_location::function_name()
. #3206
"int __cdecl square(int)"
instead of "square"
.vector
iterator, it now displays an assertion message instead of abruptly crashing. #3282
<mutex>
to use scope guards instead of throw;
, making debugging easier when exceptions are thrown. #3321
modules/modules.json
to support build systems. #3358 #3488
ranges::minmax
and ranges::minmax_element
to detect the single-element case naturally. #3384
operator""meow
without a space, because CWG-2521 is deprecating the form operator"" woof
with a space. #3453
<__msvc_cxx_stdatomic.hpp>
in C mode. #3192
<stdatomic.h>
test coverage for Clang. #3186
source_location
. #3339
views::elements
. #3350
views::drop
, views::drop_while
, views::take
, and views::take_while
. #3390
experimental::filesystem::recursive_directory_iterator::operator++()
. #3279
[[nodiscard]]
attribute. #3397
libcxx
test suite. #3464
_MSVC_STL_UPDATE
. #3191 #3264 #3362 #3395
ranges::fold_left
, ranges::fold_right
, etc.std
And std.compat
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
.)basic_format_string
, format_string
, wformat_string
cbegin
Should Always Return A Constant Iterator:
basic_const_iterator
, make_const_iterator()
, and make_const_sentinel()
. #3043
zip
:
views::zip
. #3035
views::zip_transform
, views::adjacent
, and views::adjacent_transform
are the parts that remain to be implemented.locale::c_str()
. #3088
piecewise_constant_distribution<float>::densities()
and piecewise_linear_distribution<float>::densities()
. #3107
ranges::is_permutation
with predicates that return highly unusual boolean-testable types. #3113
std.ixx
with /GR- /D_HAS_STATIC_RTTI=0
will succeed, and std::any
will simply be unavailable (as it inherently requires static RTTI).<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.reference_wrapper
, thread
, and variant
involving incomplete types. #3101 #3148
chrono::time_zone::get_info()
throws an exception, fixed it to report GetLastError()
as intended, instead of "The operation completed successfully."
#3122
ellint_2()
. #3077
error_category
's default constructor to be constexpr
. #3139 #3176
break
statement? Use [[fallthrough]]
when a break
statement is intentionally omitted between case
s". #3162
<ranges>
scenarios by properly constraining movable-box
's copy constructors. #3171
move_sentinel
. #3098
uniform_int_distribution
by implementing Daniel Lemire's algorithm Fast Random Integer Generation in an Interval. #3012
gcd()
to avoid a redundant shift. #3127
locale::classic()
for a 10x speedup (times, not percent). #3048
move()
, forward()
, move_if_noexcept()
, and forward_like()
that will allow the MSVC compiler to intrinsically implement them without emitting function calls. #3182
get_future()
's [[nodiscard("message")]]
. #3068
<xatomic.h>
, <xbit_ops.h>
, and <xerrc.h>
are now core headers. #3116
<format>
's compiler error messages for unformattable types. #3080
<variant>
visit()
invoking pointers to members. #3070
forward_like()
. #3072
views::as_rvalue
. #3089
bind_front()
and bind_back()
. #3117
any
/optional
/variant
shared test code. #2976
is_partitioned()
test. #3174
<atomic>
implementation details, preparing for later changes. #3124
common_type
for the STL's internal 128-bit integer-class types. #3153
_MSVC_STL_UPDATE
. #3073 #3147
auto(x)
: decay-copy
In The Language
<stacktrace>
pmr
Alias For std::stacktrace
constexpr
type_info::operator==()
views::stride
constexpr
Integral <charconv>
ranges::contains
, ranges::contains_subrange
constexpr
bitset
chrono
Typesstring::substr() &&
ranges::iota
, ranges::shift_left
, ranges::shift_right
views::join_with
forward_like()
views::as_rvalue
string_view
Range Constructor Should Be explicit
noexcept
For apply()
move_iterator<T*>
Should Be A Random-Access Iteratortransform_view::
iterator
<true>::value_type
and iterator_category
should use const F&
function
/packaged_task
deduction guides and deducing this
atomic_fetch_xor
missing from stdatomic.h
common_iterator::operator->()
should return by valueoperator==
for polymorphic_allocator
cannot deduce template argument in common casesformatter<remove_cvref_t<const charT[N]>, charT>
requirement explicitchunk_view::
outer-iterator
::value_type::size
should return unsigned typeend
of chunk_view
for input ranges can be const
chunk_view
and slide_view
should not be default_initializable
view_interface::empty
is overconstraineddecay-copy
should be constrained<any>
with our unofficially supported mode to disable exceptions. #2193
<format>
with the new compiler option /presetPadding
by adding a compiler bug workaround. #2746
complex
zero to behave consistently with other implementations. #2758
<syncstream>
. #2763
long
or unsigned long
values with formatter
. #2768
deallocate()
with null pointers. User-defined allocators aren't required to tolerate that, so the containers now avoid such calls. #2790
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_code
s), except that "file not found" is not considered an error. #1343
construct_at()
, allowing immovable objects to be emplaced via copy elision. #2624
time_point
s. #2705
lerp()
now avoids overflowing to infinity when it can calculate the correct result with a fallback approach. #1918
list
, forward_list
, or ordered/unordered associative container. #2782
stdext::hash_map
container family. #2784
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
source_location::current()
in certain scenarios. #2824
<format>
to print duration
s with extremely small periods (e.g. femtoseconds, attoseconds). #2814
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
"%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.std::filesystem::directory_entry::clear_cache()
, which was a non-Standard extension. #2854
<complex>
log()
/log10()
/pow()
on ARM64. #2870
path::lexically_relative()
to handle UNC drive paths like \\?\C:\meow.txt
. #2867
filesystem::read_symlink()
and filesystem::copy()
to handle junctions. #2877
ranges::uninitialized_copy_n
and ranges::uninitialized_move_n
with certain input iterators. #2964
ranges::enable_view
to properly reject references and to avoid compiler errors in certain unusual situations. #2978
<string>
while significant bugs are under investigation. #2990
views::chunk_by
with unusual predicates returning non-bool
types. #2890
visit<R>()
involving conversions to immovable types. #2971 #2999
chrono::abs()
in certain unusual situations. #2988
<format>
to always print NaNs as "nan"
, "-nan"
, or uppercase versions as required by the Standard, never "-nan(ind)"
. #3001
ranges::shuffle
and ranges::sample
to accept uniform_random_bit_generator
s that don't provide result_type
. #3002
vector<bool>::insert(where, first, last)
and vector<bool>::insert_range(where, range)
to meet the Standard's complexity requirements. #3021
chunk_view
and stride_view
iterators validate their preconditions. #3023
basic_string_view<char_like_struct>
. #3032
move_only_function
to behave correctly when passed between DLLs. #3038
dllexport
ing classes derived from pair
or tuple
. #3045
<regex>
integer overflows when parsing huge numbers in backreferences, braced repetitions, and decimal escapes. #2169
regex_error
s with codes of error_backref
, error_badbrace
, and error_escape
, respectively.ranges::distance
to follow the Standard, which depicts two overloads (for sized and unsized sentinels). #2987
basic_string::substr()
now uses a default-constructed allocator as required by the Standard. #3057
std::_Bit_cast
by using __builtin_bit_cast
instead of a memcpy
workaround. #3066
clamp()
codegen with conditional move instructions. #2336
signed char
, unsigned char
, char8_t
, and byte
elements, matching the performance of char
by avoiding a slow codepath. #2739
vector
's range constructor, insert()
, and assign()
now efficiently handle iterators that satisfy the forward_iterator
concept, even when their classic iterator_category
isn't convertible to forward_iterator_tag
. #1794
<format>
grapheme clusterization, saving 2670 bytes. #2757
std::filesystem::path::lexically_relative()
now avoids unnecessary memory allocations. #1915
min_element()
, max_element()
, minmax_element()
, ranges::min_element()
, ranges::max_element()
, and ranges::minmax_element()
, with speedups ranging from 1.5x to 26.6x (times, not percent). #2447 #2821 #2825
atomic::wait
. #2781
thread::join()
. #2820
mutex::try_lock()
. #2317
filesystem::resize_file()
and experimental::filesystem::resize_file()
. #2771
T + complex<T>
, T * complex<T>
, complex<T> * T
, and complex<T> / T
. Improved the debug codegen for complex<T> + T
and complex<T> - T
. #2855
unreachable()
. #3055
if constexpr
instead of tag dispatch in:
get<I>()
and get<T>()
for pair
. #2756
optional
, pair
, and tuple
now use conditional explicit
instead of SFINAE in all Standard modes, for all supported compilers. #2796
n + vector::iterator
). This improves throughput by not polluting unqualified name lookup. #2797
<charconv>
's large lookup tables are now separately compiled, so translation units including <charconv>
will emit significantly smaller object files. #2125
<unordered_map>
and <unordered_set>
now avoid including most of <string>
. #2996
<functional>
, which internally uses <unordered_map>
to implement boyer_moore_searcher
._SILENCE_STDEXT_HASH_DEPRECATION_WARNINGS
. #3027
<functional>
now avoids including <memory>
. #2998
_LEGACY_CODE_ASSUMES_FUNCTIONAL_INCLUDES_MEMORY
. #3027
<tuple>
is now a core header. #2730
char8_t
in C++14 and C++17 modes via /Zc:char8_t
. #2748
complex<NonFloating>
now emits a deprecation warning explaining that it has unspecified behavior according to the Standard. #2759
wchar_t
is a real type, the STL now avoids emitting many specializations for unsigned short
that are intended for fake wchar_t
only (i.e. the non-Standard /Zc:wchar_t-
option). #2164
constexpr
variables as inline
in C++17-and-later mode. #2792
'std::_Meow'
has internal linkage in an included header file context, but external linkage in imported header unit context; consider declaring it 'inline'
as well if it will be shared across translation units, or 'static'
to express intent to use it local to this translation unit".constexpr
basic_string
now uses the Small String Optimization. #1735
error_code
s with 0
values and future_category
or iostream_category
now return "success"
from message()
, matching the behavior of generic_category
. #2742
<system_error>
now maps: #2744 #2899
WAIT_TIMEOUT
, ERROR_TIMEOUT
, and ERROR_SEM_TIMEOUT
to errc::timed_out
ERROR_BAD_NET_NAME
to errc::no_such_file_or_directory
ERROR_FILENAME_EXCED_RANGE
to errc::filename_too_long
unique_ptr
s and vector
s storing character sequences. #2843
<any>
, <format>
, <functional>
, <mutex>
, and <ranges>
. #2191
<cstdlib>
now makes its using
-declarations for std::getenv()
and std::system()
available to UWP apps. #2850
<filesystem>
and <experimental/filesystem>
now use GetTempPath2W()
when it's available on Windows 11. #2302
_Init_locks::operator=
in unusual situations. #3011
<meow>
are available only with C++NN or later."<coroutine>
are not available with /await
."<unordered_map>
and <unordered_set>
no longer provide a non-Standard hash_compare
class template in namespace std
. #2996
[[nodiscard]]
warnings, when the compiler supports [[nodiscard("message")]]
and the reason is more complex than the common/simple scenario of pure observers. #2211
std::remove_if()
now emits a detailed warning message, explaining the classic erase-remove idiom, and suggesting C++20 std::erase_if()
instead.vector::assign(num, val)
and std::swap_ranges()
now have debug checks for forbidden aliasing. #1263
_ENFORCE_ONLY_CORE_HEADERS
, limiting STL usage to the subset of core headers. #2068
<coroutine>
. #2861
/permissive
configurations to tests that can successfully compile in this discouraged-but-supported mode. #3015
<source_location>
test for an upcoming compiler fix. #3046
<string>
bug (specific to ASan annotations being enabled) that was fixed. #3039
tuple_cat()
's implementation. #2833
<system_error>
maps Windows error codes to errc
values. #2837
<atomic>
to share code with C11 atomics (work in progress). #2846
<cmeow>
wrapper headers instead of the <meow.h>
CRT headers. #2852
<random>
's static constexpr
data members. #3006
typedef
to using
. #3018
<functional>
and <memory>
to consistently use modern int = 0
SFINAE. #2124
basic_string
doesn't use templated static constexpr
data members as internal helpers. #2980
/analyze
to PR/CI builds, and fixed warnings in the STL's separately compiled sources. #2812
_MSVC_STL_UPDATE
. #2764 #2840 #3020
tuple
constructor constraints for UTypes&&...
overloadsuses_allocator_construction_args
fails to handle types convertible to pair
basic_osyncstream::emit
should be an unformatted output functionflush_emit
should set badbit
if the emit
call failsvector<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_range
s as required by the Standard. #2576
is_convertible
and common_reference
, so contiguous_iterator<const volatile int*>
is now true
. #2592
make_any()
, make_optional()
, shared_ptr::operator=()
, shared_ptr::reset()
, and weak_ptr::operator=()
.filesystem::path
's comparison operators and some other member functions being IF-NDR (ill-formed, no diagnostic required) in C++23 mode. #2457
<chrono>
parsing to fail when the input is insufficient to supply the entire format string. #2523
"23:59"
is insufficient for the format string "%H:%M:%S"
.ranges::find()
with unreachable_sentinel
. #2434
[[nodiscard]] friend
) to fix spurious cases of "warning C5240: 'nodiscard': attribute is ignored in this syntactic position". #2622
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
<ranges>
machinery. #2630
<future>
's use of <ppltasks.h>
in Desktop XAML apps. #2654
<chrono>
from parsing fractional seconds as floating-point duration
s. #2638
<bit>
's countl_zero()
returning incorrect results on ARM64 for 8-bit and 16-bit types. #2647
get_time()
and time_get
's 2-digit year logic. #2666
system_category().message()
to behave correctly instead of returning "???"
when the user language and system language are different. #2669
atomic_thread_fence()
and atomic<8-byte type>::store()
. #2702
atomic<shared_ptr<T[]>>
, atomic<shared_ptr<T[N]>>
, atomic<weak_ptr<T[]>>
, and atomic<weak_ptr<T[N]>>
. #1339
<cmath>
's lerp()
for arithmetic types. #2113
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
shared_ptr<void>
, weak_ptr<void>
, and unique_ptr<void, Deleter>
. #2706
move_only_function
when compiling <functional>
in /std:c++latest
mode with /Zc:alignedNew-
. #2712
allocator<void>
. #2726
allocator<void>
is still supported, it just uses the primary template now.__imp___std_init_once_begin_initialize
and __imp___std_init_once_complete
.__imp____std_init_once_begin_initialize@16
and __imp____std_init_once_complete@12
.rotl()
and rotr()
in <bit>
for 8-bit and 16-bit integers by using compiler intrinsics. #2611
reverse()
for 32-bit trivial types. #2383
<format>
performance when the execution character set isn't self-synchronizing, by caching expensive calls to get codepage info. #2600
find()
, count()
, ranges::find()
, and ranges::count()
, with speedups ranging from 2.0x to 27.6x (times, not percent). #2434
<charconv>
floating-point from_chars()
. #2623
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
inclusive_scan()
and transform_inclusive_scan()
. #2662
scoped_allocator_adaptor
's operator==()
. #2677
function
, move_only_function
, and bind()
. #2668
vector<bool>::insert()
. #2694
subtract_with_carry_engine
's internal machinery. #2693
<chrono>
into a smaller internal header, improving throughput when other headers need only pre-C++20 <chrono>
machinery. #2604
<deque>
to use scope guards instead of throw;
, making debugging easier when exceptions are thrown. #2308
constexpr
dynamic allocation and constexpr unique_ptr
. #2658
<format>
grapheme clusterization when determining the width of a string for padding and alignment purposes. This is a "quality of implementation" feature recommended by N4910 [format.string.std]/11
. #2119
<strstream>
to deprecate its classes instead of the entire header. #2680
unexpected()
in <exception>
was removed by C++17. As with almost all removals, we support an escape hatch to restore unexpected()
, by defining _HAS_UNEXPECTED
to 1
. However, this escape hatch conflicts with C++23, which is reusing the identifier for unexpected<E>
in <expected>
. Therefore, the escape hatch is now blocked with an #error
in C++23 mode. #2709
<string>
, allowing additional errors to be detected. #2196
<ciso646>
now emits a warning in C++20 mode, as it was removed in that Standard. #2710
join_view
for non-forward_range
s until LWG-3698 is resolved. #2727
<random>
distributions now have non-const
function call operators, making it easier to write portable code. #2732
ranges
algorithm tests. #2657
/Za
test coverage. #2714
/Za
is "not recommended" and has been superseded by /permissive-
.<stdatomic.h>
for non-compiler tools. #2615
/std:c++20
and /std:c++latest
modes. #2637
format
and validate
targets to CMake, so it can run clang-format in parallel, and improved how Azure Pipelines runs the Code Format Validation check. #2671 #2697
_MSVC_STL_UPDATE
. #2634 #2696
unique_ptr
operator*()
should be noexcept
std::function
construction vs assignmentstd::ref
/cref
ranges::distance()
cannot be used on a move-only iterator with a sized sentinelconvertible-to-non-slicing
seems to reject valid casepolymorphic_allocator::allocate
does not satisfy Cpp17Allocator requirementsdirectory_iterator
and recursive_directory_iterator
are not C++20 ranges<random>
classescounted_iterator
s refer to the same sequence isn't quite rightstatic_cast
expression in convertible_to
has the wrong operandkeys_view
example is brokencommon_iterator
should be completely constexpr
-ableiota_view
's iterator
's binary operator+
should be improvedconst
lvalue reference overload of get
for subrange
does not constrain I
to be copyable
when N == 0
split_view::base() const &
is overconstrainedlazy_split_view<input_view>::
inner-iterator
::base() &&
invalidates outer iteratorslazy_split_view
needs to check the simpleness of Pattern
base() const &
and lazy_split_view::
outer-iterator
::value_type::end()
missing noexcept
proxy
and postfix-proxy
for common_iterator
should be fully constexpr
system_category().default_error_condition(0)
is underspecifiediota_view::size
sometimes rejects integer-class typesstd::format
iter_move
for transform_view::iterator
__cpp_lib_monadic_optional
format
should not print bool
with 'c'
basic_format_context::arg(size_t)
should be noexcept
std::hash<std::filesystem::path>
is not enablediterator_traits<common_iterator>::pointer
should conform to [iterator.traits]
constinit atomic<shared_ptr<T>> a(nullptr);
should workranges::join_view
. #2352
std::string
. #2305
basic_stringbuf
's Buffer. #2361
ranges::clamp
now correctly performs at most three projections. #1898
cl /showIncludes /D__CUDACC__ ...
command used by CUDA's msbuild integration to gather dependencies. #2075
allocator::is_always_equal
to be deprecated, not removed, in C++20 mode. (It was deprecated by LWG-3170.) #2423
begin()
/end()
crashing for empty valarray
s, which also affected range-based for-loops. #2435
ranges::distance
(from LWG-3392 which broke ranges::distance(some_array, s)
) by speculatively implementing LWG-3664. #2522
basic_string::resize_and_overwrite()
to no longer emit "warning C4018: signed/unsigned mismatch" when given certain user-defined function objects. #2525
__cpp_lib_concepts
to its final value for C++20, 202002L
. #2559
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
.libcxx
test suite. #2499
<format>
that sporadically caused incorrect output when formatting floating-point values in hex
or scientific
notation with extremely large precisions. #2569
<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
optional<const T>
now behaves like moving from a const T
: it selects T
's copy constructor. #2460
<format>
that incorrectly accepted volatile
arguments; the Standard currently says that they should be rejected. #2579
rotl()
and rotr()
in <bit>
for 32-bit and 64-bit integers by using compiler intrinsics. #2369
reverse_copy()
's vectorized implementation is now activated (for eligible types) in all Standard modes. Previously, only the C++14/17 modes activated this optimization; C++20/23 modes unintentionally used the plain implementation (correct but slower). #2416
gcd()
and lcm()
. #2343
<format>
performance when the execution character set is self-synchronizing. For example, code page 1252 "ANSI Latin 1; Western European (Windows)" activates this optimization. The /utf-8
compiler option also activates this optimization. #2493
generate_canonical
. #2498
-Wdeprecated-copy
(in product and test code) and -Wunused-but-set-variable
(in test code only). #2266
<vector>
, allowing additional errors to be detected. #2071 #2420 #2464 #2508
allocator::deallocate()
; passing a null pointer with a non-zero size is an error. #2412
aliasobj
) with the linker's /ALTERNATENAME
option (which is strictly more reproducible, although not officially documented). #2381
printf()
, allowing the compiler to check it. #2346
<charconv>
test headers to use include guards, for closer alignment with libc++. #2372
27
and 78
. #2377
friend constexpr
instead of the reverse order. #2419
<ratio>
's implementation by using constexpr
functions instead of template metaprogramming. #2450
INCLUDE
, LIB
, and PATH
after building the repo. #2578
_MSVC_STL_UPDATE
. #2374 #2455 #2519 #2602
<spanstream>
<stdatomic.h>
is currently supported when compiling as C++ (/std:c++latest
). It is not yet supported when compiling as C (/std:c11
and /std:c17
), but support for C atomics is planned for a future release. For more info, see the September 2020 blog post "C11 and C17 Standard Support Arriving in MSVC".basic_string::resize_and_overwrite
volatile
Pointersbyteswap()
stack
And queue
ranges::starts_with
, ranges::ends_with
invoke_r()
span
And basic_string_view
To Be Trivially Copyablenoexcept
For exchange()
counted_iterator
seed_seq
's constructorspriority_queue
iter_move
and iter_swap
are inconsistent for transform_view::
iterator
InputIterator
template parameter for priority_queue
constructorsuses_allocator_construction_args
handles rvalue pairs of rvalue references incorrectlymake_from_tuple
can perform (the equivalent of) a C-style castchrono::from_stream()
assign zero to duration
for failure?common_iterator
's postfix-proxy
is not quite rightview_interface
is overspecified to derive from view_base
chrono::parse
needs const charT*
overloads<complex>
exp()
and polar()
for infinity and NaN inputs. #1584
common_iterator
s of different types for equality. #2066
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
basic_streambuf::seekoff()
and basic_streambuf::seekpos()
to work with custom pos_type
s. #2121
string_view
is trivially move constructible. #2128
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
<format>
to correctly print hexfloats with large precisions. #2157
constexpr
vector
s with certain user-defined allocators. #2161
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
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
<limits>
. #2306
fstream
when calling putback()
followed by close()
. #2189
views::reverse
to work properly with ranges::reverse_view
lvalues. #2313
/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
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
basic_string
. These changes were specified by P1148R0 "Cleaning Up [strings]
", which was almost a pure rewording paper without normative impact. Oops! #2222
ranges::find_end()
to return correct values for bidirectional common ranges. #2270
ranges::sort()
, ranges::search()
, and other ranges machinery. #2290
array<T, 0>
, allowing it to compile when T
is not default constructible. #2296
allocator::allocate_at_least()
which was improperly annotated with __declspec(allocator)
. #2328
steady_clock::now()
when QueryPerformanceFrequency()
is exactly 10 MHz, which is very common for modern PCs. #2086
popcount()
, which is used when compiler intrinsics are unavailable (and is also used at compile time). #2079
<format>
prints a pointer in hexadecimal. #2097
<ranges>
non-propagating-cache
for trivially destructible types. #2118
popcount()
, using compiler intrinsics. #2127
memcpy()
, memmove()
, and memcmp()
optimizations in various algorithms to handle more types. #2158
bitset::count()
by using the same machinery as popcount()
. #2201
std::count()
for vector<bool>
by using popcount()
machinery in a more optimizer-friendly way. #2203
weak_ptr
's converting constructors now avoid locking except when necessary to ensure correctness in virtual inheritance scenarios. #2282
weak_ptr<T>
to weak_ptr<const T>
now avoids locking.filesystem::create_directories()
. #2304
is_permutation()
for reversed sequences. #2043
numeric_limits<long double>::max_digits10
to handle both 64-bit and 80-bit long double
, by restoring the original logic that was used before VS 2017 15.8.
long double
remains unsupported by MSVC.#error
messages when they're compiled as C. #2148
<vector>
and the "C++ headers for C library facilities" like <cstdio>
.binary_semaphore
's debug check messages. #2293
basic_string_view
not trivially move constructible" in our implementation of its proposed resolution. #2175
BUILTIN-PTR-MEOW
should not opt the type out of syntactic checks" has been officially resolved by the June 2021 virtual plenary meeting. #2186
constructible_from
test case that was invalidated by recent changes to the Core Language. #2107
next_permutation()
and prev_permutation()
; the algorithms were fine, but the test never worked and was never called. #2137
/arch:AVX2
to the matrix of compiler options that's used when testing <bit>
. #2150
tr1
test suite. #2202
tr1
test suite that were generating collisions between temporary filenames. #2210
<chrono>
formatting test failures related to locale-dependent time zone abbreviations. #2231
struct
from a central internal header to <optional>
. #2117
operator>>(basic_istream&&, basic_string&)
. This didn't affect correctness, but it was neither necessary nor depicted by the Standard. #2138
exception_ptr
's operators for C++20 and emitting a clear error message when compiling <stdatomic.h>
as C. #2140
<cctype>
that was attempting to defend against macroized isalnum
etc. #2147
reinterpret_cast
, and changed some reinterpret_cast
s from void*
to T*
to use static_cast
instead. #2096
_HAS_CXX23
from our central internal header yvals_core.h
. #2226
(void)
casts now that MSVC emits fewer spurious warnings about unreferenced parameters. #2280
_MSVC_STL_UPDATE
. #2183 #2233 #2321
is_scoped_enum
out_ptr()
, inout_ptr()
contains()
For basic_string
/basic_string_view
to_underlying()
For Enumerationspair
's Forwarding Constructorstring_view
variant
basic_string
And basic_string_view
Construction From nullptr
std::fstream
& co. should be constructible from string_view
elements_view
should not be allowed to return dangling referencesbase() const &
consistent across iterator wrappers that support input_iterator
sindirectly_readable_traits
should be SFINAE-friendly for all typesshared_ptr
construction from unique_ptr
should move (not copy) the deletersplit_view::
outer-iterator
::value_type::begin()
{transform,elements}_view::
iterator
::iterator_concept
should consider const
-qualification of the underlying rangetime_put::do_put
to avoid crashing when the invalid parameter handler has been changed to not end execution. #1563
ranges::take_view
. #1844
ranges::unique_copy
would fail to compile with a non-input output iterator. #1933
format_to()
in a specialization of formatter
(see #1961 for an example). #1874
views::drop
and views::take
with types that aren't integers, but are convertible to integers (e.g. integral_constant
). #1958
constexpr
vector::emplace(position, args...)
. #1962
jthread
to provide native_handle()
. #1966
filesystem::remove()
to delete read-only files, as required by the Standard. #1559
mersenne_twister_engine
: #1631
m == n
or n == 1
. (This is a compile-time special case, which doesn't affect mt19937
and mt19937_64
at all.)operator<<()
to avoid printing a trailing space after the engine's textual representation.<chrono>
to adjust for leap seconds when formatting file_time
. #1879
chrono::from_stream()
to allow a year and a day-of-year to be parsed to a time_point
. #1940
filesystem::u8path()
to accept char8_t
sources. #1943
<chrono>
to parse subseconds for time_point
s. #1987
local_time
with a UTC offset.<chrono>
formatting to correctly estimate string widths (see N4892 [format.string.std]/9). #2017
_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
pmr::map<K, pair<A, B>>::operator[]
. #2023
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
<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
vector<bool>
, basic_string
, and map
/multimap
/set
/multiset
's empty()
member functions. #1836
<format>
. #1874
std::find()
and std::count()
for vector<bool>
, with measured speedups between 19x and 26x (times, not percent). #1131
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
std::swap_ranges()
to ranges::swap_ranges()
, and enhanced it to work for arbitrary contiguous iterators. #2048
<format>
and <chrono>
now avoid including <array>
. #2031
source_location
. #1837
[[nodiscard]]
to the stoi()
family of functions in <string>
and to various functions in <locale>
(collate
member functions, has_facet()
, and the isalnum()
and tolower()
families). #1809
forward_list::splice_after()
. #2057
bind_front()
, u8string
(and its iterators), default_sentinel_t
, unreachable_sentinel_t
, ranges::empty_view
, ranges::single_view
, ranges::iota_view
(and its iterator/sentinel), ranges::ref_view
, thread
, thread::id
, jthread
, and filesystem::path
. #1856
span
and basic_string_view
are trivially copyable; P2251 may eventually Standardize these guarantees. #2015
std::basic_common_reference
; it was unintentionally relying on identical bugs in MSVC and Clang, but EDG correctly diagnosed that the code was non-Standard. #2013
abs()
overloads in <cmath>
and <cstdlib>
) that unintentionally hadn't been running in our new GitHub test harness. #2070
_Pragma
instead of non-Standard __pragma
(when possible) to internally suppress warnings. #1342
<format>
now uses _First
/_Last
parameter names (instead of _Begin
/_End
) to be consistent with the rest of the STL. (The connotations are that first/last refers to an arbitrary range that might be a subrange, while begin/end refers to an entire container/view.) #1951
vector
's implementation, also using if constexpr
to simplify code. #1771
<format>
's implementation of type-erased argument storage. #1907
operator<=>(optional<T>, U)
" and updated our implementation's comment accordingly. #2011
char_traits::move()
. #2055
override
, and removed redundant virtual
keywords. #2069
// CLASS TEMPLATE vector
; SEE #306 FOR THE RATIONALE. #2074
char_traits::move()
. #2083
/ZH:SHA_256
switch to improve supply chain integrity. #1829
_MSVC_STL_UPDATE
. Also updated _MSVC_STL_VERSION
to 143
for the VS 2022 release series. #1897 #1955 #2035 #2091