Skip to content

Fix build warnings #3002

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 1 commit into from
Mar 8, 2025
Merged

Fix build warnings #3002

merged 1 commit into from
Mar 8, 2025

Conversation

ahoppen
Copy link
Member

@ahoppen ahoppen commented Mar 7, 2025

Mostly, ensure that we only use @_implementationOnly if we build with RESILIENT_LIBRARIES.

Also, strerror is marked as unsafe and deprecated on Windows. It looks like this is because strerror is not thread-safe. Switch to the thread-safe version strerror_r instead.

@ahoppen ahoppen requested a review from rintaro March 7, 2025 15:43
@ahoppen ahoppen requested a review from bnbarham as a code owner March 7, 2025 15:43
@ahoppen
Copy link
Member Author

ahoppen commented Mar 7, 2025

@swift-ci Please test

@ahoppen
Copy link
Member Author

ahoppen commented Mar 7, 2025

@swift-ci Please test

@ahoppen
Copy link
Member Author

ahoppen commented Mar 7, 2025

@swift-ci Please test Windows

Copy link
Contributor

@bnbarham bnbarham left a comment

Choose a reason for hiding this comment

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

I quite dislike the #ifs for the imports, but I don't have a better suggestion.

Mostly, ensure that we only use `@_implementationOnly` if we build with `RESILIENT_LIBRARIES`.

Also, `strerror` is marked as unsafe and deprecated on Windows. It looks like this is because `strerror` is not thread-safe. Switch to the thread-safe version `strerror_r` instead.
@ahoppen
Copy link
Member Author

ahoppen commented Mar 7, 2025

@swift-ci Please test

@ahoppen
Copy link
Member Author

ahoppen commented Mar 7, 2025

@swift-ci Please test Windows

7 similar comments
@ahoppen
Copy link
Member Author

ahoppen commented Mar 7, 2025

@swift-ci Please test Windows

@ahoppen
Copy link
Member Author

ahoppen commented Mar 7, 2025

@swift-ci Please test Windows

@ahoppen
Copy link
Member Author

ahoppen commented Mar 7, 2025

@swift-ci Please test Windows

@ahoppen
Copy link
Member Author

ahoppen commented Mar 7, 2025

@swift-ci Please test Windows

@ahoppen
Copy link
Member Author

ahoppen commented Mar 8, 2025

@swift-ci Please test Windows

@ahoppen
Copy link
Member Author

ahoppen commented Mar 8, 2025

@swift-ci Please test Windows

@ahoppen
Copy link
Member Author

ahoppen commented Mar 8, 2025

@swift-ci Please test Windows

@ahoppen ahoppen merged commit af7c0c6 into swiftlang:main Mar 8, 2025
22 checks passed
@ahoppen ahoppen deleted the fix-warnings branch March 8, 2025 15:42
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