Skip to content

Commit 0d3bdc6

Browse files
authored
Fix a error of 'book/deref-coercions.html'
The original sentence is: > This example has two conversions: `Rc<String>` to `String` and then `String` to `&str`. But it should be > This example has two conversions: `Rc<String>` to `String` and then `String` to `str`. or > This example has two conversions: `&Rc<String>` to `&String` and then `&String` to `&str`. I think the latter is more clearly.
1 parent 6572a46 commit 0d3bdc6

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/doc/book/deref-coercions.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ foo(&counted);
6969
All we’ve done is wrap our `String` in an `Rc<T>`. But we can now pass the
7070
`Rc<String>` around anywhere we’d have a `String`. The signature of `foo`
7171
didn’t change, but works just as well with either type. This example has two
72-
conversions: `Rc<String>` to `String` and then `String` to `&str`. Rust will do
72+
conversions: `&Rc<String>` to `&String` and then `&String` to `&str`. Rust will do
7373
this as many times as possible until the types match.
7474

7575
Another very common implementation provided by the standard library is:

0 commit comments

Comments
 (0)