Skip to content

Convert SourceKitIndexDelegate to be an actor #1003

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 3 commits into from
Dec 19, 2023
Merged

Convert SourceKitIndexDelegate to be an actor #1003

merged 3 commits into from
Dec 19, 2023

Conversation

krzyzanowskim
Copy link
Contributor

Resolves #867

Copy link
Member

@ahoppen ahoppen left a comment

Choose a reason for hiding this comment

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

Thanks!

if pendingUnitCount < 0 {
assertionFailure("pendingUnitCount = \(pendingUnitCount) < 0")
pendingUnitCount = 0
_indexChanged()
}
}

/// *Must be called on queue*.
Copy link
Member

Choose a reason for hiding this comment

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

This comment is no longer needed.

await delegate.mainFilesChanged()
}
}
}

/// Register a delegate to receive notifications when main files change.
public func registerMainFileChanged(_ delegate: MainFilesDelegate) {
queue.sync {
mainFilesDelegates.append(delegate)
Copy link
Member

Choose a reason for hiding this comment

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

I think this should be indented two spaces less now. Could you run swift-format on your changes?

@ahoppen ahoppen enabled auto-merge (squash) December 19, 2023 19:00
@ahoppen
Copy link
Member

ahoppen commented Dec 19, 2023

@swift-ci Please test

@ahoppen ahoppen merged commit 25a1b45 into swiftlang:main Dec 19, 2023
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.

Convert SourceKitIndexDelegate to be an actor
2 participants