summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJohn McCall <rjmccall@apple.com>2010-04-29 01:20:45 +0000
committerJohn McCall <rjmccall@apple.com>2010-04-29 01:20:45 +0000
commit17b61785a35a02991450bf12b89f2872af8b5c47 (patch)
treeef8f1c7d294a6f5e381969c4b39059caeaf0b75b
parente23b871c4b8c01aa4f18423727ef9a7e1afb5e21 (diff)
downloadbcm5719-llvm-17b61785a35a02991450bf12b89f2872af8b5c47.tar.gz
bcm5719-llvm-17b61785a35a02991450bf12b89f2872af8b5c47.zip
Test case for r102578.
llvm-svn: 102580
-rw-r--r--clang/test/CXX/class.access/p6.cpp14
1 files changed, 14 insertions, 0 deletions
diff --git a/clang/test/CXX/class.access/p6.cpp b/clang/test/CXX/class.access/p6.cpp
index 814265d0b04..734a4d8c486 100644
--- a/clang/test/CXX/class.access/p6.cpp
+++ b/clang/test/CXX/class.access/p6.cpp
@@ -105,3 +105,17 @@ namespace test3 {
Outer::A<B, Blue>::foo(); // expected-error {{no member named 'foo'}}
}
}
+
+namespace test4 {
+ template <class T> class A {
+ private: typedef int type;
+ template <class U> friend void foo(U &, typename U::type);
+ };
+
+ template <class U> void foo(U &, typename U::type) {}
+
+ void test() {
+ A<int> a;
+ foo(a, 0);
+ }
+}
OpenPOWER on IntegriCloud