xref: /minix3/external/bsd/llvm/dist/clang/test/Parser/cuda-kernel-call-c++11.cu (revision 0a6a1f1d05b60e214de2f05a7310ddd1f0e590e7)
1*0a6a1f1dSLionel Sambuc // RUN: %clang_cc1 -fsyntax-only -std=c++11 -verify %s
2*0a6a1f1dSLionel Sambuc 
3*0a6a1f1dSLionel Sambuc template<typename> struct S {};
4*0a6a1f1dSLionel Sambuc template<typename> void f();
5*0a6a1f1dSLionel Sambuc 
6*0a6a1f1dSLionel Sambuc 
foo(void)7*0a6a1f1dSLionel Sambuc void foo(void) {
8*0a6a1f1dSLionel Sambuc   // In C++11 mode, all of these are expected to parse correctly, and the CUDA
9*0a6a1f1dSLionel Sambuc   // language should not interfere with that.
10*0a6a1f1dSLionel Sambuc 
11*0a6a1f1dSLionel Sambuc   // expected-no-diagnostics
12*0a6a1f1dSLionel Sambuc 
13*0a6a1f1dSLionel Sambuc   S<S<S<int>>> s3;
14*0a6a1f1dSLionel Sambuc 
15*0a6a1f1dSLionel Sambuc   S<S<S<S<int>>>> s4;
16*0a6a1f1dSLionel Sambuc 
17*0a6a1f1dSLionel Sambuc   S<S<S<S<S<int>>>>> s5;
18*0a6a1f1dSLionel Sambuc 
19*0a6a1f1dSLionel Sambuc   (void)(&f<S<S<int>>>==0);
20*0a6a1f1dSLionel Sambuc }
21