aboutsummaryrefslogtreecommitdiff
path: root/test/SemaCXX/cxx0x-return-init-list.cpp
diff options
context:
space:
mode:
authorSebastian Redl <sebastian.redl@getdesigned.at>2012-02-22 10:50:08 +0000
committerSebastian Redl <sebastian.redl@getdesigned.at>2012-02-22 10:50:08 +0000
commit33deb35535aebe81bed0eaf5c14f3032276a086e (patch)
tree1a6b786fd11d1fd4d8c083f85419739e12012c4b /test/SemaCXX/cxx0x-return-init-list.cpp
parent76517426dc8bf7734c07eefc35171a6bfdba1a2b (diff)
Fix parsing and processing initializer lists in return statements and as direct member initializers.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@151155 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/SemaCXX/cxx0x-return-init-list.cpp')
-rw-r--r--test/SemaCXX/cxx0x-return-init-list.cpp10
1 files changed, 4 insertions, 6 deletions
diff --git a/test/SemaCXX/cxx0x-return-init-list.cpp b/test/SemaCXX/cxx0x-return-init-list.cpp
index b786922b71..b2cb3d37ce 100644
--- a/test/SemaCXX/cxx0x-return-init-list.cpp
+++ b/test/SemaCXX/cxx0x-return-init-list.cpp
@@ -1,17 +1,15 @@
// RUN: %clang_cc1 -fsyntax-only -verify %s
-// This test checks for a teeny tiny subset of the functionality in
-// the C++11 generalized initializer lists feature, which happens to
-// be used in libstdc++ 4.5. We accept only this syntax so that Clang
-// can handle the libstdc++ 4.5 headers.
+// Test that a very basic variation of generalized initializer returns (that
+// required for libstdc++ 4.5) is supposed in C++98.
int test0(int i) {
- return { i }; // expected-warning{{generalized initializer lists are a C++11 extension unsupported in Clang}}
+ return { i }; // expected-warning{{generalized initializer lists are a C++11 extension}}
}
template<typename T, typename U>
T test1(U u) {
- return { u }; // expected-warning{{generalized initializer lists are a C++11 extension unsupported in Clang}}
+ return { u }; // expected-warning{{generalized initializer lists are a C++11 extension}}
}
template int test1(char);