diff --git a/src/ch10-01-syntax.md b/src/ch10-01-syntax.md index 663844423e..c064094a54 100644 --- a/src/ch10-01-syntax.md +++ b/src/ch10-01-syntax.md @@ -55,7 +55,7 @@ same type `T`. Listing 10-5 shows the combined `largest` function definition using the generic data type in its signature. The listing also shows how we can call the function with either a slice of `i32` values or `char` values. Note that this code won’t -compile yet, but we’ll fix it later in this chapter. +compile yet. @@ -77,10 +77,10 @@ states that the body of `largest` won’t work for all possible types that `T` could be. Because we want to compare values of type `T` in the body, we can only use types whose values can be ordered. To enable comparisons, the standard library has the `std::cmp::PartialOrd` trait that you can implement on types -(see Appendix C for more on this trait). By following the help text’s -suggestion, we restrict the types valid for `T` to only those that implement -`PartialOrd` and this example will compile, because the standard library -implements `PartialOrd` on both `i32` and `char`. +(see Appendix C for more on this trait). To fix the example code above, we would +need to follow the help text's suggestions and restrict the types valid for `T` +to only those that implement `PartialOrd`. The example would then compile, because +the standard library implements `PartialOrd` on both `i32` and `char`. ### In Struct Definitions