@@ -10188,12 +10188,12 @@ void ASTReader::visitTopLevelModuleMaps(
1018810188}
1018910189
1019010190void ASTReader::finishPendingActions () {
10191- while (!PendingIdentifierInfos. empty () ||
10192- !PendingDeducedFunctionTypes.empty () ||
10193- !PendingDeducedVarTypes.empty () || !PendingDeclChains .empty () ||
10194- !PendingMacroIDs .empty () || !PendingDeclContextInfos .empty () ||
10195- !PendingUpdateRecords.empty () ||
10196- !PendingObjCExtensionIvarRedeclarations.empty ()) {
10191+ while (
10192+ !PendingIdentifierInfos. empty () || !PendingDeducedFunctionTypes.empty () ||
10193+ !PendingDeducedVarTypes.empty () || !PendingIncompleteDeclChains .empty () ||
10194+ !PendingDeclChains .empty () || !PendingMacroIDs .empty () ||
10195+ !PendingDeclContextInfos. empty () || !PendingUpdateRecords.empty () ||
10196+ !PendingObjCExtensionIvarRedeclarations.empty ()) {
1019710197 // If any identifiers with corresponding top-level declarations have
1019810198 // been loaded, load those declarations now.
1019910199 using TopLevelDeclsMap =
@@ -10241,6 +10241,13 @@ void ASTReader::finishPendingActions() {
1024110241 }
1024210242 PendingDeducedVarTypes.clear ();
1024310243
10244+ // For each decl chain that we wanted to complete while deserializing, mark
10245+ // it as "still needs to be completed".
10246+ for (unsigned I = 0 ; I != PendingIncompleteDeclChains.size (); ++I) {
10247+ markIncompleteDeclChain (PendingIncompleteDeclChains[I]);
10248+ }
10249+ PendingIncompleteDeclChains.clear ();
10250+
1024410251 // Load pending declaration chains.
1024510252 for (unsigned I = 0 ; I != PendingDeclChains.size (); ++I)
1024610253 loadPendingDeclChain (PendingDeclChains[I].first ,
@@ -10478,12 +10485,6 @@ void ASTReader::finishPendingActions() {
1047810485 for (auto *ND : PendingMergedDefinitionsToDeduplicate)
1047910486 getContext ().deduplicateMergedDefinitonsFor (ND);
1048010487 PendingMergedDefinitionsToDeduplicate.clear ();
10481-
10482- // For each decl chain that we wanted to complete while deserializing, mark
10483- // it as "still needs to be completed".
10484- for (Decl *D : PendingIncompleteDeclChains)
10485- markIncompleteDeclChain (D);
10486- PendingIncompleteDeclChains.clear ();
1048710488}
1048810489
1048910490void ASTReader::diagnoseOdrViolations () {
0 commit comments