diff --git a/src/doc/book/traits.md b/src/doc/book/traits.md index 107ef2b44d5eb..e685cb129b939 100644 --- a/src/doc/book/traits.md +++ b/src/doc/book/traits.md @@ -397,10 +397,10 @@ fn normal>(x: &T) -> i64 { } // can be called with T == i64 -fn inverse() -> T +fn inverse(x: i32) -> T // this is using ConvertTo as if it were "ConvertTo" where i32: ConvertTo { - 42.convert() + x.convert() } ```