Author: sebor
Date: Mon Jul 14 19:15:20 2008
New Revision: 676788
URL: http://svn.apache.org/viewvc?rev=676788&view=rev
Log:
2008-07-14 Martin Sebor <[EMAIL PROTECTED]>
* etc/config/src/INITIALIZER_LIST.cpp: New config test to determine
whether the C++ 0x class template std::initializer_list is supported.
Added:
stdcxx/branches/4.3.x/etc/config/src/INITIALIZER_LIST.cpp (with props)
Added: stdcxx/branches/4.3.x/etc/config/src/INITIALIZER_LIST.cpp
URL:
http://svn.apache.org/viewvc/stdcxx/branches/4.3.x/etc/config/src/INITIALIZER_LIST.cpp?rev=676788&view=auto
==============================================================================
--- stdcxx/branches/4.3.x/etc/config/src/INITIALIZER_LIST.cpp (added)
+++ stdcxx/branches/4.3.x/etc/config/src/INITIALIZER_LIST.cpp Mon Jul 14
19:15:20 2008
@@ -0,0 +1,14 @@
+// checking for std::initializer_list<T>
+
+#include <initializer_list>
+
+// see if the initializer_list feature is implemented
+int main ()
+{
+ std::initializer_list<int> il = { 1, 2, 3, 4 };
+
+ if (4 == il.size () && 1 == *il.begin () && 4 == *(il.end () - 1))
+ return 0; // success
+
+ return 1; // failure
+}
Propchange: stdcxx/branches/4.3.x/etc/config/src/INITIALIZER_LIST.cpp
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: stdcxx/branches/4.3.x/etc/config/src/INITIALIZER_LIST.cpp
------------------------------------------------------------------------------
svn:keywords = Id