Skip to content

Conversation

skorulis-ap
Copy link
Collaborator

@skorulis-ap skorulis-ap commented Aug 28, 2025

If a project uses the MemberImportVisibility compiler flag then it requires that Swinject is imported in order to access functions from Swinject, like .implements. To a large degree this would require all consumers of Knit to also import Swinject. To solve this I've added @_exported import Swinject.

But now that Swinject is always imported there will be constant conflicts between the Container and Resolver types. So I've renamed the Swinject versions to SwinjectContainer and SwinjectResolver

@skorulis-ap skorulis-ap force-pushed the skorulis/swinject-import branch from 414a94d to 57d8f60 Compare August 28, 2025 04:50
@skorulis-ap skorulis-ap changed the title Always import Swinject in type safety generated files Fix build issues when MemberImportVisibility is enabled Aug 28, 2025
@skorulis-ap skorulis-ap marked this pull request as ready for review August 28, 2025 05:23
@skorulis-ap skorulis-ap requested a review from bradfol August 28, 2025 05:23
Copy link
Collaborator

@bradfol bradfol left a comment

Choose a reason for hiding this comment

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

Makes sense to me!

@skorulis-ap skorulis-ap merged commit 19e8a09 into main Sep 3, 2025
2 checks passed
@skorulis-ap skorulis-ap deleted the skorulis/swinject-import branch September 3, 2025 05:43
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