blob: 93246b5f03fd4bf7492efd777e49500cb6172bb5 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
|
// RUN: %clang_cc1 %s -verify -std=c++20
namespace std {
template<class T, class = T::x> // expected-error 2 {{type 'int' cannot be used prior to '::' because it has no members}}
class initializer_list;
}
namespace gh132256 {
auto x = {1}; // expected-note {{in instantiation of default argument for 'initializer_list<int>' required here}}
void f() {
for(int x : {1, 2}); // expected-note {{in instantiation of default argument for 'initializer_list<int>' required here}}
}
}
|