Created on 2023-08-29.00:00:00 last changed 13 months ago
Proposed resolution:
This wording is relative to N4958.
Modify [tuple.tuple] as indicated:
namespace std { template<class... Types> class tuple { […] }; […] }
-?- If a program declares an explicit or partial specialization of tuple, the program is ill-formed, no diagnostic required.
Modify [variant.variant.general] as indicated:
[…]
-3- A program that instantiates the definition of variant with no template arguments is ill-formed. -?- If a program declares an explicit or partial specialization of variant, the program is ill-formed, no diagnostic required.
[ 2023-11-11 Approved at November 2023 meeting in Kona. Status changed: Voting → WP. ]
[ 2023-11-02; Reflector poll ]
Set status to Tentatively Ready after five votes in favour during reflector poll.
Currently, program-defined specializations of std::tuple and std::variant are not explicitly disallowed. However, they can't be properly supported by standard library implementations, because the corresponding std::get function templates have to inspect the implementation details of these types, and users have no way to make std::get behave correctly for a program-defined specializations.
Perhaps we should explicitly disallow specializing std::tuple and std::variant.History | |||
---|---|---|---|
Date | User | Action | Args |
2023-11-13 14:08:10 | admin | set | messages: + msg13854 |
2023-11-13 14:08:10 | admin | set | status: voting -> wp |
2023-11-07 21:41:54 | admin | set | status: ready -> voting |
2023-11-03 18:08:35 | admin | set | messages: + msg13814 |
2023-11-03 18:08:35 | admin | set | status: new -> ready |
2023-10-03 10:24:56 | admin | set | messages: + msg13747 |
2023-08-29 00:00:00 | admin | create |