This revision was automatically updated to reflect the committed changes.
Closed by commit rC328567: [MS] Fix late-parsed template infinite loop in eager
instantiation (authored by rnk, committed by ).
Changed prior to commit:
https://reviews.llvm.org/D44846?vs=139663&id=139827#toc
Repository:
This revision was automatically updated to reflect the committed changes.
Closed by commit rL328567: [MS] Fix late-parsed template infinite loop in eager
instantiation (authored by rnk, committed by ).
Herald added a subscriber: llvm-commits.
Changed prior to commit:
https://reviews.llvm.org/D4
rsmith accepted this revision.
rsmith added inline comments.
This revision is now accepted and ready to land.
Comment at: clang/lib/Sema/Sema.cpp:855
// instantiations. PCH files do not.
if (TUKind != TU_Prefix) {
DiagnoseUseOfUnimplementedSelectors();
rnk updated this revision to Diff 139663.
rnk added a comment.
- make late-parsed templates pending at end of TU prefix
https://reviews.llvm.org/D44846
Files:
clang/include/clang/Sema/Sema.h
clang/lib/Sema/Sema.cpp
clang/lib/Sema/SemaTemplateInstantiateDecl.cpp
clang/test/PCH/late-parse
rnk added inline comments.
Comment at: clang/lib/Sema/Sema.cpp:855
// instantiations. PCH files do not.
if (TUKind != TU_Prefix) {
DiagnoseUseOfUnimplementedSelectors();
rsmith wrote:
> In the TUPrefix case, we'll need to write these instantiations to
rsmith added inline comments.
Comment at: clang/lib/Sema/Sema.cpp:855
// instantiations. PCH files do not.
if (TUKind != TU_Prefix) {
DiagnoseUseOfUnimplementedSelectors();
In the TUPrefix case, we'll need to write these instantiations to the PCH file.
rnk created this revision.
rnk added reviewers: rsmith, thakis, hans.
This fixes PR33561 and PR34185.
Don't store pending template instantiations for late-parsed templates in
the normal PendingInstantiations queue. Instead, use a separate list
that will only be parsed and instantiated at end of T