// type expands to a simple string.
bool CanPrefixQualifiers =
isa<BuiltinType>(T) || isa<TypedefType>(T) || isa<TagType>(T) ||
- isa<ComplexType>(T);
+ isa<ComplexType>(T) || isa<TemplateSpecializationType>(T);
if (!CanPrefixQualifiers && !Quals.empty()) {
std::string TQS;
// PR6716
namespace test1 {
template <class T> class A {
- template <class U> friend void foo(A &, U); // expected-note {{not viable: 1st argument ('A<int> const') would lose const qualifier}}
+ template <class U> friend void foo(A &, U); // expected-note {{not viable: 1st argument ('const A<int>') would lose const qualifier}}
};
void test() {
if (ptr)
return ptr; // okay
else if (ptr2)
- return ptr2; // expected-error{{cannot initialize return object of type 'A<int, FLOAT> *' with an lvalue of type 'A<int> const *'}}
+ return ptr2; // expected-error{{cannot initialize return object of type 'A<int, FLOAT> *' with an lvalue of type 'const A<int> *'}}
else {
return ptr3; // expected-error{{cannot initialize return object of type 'A<int, FLOAT> *' with an lvalue of type 'A<int, double> *'}}
}