Skip to content

Commit 95d9c86

Browse files
committed
docs: Simplify a tutorial example
1 parent 28c4560 commit 95d9c86

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

doc/tutorial.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1558,7 +1558,7 @@ access local variables in the enclosing scope.
15581558

15591559
~~~~
15601560
let mut max = 0;
1561-
(~[1, 2, 3]).map(|x| if *x > max { max = *x });
1561+
[1, 2, 3].map(|x| if *x > max { max = *x });
15621562
~~~~
15631563

15641564
Stack closures are very efficient because their environment is

0 commit comments

Comments
 (0)