summaryrefslogtreecommitdiffstats
path: root/clang/test/SemaTemplate
diff options
context:
space:
mode:
authorAlex Lorenz <arphaman@gmail.com>2017-03-10 15:04:58 +0000
committerAlex Lorenz <arphaman@gmail.com>2017-03-10 15:04:58 +0000
commit76377dcf99ddf628cdcd45833c839596e29e17f2 (patch)
tree8c27bd4089c9e5ce532d95ae2e06c2571942e52d /clang/test/SemaTemplate
parent3cc57fa1e7a3a8e25322a5fbe061dea5a17c945b (diff)
downloadbcm5719-llvm-76377dcf99ddf628cdcd45833c839596e29e17f2.tar.gz
bcm5719-llvm-76377dcf99ddf628cdcd45833c839596e29e17f2.zip
Print nested name specifiers for typedefs and type aliases
Printing typedefs or type aliases using clang_getTypeSpelling() is missing the namespace they are defined in. This is in contrast to other types that always yield the full typename including namespaces. Patch by Michael Reiher! Differential Revision: https://reviews.llvm.org/D29944 llvm-svn: 297465
Diffstat (limited to 'clang/test/SemaTemplate')
-rw-r--r--clang/test/SemaTemplate/member-access-ambig.cpp2
-rw-r--r--clang/test/SemaTemplate/typename-specifier.cpp2
2 files changed, 2 insertions, 2 deletions
diff --git a/clang/test/SemaTemplate/member-access-ambig.cpp b/clang/test/SemaTemplate/member-access-ambig.cpp
index 5c2d7617033..a28698bb17e 100644
--- a/clang/test/SemaTemplate/member-access-ambig.cpp
+++ b/clang/test/SemaTemplate/member-access-ambig.cpp
@@ -48,7 +48,7 @@ namespace AddrOfMember {
typedef int (A::*P);
template<typename T> struct S : T {
void f() {
- P(&T::X) // expected-error {{cannot cast from type 'int *' to member pointer type 'P'}}
+ P(&T::X) // expected-error {{cannot cast from type 'int *' to member pointer type 'AddrOfMember::P'}}
== &A::X;
}
};
diff --git a/clang/test/SemaTemplate/typename-specifier.cpp b/clang/test/SemaTemplate/typename-specifier.cpp
index b36a103b65a..99326f6a400 100644
--- a/clang/test/SemaTemplate/typename-specifier.cpp
+++ b/clang/test/SemaTemplate/typename-specifier.cpp
@@ -102,7 +102,7 @@ D<long> struct_D; // expected-note {{in instantiation of template class 'D<long
template<typename T> struct E {
typedef typename T::foo foo;
- typedef typename foo::bar bar; // expected-error {{type 'foo' (aka 'double') cannot be used prior to '::' because it has no members}}
+ typedef typename foo::bar bar; // expected-error {{type 'E<F>::foo' (aka 'double') cannot be used prior to '::' because it has no members}}
};
struct F {
OpenPOWER on IntegriCloud