Debian Codegraph @

gcc/testsuite/g++.dg/cpp0x/initlist-array19.C

raw
1 // PR c++/108773
2 // { dg-do compile { target c++20 } }
3
4 #include <initializer_list>
5
6 namespace std {
7 template <typename _Tp, int _Nm> struct array {
8 _Tp _M_elems[_Nm];
9 };
10 template <typename _Tp> struct list { void operator=(initializer_list<_Tp>); };
11 struct allocator {};
12 struct basic_string {
13 int _M_p;
14 constexpr basic_string() {}
15 basic_string(const char *, const allocator & = allocator());
16 ~basic_string();
17 };
18 } // namespace std
19
20 std::list<std::array<std::basic_string, 3>> stuff;
21 void foo() {
22 stuff = {{"", ""}, {"", ""}};
23 }