summaryrefslogtreecommitdiffstats
path: root/Tests
diff options
context:
space:
mode:
authorStephen Kelly <steveire@gmail.com>2014-04-06 08:17:15 (GMT)
committerStephen Kelly <steveire@gmail.com>2014-04-08 09:05:57 (GMT)
commit9a49fd21bedacdda51ecfa82a15a0e52dd64948f (patch)
treee96a14650a1088088c4f8c14e6249e785a58f926 /Tests
parent1889045ca672e295c18203401c27a9e62ff45424 (diff)
downloadCMake-9a49fd21bedacdda51ecfa82a15a0e52dd64948f.zip
CMake-9a49fd21bedacdda51ecfa82a15a0e52dd64948f.tar.gz
CMake-9a49fd21bedacdda51ecfa82a15a0e52dd64948f.tar.bz2
Features: Add cxx_decltype_incomplete_return_types.
Diffstat (limited to 'Tests')
-rw-r--r--Tests/CompileFeatures/cxx_decltype_incomplete_return_types.cpp14
1 files changed, 14 insertions, 0 deletions
diff --git a/Tests/CompileFeatures/cxx_decltype_incomplete_return_types.cpp b/Tests/CompileFeatures/cxx_decltype_incomplete_return_types.cpp
new file mode 100644
index 0000000..109d038
--- /dev/null
+++ b/Tests/CompileFeatures/cxx_decltype_incomplete_return_types.cpp
@@ -0,0 +1,14 @@
+
+template<class T>
+struct A
+{
+ ~A() = delete;
+};
+
+template<class T> auto h() -> A<T>;
+template<class T> auto i(T) -> T;
+template<class T> auto f(T) -> decltype(i(h<T>()));
+template<class T> auto f(T) -> void;
+auto g() -> void {
+ f(42);
+}