Created on 2022-11-03.00:00:00 last changed 17 months ago
Proposed resolution (approved by CWG 2022-11-08):
Change in 13.10.3.1 [temp.deduct.general] bullet 11.8 as follows:
template <class T, T> struct S {}; template <class T> int f(S<T,-- end example ]T()T{}>*); // #1 class X { int m; }; int i0 = f<X>(0); // #1 uses a value of non-structural type X as a non-type template argument
[Accepted as a DR at the November, 2022 meeting.]
The example intends to illustrate that a class type cannot be the type of a non-type template parameter (although the example is still ill-formed because "T()" is interpreted as a function type).
History | |||
---|---|---|---|
Date | User | Action | Args |
2023-07-16 13:00:43 | admin | set | status: open -> c++23 |
2023-07-16 13:00:43 | admin | set | status: drwp -> open |
2023-02-18 18:43:04 | admin | set | status: dr -> drwp |
2022-11-25 05:14:04 | admin | set | status: nb -> dr |
2022-11-08 20:26:48 | admin | set | status: open -> nb |
2022-11-08 20:26:48 | admin | set | status: open -> open |
2022-11-08 20:26:48 | admin | set | status: open -> open |
2022-11-08 20:26:48 | admin | set | status: open -> open |
2022-11-08 20:26:48 | admin | set | messages: + msg6987 |
2022-11-08 13:46:41 | admin | set | status: nb -> open |
2022-11-08 13:46:41 | admin | set | status: nb -> nb |
2022-11-08 13:46:41 | admin | set | status: nb -> nb |
2022-11-03 00:00:00 | admin | create |