Skip to content

Rearranged enum section of tutorial for clarity. #12060

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

Closed
wants to merge 1 commit into from
Closed

Rearranged enum section of tutorial for clarity. #12060

wants to merge 1 commit into from

Conversation

chromatic
Copy link
Contributor

This version starts with the simplest case and builds on it. I believe it flows better.

@@ -682,12 +659,20 @@ enum Direction {
}
~~~~

This declaration defines `North`, `East`, `South`, and `West` as constants,
all of which have type `Direction`.
Each variant of this C-like enum has a unique discriminator value. If no
Copy link
Member

Choose a reason for hiding this comment

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

Needs an explanation of why this is C-like.

@emberian
Copy link
Member

emberian commented Feb 6, 2014

r+ with above comment addressed

@chromatic
Copy link
Contributor Author

Good point. There's no need to write "C-like". This version is more explicit about what really happens.

This version starts with the simple case and builds on it.
@chromatic
Copy link
Contributor Author

This version passes tests locally.

bors added a commit that referenced this pull request Feb 10, 2014
…excrichton

This version starts with the simplest case and builds on it. I believe it flows better.
@bors bors closed this Feb 10, 2014
bors added a commit to rust-lang-ci/rust that referenced this pull request Jul 25, 2022
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.

3 participants