summaryrefslogtreecommitdiffstats
path: root/clang/test/SemaTemplate/current-instantiation.cpp
diff options
context:
space:
mode:
authorDouglas Gregor <dgregor@apple.com>2011-02-19 19:24:40 +0000
committerDouglas Gregor <dgregor@apple.com>2011-02-19 19:24:40 +0000
commitbf2b26d805d62ea214c96eac6bfd806ad733fe64 (patch)
treeaf06840c7029d8960f65b0e68a2100c097679501 /clang/test/SemaTemplate/current-instantiation.cpp
parent479d6f51e33a95d955be7c62087b7fa375b37b54 (diff)
downloadbcm5719-llvm-bf2b26d805d62ea214c96eac6bfd806ad733fe64.tar.gz
bcm5719-llvm-bf2b26d805d62ea214c96eac6bfd806ad733fe64.zip
The member classes of a current instantiation aren't necessarily a
current instantiation, even though we have a RecordDecl describing them. Fixes PR9255. Amusingly, I've had this patch sitting around for a month or two because it was "obviously" wrong, but hadn't gotten around to writing a test case to submit the fix :) llvm-svn: 126038
Diffstat (limited to 'clang/test/SemaTemplate/current-instantiation.cpp')
-rw-r--r--clang/test/SemaTemplate/current-instantiation.cpp16
1 files changed, 16 insertions, 0 deletions
diff --git a/clang/test/SemaTemplate/current-instantiation.cpp b/clang/test/SemaTemplate/current-instantiation.cpp
index 8caac9399a8..fe7213f1438 100644
--- a/clang/test/SemaTemplate/current-instantiation.cpp
+++ b/clang/test/SemaTemplate/current-instantiation.cpp
@@ -199,3 +199,19 @@ namespace Expressions {
typename Enable_If<Is_Same<U, Class<T> >::value, void>::type
Class<T>::foo() {}
}
+
+namespace PR9255 {
+ template<typename T>
+ class X0 {
+ public:
+ class Inner1;
+
+ class Inner2 {
+ public:
+ void f()
+ {
+ Inner1::f.g();
+ }
+ };
+ };
+}
OpenPOWER on IntegriCloud