summaryrefslogtreecommitdiffstats
path: root/src/doc/book
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-05-30 03:59:35 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-05-30 03:59:35 +0000
commitd1b2d29528b7794b41e66fc2136e395a02f8529b (patch)
treea4a17504b260206dec3cf55b2dca82929a348ac2 /src/doc/book
parentReleasing progress-linux version 1.72.1+dfsg1-1~progress7.99u1. (diff)
downloadrustc-d1b2d29528b7794b41e66fc2136e395a02f8529b.tar.xz
rustc-d1b2d29528b7794b41e66fc2136e395a02f8529b.zip
Merging upstream version 1.73.0+dfsg1.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'src/doc/book')
-rw-r--r--src/doc/book/redirects/using-rust-without-the-standard-library.md6
-rw-r--r--src/doc/book/src/ch08-02-strings.md2
-rw-r--r--src/doc/book/src/ch10-03-lifetime-syntax.md6
3 files changed, 7 insertions, 7 deletions
diff --git a/src/doc/book/redirects/using-rust-without-the-standard-library.md b/src/doc/book/redirects/using-rust-without-the-standard-library.md
index 75145429d..0fbdfebdd 100644
--- a/src/doc/book/redirects/using-rust-without-the-standard-library.md
+++ b/src/doc/book/redirects/using-rust-without-the-standard-library.md
@@ -7,11 +7,11 @@
---
-This particular chapter has moved to [the Unstable Book][2].
+This particular chapter has moved to [the Rustonomicon][2].
-* **[In the Unstable Rust Book: `lang_items` — Writing an executable without stdlib][2]**
+* **[In the Rustonomicon: Beneath std][2]**
* <small>[In the first edition: Ch 4.12 — Using Rust without the Standard Library][1]</small>
[1]: https://doc.rust-lang.org/1.30.0/book/first-edition/using-rust-without-the-standard-library.html
-[2]: ../unstable-book/language-features/lang-items.html#writing-an-executable-without-stdlib
+[2]: ../nomicon/beneath-std.html
diff --git a/src/doc/book/src/ch08-02-strings.md b/src/doc/book/src/ch08-02-strings.md
index 9663d36ab..f38803ee3 100644
--- a/src/doc/book/src/ch08-02-strings.md
+++ b/src/doc/book/src/ch08-02-strings.md
@@ -244,7 +244,7 @@ encoded UTF-8 example strings from Listing 8-14. First, this one:
In this case, `len` will be 4, which means the vector storing the string “Hola”
is 4 bytes long. Each of these letters takes 1 byte when encoded in UTF-8. The
following line, however, may surprise you. (Note that this string begins with
-the capital Cyrillic letter Ze, not the Arabic number 3.)
+the capital Cyrillic letter Ze, not the number 3.)
```rust
{{#rustdoc_include ../listings/ch08-common-collections/listing-08-14/src/main.rs:russian}}
diff --git a/src/doc/book/src/ch10-03-lifetime-syntax.md b/src/doc/book/src/ch10-03-lifetime-syntax.md
index 5229ab74b..498f01f0b 100644
--- a/src/doc/book/src/ch10-03-lifetime-syntax.md
+++ b/src/doc/book/src/ch10-03-lifetime-syntax.md
@@ -8,13 +8,13 @@ One detail we didn’t discuss in the [“References and
Borrowing”][references-and-borrowing]<!-- ignore --> section in Chapter 4 is
that every reference in Rust has a *lifetime*, which is the scope for which
that reference is valid. Most of the time, lifetimes are implicit and inferred,
-just like most of the time, types are inferred. We only must annotate types
+just like most of the time, types are inferred. We must only annotate types
when multiple types are possible. In a similar way, we must annotate lifetimes
when the lifetimes of references could be related in a few different ways. Rust
requires us to annotate the relationships using generic lifetime parameters to
ensure the actual references used at runtime will definitely be valid.
-Annotating lifetimes is not even a concept most other programming languages
+Annotating lifetimes is not a concept most other programming languages
have, so this is going to feel unfamiliar. Although we won’t cover lifetimes in
their entirety in this chapter, we’ll discuss common ways you might encounter
lifetime syntax so you can get comfortable with the concept.
@@ -44,7 +44,7 @@ The outer scope declares a variable named `r` with no initial value, and the
inner scope declares a variable named `x` with the initial value of 5. Inside
the inner scope, we attempt to set the value of `r` as a reference to `x`. Then
the inner scope ends, and we attempt to print the value in `r`. This code won’t
-compile because the value `r` is referring to has gone out of scope before we
+compile because what the value `r` is referring to has gone out of scope before we
try to use it. Here is the error message:
```console