Commit Graph

5096 Commits

Author SHA1 Message Date
Aryan Malik 44c783863a Fixed 'troubleshooting' link 2023-11-09 09:49:45 -05:00
Marcus Stollsteimer d0473bee36 Fix mdBook links 2023-11-09 09:49:16 -05:00
Marcus Stollsteimer 81255e776b Update panic! formatting style for Guess example 2023-11-04 14:32:25 +01:00
Nicholas Nethercote 5b6c1ceaa6 Prepare for removal of compiler plugin support.
https://github.com/rust-lang/rust/pull/116412 will remove support for
compiler plugins from rustc, which includes the entry in The Rust
Unstable Book. This commit removes a link to that entry so it won't be
broken when that PR merges.
2023-11-01 09:55:24 -04:00
Yuri Astrakhan a786ec4a2b Use v1.58 captured ident formatting in examples
Per https://github.com/rust-lang/book/issues/3047, use captured identifiers instead of the positional ones for some examples, e.g.

```diff
-  println!("Worker {} got a job; executing.", id);
+  println!("Worker {id} got a job; executing.");
```
2023-10-30 11:54:45 -04:00
Yuri Astrakhan f55ac5d8fa Inline all format arguments
The inlined format arguments are a bit easier to understand,
especially for those familiar with the other languages (python, js).
2023-10-30 11:54:36 -04:00
Rafael Kraut 187b317e89 Improve ch03-05-control-flow collection looping wording
This makes it clearer, that you COULD use a `while` loop to loop a collection, but a `for` loop is the preferred way
2023-10-27 14:37:32 +02:00
Eric Huss 3dca2fc50b Fix cargo doc links 2023-10-19 14:01:47 -04:00
Matt Nield 1402554da8
Fix typo in Chapter 7 Section 3
Fix typo in Chapter 7 Section 3, changing "start an executable that calls code with the library crate." to "start an executable that calls code within the library crate."
2023-10-08 02:02:46 -04:00
Matt Nield 08d3496982
Fix typo in Chapter 7 Section 3
Fix typo in Chapter 7 Section 3, changing "benefit from the most functionality" to "benefit from most of the functionality"
2023-10-08 01:52:28 -04:00
Stu 84ff595aa4
reword 2023-09-20 17:22:00 +01:00
Luciano Manerich Junior a6656c5b07
Added "--" between run and args 2023-08-19 17:54:19 -03:00
kadiwa 72187f5cd0 redirects: change link for `#![no_std]` tutorial 2023-08-04 10:42:07 -04:00
Mike Krisher 66aedb4a61 Small wording changes 2023-08-03 09:39:31 -04:00
Jaime Terreu 4d988c795a Improve sentence 2023-08-03 09:36:44 -04:00
Mike Ton a80a425f71 Comments cleaned up and removed 2023-07-19 16:46:31 +00:00
Mike Ton dc16e35f98 Update loop to Result: 10 2023-07-19 16:30:28 +00:00
Joshua Goring 8f79c36d97 Fix #3703 2023-07-14 22:37:30 -05:00
Rahul Rao d7db5129d2
Update ch07-03-paths-for-referring-to-an-item-in-the-module-tree.md
Editing what I think is a minor typo. The binary crate should be calling code within the library crate (instead of with the library crate)
2023-07-07 23:45:42 +05:30
Carol (Nichols || Goulding) 668c64760b
Remove adjective about what kind of number this is 2023-06-29 09:50:36 -04:00
Menachem Adin eb0e86b49d Remove redundant words 2023-06-16 00:15:10 +03:00
Shinya Fujino 21cf840842 Correct `i32` formatting in ch19-05 2023-06-12 12:24:06 -04:00
Arjun Aggarwal a125fc772c
Update README.md
->It appears that you are missing a comma after the introductory 
    phrase ideally
->The noun phrase word seems to be missing a determiner 
     before it
2023-05-21 03:12:39 +05:30
Kris van Rens c75ecfb5cb
Start note sentence with a capital 2023-05-19 20:35:39 +02:00
Nicolas Legrand 3ceb9936d7 Remove hebrew niqqud in 8-14 String::from example
Niqqud (hebrew diacrital system to represent vowels) is mainly used in
poetry and in children's book. Israelis do not use niqqud when they
write.
2023-05-17 11:51:43 +02:00
Smeagol 22e4c82ab8
Parity with rustup's help
When `rustup help` is run, it suggests using `rustup doc --book` rather than docs. While docs is a valid alias, I feel that both the book and the help should be the same.
2023-05-09 16:01:32 -04:00
Ham f1877e8db3
update link to doc of syn crate 2023-05-03 18:33:18 +08:00
Ham 12a247444c
Procedure Macro: Update dependencies 2023-05-03 18:24:22 +08:00
Chris Denton d5eb2f7a8e
Update MSVC instructions 2023-04-21 04:28:02 +01:00
Jason Walton 8fa6b854d5 Update copyright in LICENSE-APACHE
Looks like we forgot to fill this in when we added the license file. ;)
2023-04-12 20:05:30 -04:00
Vishal Lama c06006157b Fix grammar
Add the word 'of' to fix the grammar.
2023-04-03 11:31:55 -04:00
Pietro Albini 0510ca84c2 simplify COPYRIGHT file 2023-03-30 09:59:46 -04:00
Petr Pucil 136d1132ed Fix "`test` module" to "`tests` module" in ch11-03
The module is called `tests`, not `test` - see Listing 11-12:

21a2ed14f4/listings/ch11-writing-automated-tests/listing-11-12/src/lib.rs (L9-L10)
2023-03-17 16:38:53 +01:00
David Glasser d454a700b1
Fix em dashes
When reading this section as HTML, these double hyphens stood out to me. It looks like this was introduced last year in #3135. I found other parts of the book where em dashes used standard Unicode em dash characters (rather than some Markdown representation) so I updated these to use them.

(Note that I actually think this would read more clearly if it used parentheses rather than em dashes, but I figured I'd start with the smallest possible suggestion.)
2023-03-10 08:54:28 -08:00
zica dddd193acf
Replace RLS with rust-analyzer in ch00 2023-02-20 20:12:05 +08:00
Mateus Rodolfo 21a2ed14f4 Removed "," typo on ch03-01 line 85
Removed extra comma on line 85.

We’ll cover types and type annotations in the next section, “Data Types`,`”, so don’t worry about the details right now.
2023-02-13 14:45:29 -05:00
Carol (Nichols || Goulding) d94e03a18a
Update to Rust 1.67.1 2023-02-10 11:01:09 -05:00
Carol (Nichols || Goulding) f92027c68a
Update to Rust 1.66.1 2023-02-10 10:55:43 -05:00
Petr Pučil bfdfb30b05
Fix the expected substring in ch11-01
According to Listing 11-9, the substring expected to be included is
"less than or equal to 100" (not "Guess value must be less than or equal
to 100" as written in the book, which is strictly speaking not the
expected substring - it's almost the entire panic message except the
final ", got {}." part). See
f2a78f64b6/listings/ch11-writing-automated-tests/listing-11-09/src/lib.rs (L31):

```rust
    #[should_panic(expected = "less than or equal to 100")]
```

Also I think this was the only place in this chapter / in the book where
I saw a string quotation in inline code additionally surrounded with
single quotes `'`, so I removed them.
2023-02-07 14:06:22 +01:00
Jon Earnshaw bb7aa19d9d Update listings subsequent to listing 11-1 to reflect current content 2023-02-07 04:49:10 +00:00
Jon Earnshaw b2365a3f08 Modify text to better refer to updated listing 11-1 2023-02-07 04:43:38 +00:00
Jon Earnshaw 4ddb4f996b Update Listing 11-1 to reflect current contents 2023-02-07 04:28:22 +00:00
Carol (Nichols || Goulding) f2a78f64b6
Change CamelCase to UpperCamelCase
Brings the terminology in line with the rest of the project, see
<https://github.com/rust-lang/rfcs/pull/2389>.

Connects to #2194.
2023-01-23 13:19:32 -05:00
printfn 4404cbcc35 Fix broken nostarch URL 2023-01-23 10:15:22 -05:00
Anselm Schüler f2bf90ca17 Remove direction to authenticate with `cargo login {API token}` 2023-01-15 01:32:18 +01:00
abiphone 2cd1b5593d rst
restore `value`
2023-01-12 09:47:47 -05:00
abiphone 1c0fd73e4d Typo
Typo, filename is now file_path.
2023-01-12 09:47:47 -05:00
Shangdian (King) Han 0d5ac818bc
Fix incorrect interpretation of compiler error 2023-01-08 01:48:50 +08:00
Theo 2bd5d42c99 fix macos installation problem
when installing rust on macos just copy pasting the command throw an error about curl, on the official rust-lang website the command uses tlsv1.2 and roll backing seems to fix the issue
2022-12-22 16:37:10 -05:00
Arthur Cheek f28554d1b2 Update -guessing-game-tutorial incorrect output
`println!("x = {x} and y + 2 = {}", y + 2);`
"This code would print `x = 5 and y = 12`." is incorrect.
changed to "This code would print `x = 5 and y + 2 = 12`."
2022-12-22 16:36:50 -05:00