Skip to content

Commit

Permalink
Revert "fieldless" back to "C-like"
Browse files Browse the repository at this point in the history
  • Loading branch information
fee1-dead committed Aug 19, 2021
1 parent a004af2 commit db8d5b0
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/items/enumerations.md
Original file line number Diff line number Diff line change
Expand Up @@ -78,13 +78,13 @@ In two circumstances, the discriminant of a variant may be explicitly set by
following the variant name with `=` and a [constant expression]:


1. if the enumeration is fieldless; e.g.:
1. if the enumeration is "C-like" (i.e., it has no tuple or struct variants); e.g.:

```rust
enum Enum {
Foo = 3,
Bar() = 2,
Baz {} = 1,
Bar = 2,
Baz = 1,
}
```

Expand Down Expand Up @@ -161,7 +161,7 @@ enum OverflowingDiscriminantError2 {

[`mem::discriminant`] returns an opaque reference to the discriminant of
an enum value which can be compared. This cannot be used to get the value
of the discriminant.
of the discriminant.

#### Casting

Expand Down

0 comments on commit db8d5b0

Please sign in to comment.