Skip to content

Commit 2adba31

Browse files
committed
Fixes from review
Traits -> Field labels Revert a change to convention
1 parent 6bbe675 commit 2adba31

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/doc/book/structs.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ let origin_y = 0;
1010
```
1111

1212
A `struct` lets us combine these two into a single, unified datatype with `x`
13-
and `y` as traits:
13+
and `y` as field labels:
1414

1515
```rust
1616
struct Point {
@@ -19,7 +19,7 @@ struct Point {
1919
}
2020

2121
fn main() {
22-
let origin = Point { x: 0, y: 0 }; // create an instance
22+
let origin = Point { x: 0, y: 0 }; // origin: Point
2323

2424
println!("The origin is at ({}, {})", origin.x, origin.y);
2525
}

0 commit comments

Comments
 (0)