Author: rsmith Date: Tue Feb 14 21:29:24 2017 New Revision: 295146 URL: http://llvm.org/viewvc/llvm-project?rev=295146&view=rev Log: Speculatively revert r295118 to see if it's what's causing the modules selfhost buildbots to fail.
Modified: cfe/trunk/lib/AST/Type.cpp cfe/trunk/test/SemaTemplate/explicit-specialization-member.cpp Modified: cfe/trunk/lib/AST/Type.cpp URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/AST/Type.cpp?rev=295146&r1=295145&r2=295146&view=diff ============================================================================== --- cfe/trunk/lib/AST/Type.cpp (original) +++ cfe/trunk/lib/AST/Type.cpp Tue Feb 14 21:29:24 2017 @@ -3023,10 +3023,8 @@ static TagDecl *getInterestingTagDecl(Ta if (I->isCompleteDefinition() || I->isBeingDefined()) return I; } - // If there's no definition (not even in progress), return the most recent - // declaration. This is important for template specializations, in order to - // pick the declaration with the most complete TemplateSpecializationKind. - return decl->getMostRecentDecl(); + // If there's no definition (not even in progress), return what we have. + return decl; } TagDecl *TagType::getDecl() const { Modified: cfe/trunk/test/SemaTemplate/explicit-specialization-member.cpp URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/SemaTemplate/explicit-specialization-member.cpp?rev=295146&r1=295145&r2=295146&view=diff ============================================================================== --- cfe/trunk/test/SemaTemplate/explicit-specialization-member.cpp (original) +++ cfe/trunk/test/SemaTemplate/explicit-specialization-member.cpp Tue Feb 14 21:29:24 2017 @@ -57,14 +57,3 @@ template<typename T> struct Helper { template<typename T> void Helper<T>::func<2>() {} // expected-error {{cannot specialize a member}} \ // expected-error {{no function template matches}} } - -namespace b35070233 { - template <typename T> struct Cls { - static void f() {} - }; - - void g(Cls<int>); - - template<> struct Cls<int>; // expected-note {{forward declaration}} - template<> void Cls<int>::f(); // expected-error {{incomplete type}} -} _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits