Skip to content

Document integer enum discriminators in the manual #15755

New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Closed
mbrubeck opened this issue Jul 17, 2014 · 1 comment
Closed

Document integer enum discriminators in the manual #15755

mbrubeck opened this issue Jul 17, 2014 · 1 comment

Comments

@mbrubeck
Copy link
Contributor

The tutorial documents how to set the discriminator for a C-style enum (enum Foo { Bar = 123 }) and how to cast such an enum to a numeric type (Bar as uint). However, the language manual does not mention these features at all.

@dcampbell24
Copy link
Contributor

I think it would be good to also mention what the type of the discriminant is and how to control it per #9613.

dlrobertson pushed a commit to dlrobertson/rust that referenced this issue Nov 29, 2018
bors added a commit to rust-lang-ci/rust that referenced this issue Nov 13, 2023
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants