mirror of
https://github.com/rust-lang/rust.git
synced 2024-10-31 06:22:00 +00:00
fix tutorial example that uses each()
This commit is contained in:
parent
9173508aa4
commit
6cb3ce9772
@ -1237,7 +1237,7 @@ assert !crayons.is_empty();
|
||||
|
||||
// Iterate over a vector, obtaining a pointer to each element
|
||||
for crayons.each |crayon| {
|
||||
let delicious_crayon_wax = unwrap_crayon(crayon);
|
||||
let delicious_crayon_wax = unwrap_crayon(*crayon);
|
||||
eat_crayon_wax(delicious_crayon_wax);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user