Skip to content

Allow multiple language services to handle a single document #2246

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 2 commits into from
Aug 19, 2025

Conversation

ahoppen
Copy link
Member

@ahoppen ahoppen commented Aug 18, 2025

This allows us to implement all of doccDocumentation in DocumentationLanguageService. DocumentationLanguageService will be a secondary language service for Swift files and can also provide the docc documentation support that’s currently in SwiftLangaugeService.

This allows us to implement all of `doccDocumentation` in `DocumentationLanguageService`. `DocumentationLanguageService` will be a secondary language service for Swift files and can also provide the docc documentation support that’s currently in `SwiftLangaugeService`.
If a language service fails to start, don't try starting language services with lower precedence. Otherwise we get into a situation where eg. `SwiftLanguageService`` fails to start (eg. because the toolchain doesn't contain sourcekitd) and the `DocumentationLanguageService` now becomes the primary language service for the document, trying to serve documentation, completion etc. which is not intended.
@ahoppen
Copy link
Member Author

ahoppen commented Aug 18, 2025

@swift-ci Please test

@ahoppen
Copy link
Member Author

ahoppen commented Aug 18, 2025

@swift-ci Please test macOS

@ahoppen ahoppen merged commit 45d5bfb into swiftlang:main Aug 19, 2025
3 checks passed
@ahoppen ahoppen deleted the multiple-lang-services-for-doc branch August 19, 2025 22:10
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.

2 participants