Skip to content

Commit 1e483c7

Browse files
author
Diggory Hardy
committed
Tutorial: fix typo
1 parent 964fc86 commit 1e483c7

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

doc/tutorial.md

+4-4
Original file line numberDiff line numberDiff line change
@@ -1069,8 +1069,8 @@ d = @mut 15;
10691069

10701070
A mutable variable and an immutable variable can refer to the same box, given
10711071
that their types are compatible. Mutability of a box is a property of its type,
1072-
however, so for example a mutable hande to an immutable box cannot be assigned
1073-
a reference to a mutable box.
1072+
however, so for example a mutable handle to an immutable box cannot be
1073+
assigned a reference to a mutable box.
10741074

10751075
~~~~
10761076
let a = @1; // immutable box
@@ -1079,8 +1079,8 @@ let b = @mut 2; // mutable box
10791079
let mut c : @int; // declare a variable with type managed immutable int
10801080
let mut d : @mut int; // and one of type managed mutable int
10811081
1082-
c = a; // box type is the same
1083-
d = b; // box type is the same
1082+
c = a; // box type is the same, okay
1083+
d = b; // box type is the same, okay
10841084
10851085
// but b cannot be assigned to c, or a to d
10861086
c = b; // error

0 commit comments

Comments
 (0)