We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 1d5fd89 commit ccbd7b2Copy full SHA for ccbd7b2
src/custom_types/structs.md
@@ -55,10 +55,10 @@ fn main() {
55
56
// Make a new point by using struct update syntax to use the fields of our
57
// other one
58
- let bottom_right = Point { x: 5.2, ..point };
+ let bottom_right = Point { x: 5.2, ..another_point };
59
60
- // `bottom_right.y` will be the same as `point.y` because we used that field
61
- // from `point`
+ // `bottom_right.y` will be the same as `another_point.y` because we used that field
+ // from `another_point`
62
println!("second point: ({}, {})", bottom_right.x, bottom_right.y);
63
64
// Destructure the point using a `let` binding
0 commit comments