mirror of
https://github.com/rust-lang/book.git
synced 2026-11-30 20:24:32 -06:00
Fix spelling errors!!!
This commit is contained in:
@@ -56,7 +56,7 @@ Functions can also be defined to have *parameters*, which are special variables
|
|||||||
that are part of a function's signature. When a function has parameters, we can
|
that are part of a function's signature. When a function has parameters, we can
|
||||||
provide it with concrete values for those parameters. Technically, the concrete
|
provide it with concrete values for those parameters. Technically, the concrete
|
||||||
values are called *arguments*, but in casual conversation people tend to use
|
values are called *arguments*, but in casual conversation people tend to use
|
||||||
the words "parameter" and "argument" interchangably for either the variables in
|
the words "parameter" and "argument" interchangeably for either the variables in
|
||||||
a function's definition or the concrete values passed in when you call a
|
a function's definition or the concrete values passed in when you call a
|
||||||
function.
|
function.
|
||||||
|
|
||||||
|
|||||||
@@ -172,7 +172,7 @@ Again, the lifetime names are declared in the angle brackets where generic type
|
|||||||
parameters are declared, and this is because lifetimes are a form of generics.
|
parameters are declared, and this is because lifetimes are a form of generics.
|
||||||
In the examples above, `'a` and `'b` were concrete lifetimes: we knew about `r`
|
In the examples above, `'a` and `'b` were concrete lifetimes: we knew about `r`
|
||||||
and `x` and how long they would live exactly. However, when we write a
|
and `x` and how long they would live exactly. However, when we write a
|
||||||
function, we can't know beforehand exactly all of the valuess that it could be
|
function, we can't know beforehand exactly all of the values that it could be
|
||||||
called with and how long they will be valid for. We have to explain to Rust
|
called with and how long they will be valid for. We have to explain to Rust
|
||||||
what we expect the lifetime of the parameter to be (we'll learn about how to
|
what we expect the lifetime of the parameter to be (we'll learn about how to
|
||||||
know what you expect the lifetime to be in a bit). This is similar to writing a
|
know what you expect the lifetime to be in a bit). This is similar to writing a
|
||||||
|
|||||||
Reference in New Issue
Block a user