summaryrefslogtreecommitdiffstats
path: root/clang/test/SemaTemplate/nested-name-spec-template.cpp
diff options
context:
space:
mode:
authorDouglas Gregor <dgregor@apple.com>2010-06-17 16:03:49 +0000
committerDouglas Gregor <dgregor@apple.com>2010-06-17 16:03:49 +0000
commitffa20398a6c0c04a24133fdd7ef0a5bb6475a8e8 (patch)
tree0e620e6df15dea11ee201ffd0645578b0ecb0a73 /clang/test/SemaTemplate/nested-name-spec-template.cpp
parent630dec57a2af38cd240b5b124704501df8bb9d64 (diff)
downloadbcm5719-llvm-ffa20398a6c0c04a24133fdd7ef0a5bb6475a8e8.tar.gz
bcm5719-llvm-ffa20398a6c0c04a24133fdd7ef0a5bb6475a8e8.zip
When pushing a copy of the TypeLoc information for a dependent
template specialization type, copy the location information but use the new type. Fixes PR7385. llvm-svn: 106224
Diffstat (limited to 'clang/test/SemaTemplate/nested-name-spec-template.cpp')
-rw-r--r--clang/test/SemaTemplate/nested-name-spec-template.cpp16
1 files changed, 16 insertions, 0 deletions
diff --git a/clang/test/SemaTemplate/nested-name-spec-template.cpp b/clang/test/SemaTemplate/nested-name-spec-template.cpp
index e1e7246bd7e..12ab4868091 100644
--- a/clang/test/SemaTemplate/nested-name-spec-template.cpp
+++ b/clang/test/SemaTemplate/nested-name-spec-template.cpp
@@ -72,3 +72,19 @@ namespace N1 {
}
template<typename T> T N1::f0() { }
+
+namespace PR7385 {
+ template< typename > struct has_xxx0
+ {
+ template< typename > struct has_xxx0_introspect
+ {
+ template< typename > struct has_xxx0_substitute ;
+ template< typename V >
+ int int00( has_xxx0_substitute < typename V::template xxx< > > = 0 );
+ };
+ static const int value = has_xxx0_introspect<int>::value; // expected-error{{no member named 'value'}}
+ typedef int type;
+ };
+
+ has_xxx0<int>::type t; // expected-note{{instantiation of}}
+}
OpenPOWER on IntegriCloud