blob: 99f5c6f0590ab53362256a610d8c4ab66927b64e [file] [log] [blame]
Richard Smith87bb5692015-06-09 00:35:49 +00001// RUN: rm -rf %t
2// RUN: %clang_cc1 -fmodules -verify -fmodules-cache-path=%t -I %S/Inputs/template-default-args -std=c++11 %s
Richard Smith87bb5692015-06-09 00:35:49 +00003
4template<typename T> struct A;
5template<typename T> struct B;
6template<typename T> struct C;
7template<typename T = int> struct D;
Richard Smithe7bd6de2015-06-10 20:30:23 +00008template<typename T = int> struct E {};
Richard Smith95d83952015-06-10 20:36:34 +00009template<typename T> struct H {}; // expected-note {{here}}
Richard Smith87bb5692015-06-09 00:35:49 +000010
11#include "b.h"
12
13template<typename T = int> struct A {};
14template<typename T> struct B {};
15template<typename T = int> struct B;
16template<typename T = int> struct C;
17template<typename T> struct D {};
Richard Smithe7bd6de2015-06-10 20:30:23 +000018template<typename T> struct F {};
Richard Smith95d83952015-06-10 20:36:34 +000019template<typename T> struct G {}; // expected-note {{here}}
Richard Smithe7bd6de2015-06-10 20:30:23 +000020
21#include "c.h"
Richard Smith87bb5692015-06-09 00:35:49 +000022
23A<> a;
24B<> b;
25extern C<> c;
26D<> d;
Richard Smithe7bd6de2015-06-10 20:30:23 +000027E<> e;
28F<> f;
Richard Smith95d83952015-06-10 20:36:34 +000029G<> g; // expected-error {{too few}}
30H<> h; // expected-error {{too few}}