diff --git a/clang/include/clang/AST/DeclTemplate.h b/clang/include/clang/AST/DeclTemplate.h --- a/clang/include/clang/AST/DeclTemplate.h +++ b/clang/include/clang/AST/DeclTemplate.h @@ -2093,7 +2093,7 @@ /// Retrieve the set of partial specializations of this class /// template. llvm::FoldingSetVector & - getPartialSpecializations(); + getPartialSpecializations() const; ClassTemplateDecl(ASTContext &C, DeclContext *DC, SourceLocation L, DeclarationName Name, TemplateParameterList *Params, diff --git a/clang/lib/AST/DeclTemplate.cpp b/clang/lib/AST/DeclTemplate.cpp --- a/clang/lib/AST/DeclTemplate.cpp +++ b/clang/lib/AST/DeclTemplate.cpp @@ -403,7 +403,7 @@ } llvm::FoldingSetVector & -ClassTemplateDecl::getPartialSpecializations() { +ClassTemplateDecl::getPartialSpecializations() const { LoadLazySpecializations(); return getCommonPtr()->PartialSpecializations; }