summaryrefslogtreecommitdiffstats
path: root/clang/test/Parser/cxx-template-decl.cpp
diff options
context:
space:
mode:
authorRichard Smith <richard-llvm@metafoo.co.uk>2014-06-16 15:51:22 +0000
committerRichard Smith <richard-llvm@metafoo.co.uk>2014-06-16 15:51:22 +0000
commit78e1ca692bf07944c5d35dabb58be10bae640a51 (patch)
tree5593ba65d0cd85577a117827226cf4f5e0b21066 /clang/test/Parser/cxx-template-decl.cpp
parentdbd4d4c8375ee79dd9da290695f292ddcb65c3d3 (diff)
downloadbcm5719-llvm-78e1ca692bf07944c5d35dabb58be10bae640a51.tar.gz
bcm5719-llvm-78e1ca692bf07944c5d35dabb58be10bae640a51.zip
[C++1z] Implement N4051: 'typename' is permitted instead of 'class' when declaring a template template parameter.
llvm-svn: 211031
Diffstat (limited to 'clang/test/Parser/cxx-template-decl.cpp')
-rw-r--r--clang/test/Parser/cxx-template-decl.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/clang/test/Parser/cxx-template-decl.cpp b/clang/test/Parser/cxx-template-decl.cpp
index 87429001223..8b2b12037b3 100644
--- a/clang/test/Parser/cxx-template-decl.cpp
+++ b/clang/test/Parser/cxx-template-decl.cpp
@@ -1,5 +1,6 @@
// RUN: %clang_cc1 -fsyntax-only -verify %s
// RUN: %clang_cc1 -fsyntax-only -verify %s -fdelayed-template-parsing -DDELAYED_TEMPLATE_PARSING
+// RUN: %clang_cc1 -fsyntax-only -verify -std=gnu++1z %s
@@ -24,6 +25,11 @@ template <template X> struct Err1; // expected-error {{expected '<' after 'templ
template <template <typename> > struct Err2; // expected-error {{template template parameter requires 'class' after the parameter list}}
template <template <typename> Foo> struct Err3; // expected-error {{template template parameter requires 'class' after the parameter list}}
+template <template <typename> typename Foo> struct Cxx1z;
+#if __cplusplus <= 201402L
+// expected-warning@-2 {{extension}}
+#endif
+
// Template function declarations
template <typename T> void foo();
template <typename T, typename U> void foo();
OpenPOWER on IntegriCloud