[clang][modules] Don't prevent translation of FW_Private includes when explicitly...
[llvm-project.git] / clang / test / CXX / temp / temp.spec / temp.expl.spec / p19.cpp
blob16666d185b06eadf575375dba95b1595888c4ec9
1 // RUN: %clang_cc1 -fsyntax-only -verify %s
3 template<typename T>
4 struct X {
5 template<typename U> struct Inner { };
7 template<typename U> void f(T, U) { }
8 };
10 template<> template<typename U>
11 struct X<int>::Inner {
12 U member;
15 template<> template<typename U>
16 void X<int>::f(int x, U y) {
17 x = y; // expected-error{{incompatible pointer to integer conversion}}
20 void test(X<int> xi, X<long> xl, float *fp) {
21 X<int>::Inner<float*> xii;
22 xii.member = fp;
23 xi.f(17, 25);
24 xi.f(17, 3.14159);
25 xi.f(17, fp); // expected-note{{instantiation}}
26 X<long>::Inner<float*> xli;
28 xli.member = fp; // expected-error{{no member}}
29 xl.f(17, fp); // okay