aboutsummaryrefslogtreecommitdiffstats
path: root/test/SemaCXX
diff options
context:
space:
mode:
Diffstat (limited to 'test/SemaCXX')
-rw-r--r--test/SemaCXX/constructor.cpp11
1 files changed, 11 insertions, 0 deletions
diff --git a/test/SemaCXX/constructor.cpp b/test/SemaCXX/constructor.cpp
index 105605c6e37b..33ea49663491 100644
--- a/test/SemaCXX/constructor.cpp
+++ b/test/SemaCXX/constructor.cpp
@@ -86,3 +86,14 @@ A::S::operator int() { return 1; }
A::S::~S() {}
+namespace PR38286 {
+ // FIXME: It'd be nice to give more consistent diagnostics for these cases
+ // (but they're all failing for somewhat different reasons...).
+ template<typename> struct A;
+ template<typename T> A<T>::A() {} // expected-error {{incomplete type 'A' named in nested name specifier}}
+ /*FIXME: needed to recover properly from previous error*/;
+ template<typename> struct B;
+ template<typename T> void B<T>::f() {} // expected-error {{out-of-line definition of 'f' from class 'B<type-parameter-0-0>'}}
+ template<typename> struct C;
+ template<typename T> C<T>::~C() {} // expected-error {{no type named 'C' in 'C<type-parameter-0-0>'}}
+}