-
-
Notifications
You must be signed in to change notification settings - Fork 2.8k
c translation of enum with multiple names matched to same value #1359
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
Labels
bug
Observed behavior contradicts documented or intended behavior
contributor friendly
This issue is limited in scope and/or knowledge of Zig internals.
frontend
Tokenization, parsing, AstGen, Sema, and Liveness.
translate-c
C to Zig source translation feature (@cImport)
Milestone
Comments
zacharycarter
pushed a commit
to zacharycarter/zeal_zig
that referenced
this issue
Dec 15, 2018
Are there any workarounds in 0.4 right now? Otherwise I think this currently blocks me from using Vulkan without manually defining the external symbols. |
Related proposal: #2115 |
This is blocking me from using SFML 2.5.
|
This is blocking me using
|
Extern enums now allow multiple names matched to same value. |
This is huuuge! Thanks so much! <3 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
bug
Observed behavior contradicts documented or intended behavior
contributor friendly
This issue is limited in scope and/or knowledge of Zig internals.
frontend
Tokenization, parsing, AstGen, Sema, and Liveness.
translate-c
C to Zig source translation feature (@cImport)
This C code:
Generates this Zig code:
Which is a compile error in Zig. It also generates:
Which are the actual symbols in the C namespace. So Zig will be OK omitting the second name with the same value as a previous item, but instead of the global names being the enum type, they have to be the integer type.
The text was updated successfully, but these errors were encountered: