xref: /llvm-project/clang/test/CXX/temp/temp.param/p15.cpp (revision 205d0445529eb985a1485ff8e2a18908f75f3bb1)
18fbe78f6SDaniel Dunbar // RUN: %clang_cc1 -fsyntax-only -std=c++98 -verify %s
2a5d5c749SDouglas Gregor template<typename T> struct X;
3a5d5c749SDouglas Gregor template<int I> struct Y;
4a5d5c749SDouglas Gregor 
5a5d5c749SDouglas Gregor X<X<int> > *x1;
6a5d5c749SDouglas Gregor X<X<int>> *x2; // expected-error{{a space is required between consecutive right angle brackets (use '> >')}}
7a5d5c749SDouglas Gregor 
8a5d5c749SDouglas Gregor X<X<X<X<int>> // expected-error{{a space is required between consecutive right angle brackets (use '> >')}}
9a5d5c749SDouglas Gregor     >> *x3;   // expected-error{{a space is required between consecutive right angle brackets (use '> >')}}
10a5d5c749SDouglas Gregor 
11a5d5c749SDouglas Gregor Y<(1 >> 2)> *y1;
12*205d0445SDouglas Gregor Y<1 >> 2> *y2; // expected-warning{{use of right-shift operator ('>>') in template argument will require parentheses in C++11}}
13