Skip to content

jextract: fix conditional imports#620

Merged
ktoso merged 1 commit intoswiftlang:mainfrom
madsodgaard:conditional-import
Mar 16, 2026
Merged

jextract: fix conditional imports#620
ktoso merged 1 commit intoswiftlang:mainfrom
madsodgaard:conditional-import

Conversation

@madsodgaard
Copy link
Contributor

Fixes a bug where the generator would generate:

#if canImport(FoundationEssentials)
import FoundationEssentials
#else
import Foundation
#endif
#if canImport(Foundation)
import Foundation
#else
import FoundationEssentials
#endif

@madsodgaard madsodgaard requested a review from ktoso as a code owner March 14, 2026 14:09
Copy link
Collaborator

@ktoso ktoso left a comment

Choose a reason for hiding this comment

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

Oh good catch!

@ktoso ktoso merged commit 2fde0d7 into swiftlang:main Mar 16, 2026
61 checks passed
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