llvm-project/libcxx/test/std/containers/sequences/list
Konstantin Varlamov 7da4ee6f23 [libcxx][NFC] Make sequence containers slightly more SFINAE-friendly during CTAD.
Disable the constructors taking `(size_type, const value_type&,
allocator_type)` if `allocator_type` is not a valid allocator.
Otherwise, these constructors are considered when resolving e.g.
`(int*, int*, NotAnAllocator())`, leading to a hard error during
instantiation. A hard error makes the Standard's requirement to not
consider deduction guides of the form `(Iterator, Iterator,
BadAllocator)` during overload resolution essentially non-functional.

The previous approach was to SFINAE away `allocator_traits`. This patch
SFINAEs away the specific constructors instead, for consistency with
`basic_string` -- see [LWG3076](wg21.link/lwg3076) which describes
a very similar problem for strings (note, however, that unlike LWG3076,
no valid constructor call is affected by the bad instantiation).

Differential Revision: https://reviews.llvm.org/D114311
2021-12-01 11:56:51 -08:00
..
list.capacity [libc++] Remove "// -*- C++ -*-" comments from all .cpp files. NFCI. 2021-10-01 12:06:59 -04:00
list.cons [libcxx][NFC] Make sequence containers slightly more SFINAE-friendly during CTAD. 2021-12-01 11:56:51 -08:00
list.erasure [libc++] Remove the c++98 Lit feature from the test suite 2020-06-03 09:37:22 -04:00
list.modifiers [libc++] Use addressof in list. 2021-11-11 18:56:08 +01:00
list.ops [libc++] Use addressof in list. 2021-11-11 18:56:08 +01:00
list.special [libcxx][NFC] Make sequence containers slightly more SFINAE-friendly during CTAD. 2021-12-01 11:56:51 -08:00
allocator_mismatch.compile.fail.cpp [libc++] Remove workaround for .fail.cpp tests that don't have clang-verify markup 2020-04-15 10:53:37 -04:00
compare.pass.cpp [libcxx][test][NFC] More tests for containers comparisons 2021-11-03 16:15:10 +03:00
get_allocator.pass.cpp [libcxx][test][NFC] Extend get_allocator() testing for containers 2021-12-01 16:15:19 +03:00
incomplete_type.pass.cpp
iterator_concept_conformance.compile.pass.cpp [libc++] Remove Lit annotations for unsupported GCC versions from the test suite 2021-08-12 13:30:47 -04:00
iterators.pass.cpp
range_concept_conformance.compile.pass.cpp [libc++][NFC] Replace uses of stdr:: by just std::ranges:: 2021-09-02 13:02:12 -04:00
types.pass.cpp [libc++] Translate MODULES_DEFINES annotations to ADDITIONAL_COMPILE_FLAGS 2020-04-07 14:40:49 -04:00