| 1 |
// PR c++/92965 |
| 2 |
// { dg-do compile { target c++20 } } |
| 3 |
|
| 4 |
template<int> |
| 5 |
class TS { |
| 6 |
int x; // { dg-bogus "is not public" } |
| 7 |
public: |
| 8 |
constexpr TS(int) {} |
| 9 |
}; |
| 10 |
TS(int) -> TS<1>; |
| 11 |
|
| 12 |
template<TS> void foo() {} |
| 13 |
template<int> void foo() {} |
| 14 |
|
| 15 |
void test() { foo<2>(); } |