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

Add support for transparent enums #992

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

scovich
Copy link
Contributor

@scovich scovich commented Aug 12, 2024

The code restructuring work that allows transparent typedefs (see #966) makes it straightforward to also support rust's transparent enums if we want to do so. Add the support, including accompanying tests and documentation.

NOTE: This PR is currently stacked on top of #966, so the first two commits should be ignored while reviewing.

#[repr(transparent)]
struct TransparentComplexWrappingStructure { only_field: DummyStruct }
struct TransparentComplexWrappingStruct { only_field: DummyStruct }
Copy link
Contributor

Choose a reason for hiding this comment

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

I like this patch in general, but these changes which are not related to the changed behavior makes a bit harder to read the patch.

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