Ne.app NeANT
The Ne.app NeANT User module of the NeANT distribution.
INITIALIZER_LIST.cpp
Go to the documentation of this file.
1// checking for std::initializer_list<T>
2
3#include <initializer_list>
4
5// see if the initializer_list feature is implemented
6int main ()
7{
8 std::initializer_list<int> il = { 1, 2, 3, 4 };
9
10 if (4 == il.size () && 1 == *il.begin () && 4 == *(il.end () - 1))
11 return 0; // success
12
13 return 1; // failure
14}
int main()