Skip to content

Commit

Permalink
Merge remote-tracking branch 'upstream/main'
Browse files Browse the repository at this point in the history
  • Loading branch information
damoasda committed Jan 1, 2024
2 parents b427363 + 71352de commit c51c6b1
Show file tree
Hide file tree
Showing 7 changed files with 14 additions and 21 deletions.
2 changes: 1 addition & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -70,4 +70,4 @@ a new language! We're waiting on [mdbook support] for multiple languages
before we merge any in, but feel free to start!

[Translations]: https://github.com/rust-lang/book/issues?q=is%3Aopen+is%3Aissue+label%3ATranslations
[mdbook support]: https://github.com/rust-lang-nursery/mdBook/issues/5
[mdbook support]: https://github.com/rust-lang/mdBook/issues/5
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ See the [releases] to download just the code of all the code listings that appea
Building the book requires [mdBook], ideally the same version that
rust-lang/rust uses in [this file][rust-mdbook]. To get it:

[mdBook]: https://github.com/rust-lang-nursery/mdBook
[mdBook]: https://github.com/rust-lang/mdBook
[rust-mdbook]: https://github.com/rust-lang/rust/blob/master/src/tools/rustbook/Cargo.toml

```bash
Expand Down Expand Up @@ -93,7 +93,7 @@ a new language! We're waiting on [mdbook support] for multiple languages
before we merge any in, but feel free to start!

[Translations]: https://github.com/rust-lang/book/issues?q=is%3Aopen+is%3Aissue+label%3ATranslations
[mdbook support]: https://github.com/rust-lang-nursery/mdBook/issues/5
[mdbook support]: https://github.com/rust-lang/mdBook/issues/5

## Spellchecking

Expand Down
11 changes: 2 additions & 9 deletions redirects/compiler-plugins.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,5 @@

<small>There is a new edition of the book and this is an old link.</small>

> Compiler plugins are user-provided libraries that extend the compiler's behavior with new syntax extensions, lint checks, etc.
---

This particular chapter has moved to [the Unstable Book][2].

* **[In the Unstable Rust Book: `plugin`][2]**

[2]: ../unstable-book/language-features/plugin.html
> Compiler plugins were user-provided libraries that extended the compiler's behavior in certain ways.
> Support for them has been removed.
6 changes: 3 additions & 3 deletions redirects/using-rust-without-the-standard-library.md
Original file line number Diff line number Diff line change
Expand Up @@ -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
2 changes: 1 addition & 1 deletion src/ch01-02-hello-world.md
Original file line number Diff line number Diff line change
Expand Up @@ -198,4 +198,4 @@ code. Next, we’ll introduce you to the Cargo tool, which will help you write
real-world Rust programs.

[troubleshooting]: ch01-01-installation.html#troubleshooting
[devtools]: appendix-04-useful-development-tools.md
[devtools]: appendix-04-useful-development-tools.html
4 changes: 2 additions & 2 deletions src/ch02-00-guessing-game-tutorial.md
Original file line number Diff line number Diff line change
Expand Up @@ -930,8 +930,8 @@ discusses structs and method syntax, and Chapter 6 explains how enums work.
[randcrate]: https://crates.io/crates/rand
[semver]: http://semver.org
[cratesio]: https://crates.io/
[doccargo]: http://doc.crates.io
[doccratesio]: http://doc.crates.io/crates-io.html
[doccargo]: https://doc.rust-lang.org/cargo/
[doccratesio]: https://doc.rust-lang.org/cargo/reference/publishing.html
[match]: ch06-02-match.html
[shadowing]: ch03-01-variables-and-mutability.html#shadowing
[parse]: ../std/primitive.str.html#method.parse
Expand Down
6 changes: 3 additions & 3 deletions src/ch10-03-lifetime-syntax.md
Original file line number Diff line number Diff line change
Expand Up @@ -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.
Expand Down Expand Up @@ -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
Expand Down

0 comments on commit c51c6b1

Please sign in to comment.