Skip to content
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

fix(linux support): add the missing import for linux #3

Merged
merged 1 commit into from
Jan 25, 2021

Conversation

shoebox
Copy link

@shoebox shoebox commented Jan 11, 2021

Add linux support for Swift 5.3

Copy link

@RomanPodymov RomanPodymov left a comment

Choose a reason for hiding this comment

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

Please check if you need import FoundationNetworking.

@@ -1,4 +1,7 @@
import Foundation
#if canImport(FoundationNetworking)
import FoundationNetworking

Choose a reason for hiding this comment

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

Do you really need this import? There is not such line at https://github.com/yonaskolb/SwagGen/blob/master/Sources/SwagGen/GenerateCommand.swift.

Copy link
Author

Choose a reason for hiding this comment

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

@RomanPodymov it is sadly required yes.

Yonas's repository either is not working on Linux due to the same issue.

Swift 5.1 moved all of Foundation's networking-related code to a separate module, which you have to include separately with import FoundationNetworking

Cf the following:
apple/swift-corelibs-foundation#2289

@emirandm emirandm merged commit 32ffc1d into develop-3.0.3 Jan 25, 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
4 participants