X-Git-Url: https://git.ralfj.de/rust-101.git/blobdiff_plain/76de9227939c9244b1e5bd9364542c92991140c8..a0edb0ae866081958e5d6e2ec5a3579d2bb01085:/src/part07.rs diff --git a/src/part07.rs b/src/part07.rs index 85218bc..2d88390 100644 --- a/src/part07.rs +++ b/src/part07.rs @@ -4,8 +4,8 @@ pub use part05::BigInt; // With our new knowledge of lifetimes, we are now able to write down the desired type of `min`: -//@ We want the function to take two borrows *of the same lifetime*, and then -//@ return a borrow of that lifetime. If the two input lifetimes would be different, we +//@ We want the function to take two references *with the same lifetime*, and then +//@ return a reference with that lifetime. If the two input lifetimes would be different, we //@ would not know which lifetime to use for the result. pub trait Minimum { fn min<'a>(&'a self, other: &'a Self) -> &'a Self;