Skip to content

Commit 06ac6f4

Browse files
committed
Properly Iterate Through RequestedCachedResults
Clearing the cache and the end of the for loop invalidates the interator and prevents iterating through the rest of the vector. This should be cleared after we're done iterating.
1 parent 3658b6c commit 06ac6f4

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/IDE/CodeCompletion.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5568,8 +5568,8 @@ void CodeCompletionCallbacksImpl::doneParsing() {
55685568
TheModule->forAllVisibleModules(AccessPath, handleImport);
55695569
}
55705570
}
5571-
Lookup.RequestedCachedResults.clear();
55725571
}
5572+
Lookup.RequestedCachedResults.clear();
55735573

55745574
CompletionContext.typeContextKind = Lookup.typeContextKind();
55755575

0 commit comments

Comments
 (0)