Skip to content

Indexing: include index file entry in supplementary output file map #478

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Feb 9, 2021

Conversation

nkcsgexi
Copy link
Contributor

@nkcsgexi nkcsgexi commented Feb 9, 2021

This is the behavior of the C++ driver and we should preserve it.

rdar://74127445

This is the behavior of the C++ driver and we should preserve it.

rdar://74127445
@nkcsgexi
Copy link
Contributor Author

nkcsgexi commented Feb 9, 2021

@swift-ci please test

@@ -417,6 +418,11 @@ extension Driver {
for flaggedPair in flaggedInputOutputPairs {
addEntry(&entries, input: flaggedPair.input, output: flaggedPair.output)
}
// To match the legacy driver behavior, make sure we add an entry for the
// file under indexing and the primary output file path.
if let indexFilePath = indexFilePath, let idxOutput = inputOutputMap[indexFilePath] {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah, I guess after 3 input source files we are going to exceed:

if inputsGeneratingCodeCount * FileType.allCases.count > fileListThreshold {

Makes sense to me!

@nkcsgexi nkcsgexi merged commit c86e00d into swiftlang:main Feb 9, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants