Small change to example to make variable values more sensible.
This commit is contained in:
parent
e5f1b9f6dc
commit
51ea4fb17f
|
@ -1492,8 +1492,8 @@ Rust uses the unary star operator (`*`) to access the contents of a
|
|||
box or pointer, similarly to C.
|
||||
|
||||
~~~
|
||||
let owned = ~20;
|
||||
let borrowed = &30;
|
||||
let owned = ~10;
|
||||
let borrowed = &20;
|
||||
|
||||
let sum = *owned + *borrowed;
|
||||
~~~
|
||||
|
|
Loading…
Reference in New Issue