diff options
author | John McCall <rjmccall@apple.com> | 2010-04-29 23:50:39 +0000 |
---|---|---|
committer | John McCall <rjmccall@apple.com> | 2010-04-29 23:50:39 +0000 |
commit | 99b2fe5f54e2a37c486e7433f7c2907778431fb9 (patch) | |
tree | 23ae0e89c4ebc36473db6495d117324489a6379d /clang/test/SemaTemplate/nested-name-spec-template.cpp | |
parent | 8d4214578d3d68b55337369dd7de7128af6b8c22 (diff) | |
download | bcm5719-llvm-99b2fe5f54e2a37c486e7433f7c2907778431fb9.tar.gz bcm5719-llvm-99b2fe5f54e2a37c486e7433f7c2907778431fb9.zip |
Rebuild the nested name specifiers in member-pointer declarator chunks when
entering the current instantiation. Set up a little to preserve type location
information for typename types while we're in there.
Fixes a Boost failure.
llvm-svn: 102673
Diffstat (limited to 'clang/test/SemaTemplate/nested-name-spec-template.cpp')
-rw-r--r-- | clang/test/SemaTemplate/nested-name-spec-template.cpp | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/clang/test/SemaTemplate/nested-name-spec-template.cpp b/clang/test/SemaTemplate/nested-name-spec-template.cpp index 1691db74a11..9d25a051e8a 100644 --- a/clang/test/SemaTemplate/nested-name-spec-template.cpp +++ b/clang/test/SemaTemplate/nested-name-spec-template.cpp @@ -51,3 +51,16 @@ struct TestA { typedef typename N::template B<T>::type type; // expected-error{{'B' following the 'template' keyword does not refer to a template}} \ // expected-error{{expected member name}} }; + +// Reduced from a Boost failure. +namespace test1 { + template <class T> struct pair { + T x; + T y; + + static T pair<T>::* const mem_array[2]; + }; + + template <class T> + T pair<T>::* const pair<T>::mem_array[2] = { &pair<T>::x, &pair<T>::y }; +} |