File tree Expand file tree Collapse file tree 4 files changed +6
-6
lines changed Expand file tree Collapse file tree 4 files changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -80,7 +80,7 @@ TEST(GetDeducedType, KwAutoKwDecltypeExpansion) {
80
80
namespace std
81
81
{
82
82
template<class _E>
83
- class [[initializer_list]] {};
83
+ class [[initializer_list]] { const _E *a, *b; };
84
84
}
85
85
86
86
^auto i = {1,2};
Original file line number Diff line number Diff line change @@ -771,7 +771,7 @@ TEST(LocateSymbol, All) {
771
771
namespace std
772
772
{
773
773
template<class _E>
774
- class [[initializer_list]] {};
774
+ class [[initializer_list]] { const _E *a, *b; };
775
775
}
776
776
777
777
^auto i = {1,2};
Original file line number Diff line number Diff line change @@ -534,7 +534,7 @@ TEST(WalkAST, Enums) {
534
534
TEST (WalkAST, InitializerList) {
535
535
testWalk (R"cpp(
536
536
namespace std {
537
- template <typename T> struct $implicit^initializer_list {};
537
+ template <typename T> struct $implicit^initializer_list { const T *a, *b; };
538
538
})cpp" ,
539
539
R"cpp(
540
540
const char* s = "";
Original file line number Diff line number Diff line change 5
5
6
6
namespace std {
7
7
8
- typedef decltype (sizeof 0 ) size_t;
8
+ // FIXME: This doesn't work if size_t is not a signed type
9
+ typedef int size_t ;
9
10
10
11
template <class E > class initializer_list {
11
12
public:
@@ -15,8 +16,7 @@ template<class E> class initializer_list {
15
16
using size_type = size_t ;
16
17
using iterator = const E*;
17
18
using const_iterator = const E*;
18
- iterator ptr;
19
- size_type sz;
19
+ iterator first, last;
20
20
initializer_list ();
21
21
size_t size () const ; // number of elements
22
22
const E* begin () const ; // first element
You can’t perform that action at this time.
0 commit comments