Skip to content

Commit 4a63d9f

Browse files
committed
Remove broken explicit coercion example
1 parent fd2626c commit 4a63d9f

File tree

1 file changed

+0
-7
lines changed

1 file changed

+0
-7
lines changed

src/doc/book/casting-between-types.md

-7
Original file line numberDiff line numberDiff line change
@@ -49,13 +49,6 @@ expression, `e as U2` is not necessarily so (in fact it will only be valid if
4949

5050
A cast `e as U` is valid if `e` has type `T` and `T` *coerces* to `U`.
5151

52-
For example:
53-
54-
```rust
55-
let a = "hello";
56-
let b = a as String;
57-
```
58-
5952
## Numeric casts
6053

6154
A cast `e as U` is also valid in any of the following cases:

0 commit comments

Comments
 (0)