Skip to content

[windows] Avoid warning in header in test turning into fatal error. #28175

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

Conversation

drodriguez
Copy link
Contributor

In Windows, ClangImporter seems to execute with Microsoft compatibility,
and there are some more warnings that do not happen in Unix. One of them
seems to be -Wmicrosoft-enum-forward-reference which warns about forward
defined enums, like the one that happens in this header. Since the
-warnings-as-errors flag is now passed down to ClangImporter, this
warning will make this test fail.

Simply use the #pragma to disable the warning for this piece of code.

The problem was introduced in #28142 and started failing in https://ci-external.swift.org/job/oss-swift-windows-x86_64/1888/

In Windows, ClangImporter seems to execute with Microsoft compatibility,
and there are some more warnings that do not happen in Unix. One of them
seems to be -Wmicrosoft-enum-forward-reference which warns about forward
defined enums, like the one that happens in this header. Since the
-warnings-as-errors flag is now passed down to ClangImporter, this
warning will make this test fail.

Simply use the #pragma to disable the warning for this piece of code.
@drodriguez
Copy link
Contributor Author

Since PR 28170 is also trying to fix a compilation problem that happens before this one, running the Windows tests at this moment will not succeed.

@swift-ci please smoke test

@compnerd compnerd merged commit 5ca5c15 into swiftlang:master Nov 9, 2019
@drodriguez drodriguez deleted the windows-disable-warning-forwarded-enums branch November 9, 2019 21:37
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