Skip to content

Commit db8d5b0

Browse files
committed
Revert "fieldless" back to "C-like"
1 parent a004af2 commit db8d5b0

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/items/enumerations.md

+4-4
Original file line numberDiff line numberDiff line change
@@ -78,13 +78,13 @@ In two circumstances, the discriminant of a variant may be explicitly set by
7878
following the variant name with `=` and a [constant expression]:
7979

8080

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

8383
```rust
8484
enum Enum {
8585
Foo = 3,
86-
Bar() = 2,
87-
Baz {} = 1,
86+
Bar = 2,
87+
Baz = 1,
8888
}
8989
```
9090

@@ -161,7 +161,7 @@ enum OverflowingDiscriminantError2 {
161161

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

166166
#### Casting
167167

0 commit comments

Comments
 (0)