Skip to content

[cxx-interop] Test typed and untyped enums cannot be assigned to each other #61639

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
Oct 20, 2022

Conversation

mikepinkerton
Copy link

Check that untyped C++ enums (which import into Swift as Int) cannot be assigned to an imported C++ type that is a typed enum or an enum class.

@hyp hyp added the c++ interop Feature: Interoperability with C++ label Oct 19, 2022
@hyp
Copy link
Contributor

hyp commented Oct 19, 2022

@swift-ci please test

@hyp
Copy link
Contributor

hyp commented Oct 19, 2022

@swift-ci please test macOS platform

Copy link
Contributor

@zoecarver zoecarver left a comment

Choose a reason for hiding this comment

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

Looks good. Thanks, Mike!

@hyp
Copy link
Contributor

hyp commented Oct 20, 2022

Thanks!

@hyp hyp merged commit 9348d44 into swiftlang:main Oct 20, 2022
bytes-crafter pushed a commit to openFyde/chromium that referenced this pull request May 28, 2025
I added swiftlang/swift#61639 to test the case
where enums in Swift interop were correctly not allowed to be assigned,
so removing the test case here.

Change-Id: I1f42ca1a1647b67ef86fee1ccc25cbcc6ee22ce5
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3975950
Reviewed-by: Sylvain Defresne <[email protected]>
Reviewed-by: Rohit Rao <[email protected]>
Commit-Queue: Mike Pinkerton <[email protected]>
Cr-Commit-Position: refs/heads/main@{#1063283}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
c++ interop Feature: Interoperability with C++
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants