1
0
mirror of https://github.com/google/comprehensive-rust.git synced 2025-01-09 09:11:50 +02:00
Commit Graph

1898 Commits

Author SHA1 Message Date
Nicole L
025fbffa99
Remove generics from logger exercise (#1899)
The logger exercise comes before the section on generics, and the
purpose of the exercise is for students to get practice writing a trait
implementation, so using generics in the solution is a source of
confusion for students. I've removed the generic and made
`VerbosityFilter` directly hold a `StderrLogger`.
2024-03-11 16:30:38 -04:00
Damiano Ferrari
9059a1aa38
Update fibonacci exercise.rs (#1909) 2024-03-11 14:09:47 +00:00
dependabot[bot]
595ecbcaa7
cargo: bump the minor group with 1 update (#1914)
Bumps the minor group with 1 update:
[http](https://github.com/hyperium/http).

Updates `http` from 1.0.0 to 1.1.0

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-03-11 10:50:44 +00:00
dependabot[bot]
e6b62f465c
cargo: bump the patch group in /src/exercises/bare-metal/rtc with 2 updates (#1913)
Bumps the patch group in /src/exercises/bare-metal/rtc with 2 updates:
[chrono](https://github.com/chronotope/chrono) and
[cc](https://github.com/rust-lang/cc-rs).

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-03-11 10:50:28 +00:00
dependabot[bot]
eb3dd875fb
cargo: bump the patch group in /src/bare-metal/aps/examples with 1 update (#1916)
Bumps the patch group in /src/bare-metal/aps/examples with 1 update:
[cc](https://github.com/rust-lang/cc-rs).

Updates `cc` from 1.0.88 to 1.0.90

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-03-11 10:28:39 +00:00
dependabot[bot]
a265ca3222
cargo: bump the patch group with 4 updates (#1915)
Bumps the patch group with 4 updates:
[clap](https://github.com/clap-rs/clap),
[reqwest](https://github.com/seanmonstar/reqwest),
[cxx](https://github.com/dtolnay/cxx) and
[cxx-build](https://github.com/dtolnay/cxx).

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-03-11 10:28:24 +00:00
dependabot[bot]
dc597531fd
cargo: bump the patch group in /src/bare-metal/microcontrollers/examples with 1 update (#1912)
Bumps the patch group in /src/bare-metal/microcontrollers/examples with
1 update: [nrf52833-hal](https://github.com/nrf-rs/nrf-hal).

Updates `nrf52833-hal` from 0.16.0 to 0.16.1

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-03-11 10:27:03 +00:00
Abhik Banerjee
fa29bcf662
Refreshed Bengali Translations and Added New Translations to Bengali (#1876)
This PR aims to do the following:
1. Refresh the Bengali Translations
2. Add new translations in line with #653 to complete up to 10%.
3. Corrections to existing translations.

Edit: Recent commits bump up the % completed to 12.

---------

Co-authored-by: abhik-bits <127435906+abhik-bits@users.noreply.github.com>
Co-authored-by: Mir Wasi Ahmed <1697945+mirwasi@users.noreply.github.com>
2024-03-07 19:14:49 +00:00
Aaron M
3ac3b301bc
Fix typo in associated-types.md (#1887)
A minor nitpick, but as someone new to the language I did spend a bit
more time than I'd like to admit trying to understand the meaning of
`allow` before realizing this is likely a typo. Maybe I still don't
understand, and in that case I'd appreciate a correction!
2024-03-07 13:56:30 +00:00
Max Heller
97ac0e7caf
set fallback fonts for PDF rendering (#1728)
Once a new version of Pandoc is released that includes
https://github.com/jgm/pandoc/pull/9204 and
https://github.com/jgm/pandoc/pull/9353 (both merged), this will fix the
emoji and symbol rendering issues in #1708.

It doesn't seem to be possible to set fallback fonts with
`luatexja-fontspec` (used to configure CJK fonts), which results in some
missing symbols in the translations but at least renders the emoji
properly.

Closes #1708
2024-03-07 14:37:52 +01:00
Frances Wingerter
e362b44b66
concurrency: Update async trait slide (#1883)
Clarify that the basics are stable, but dyn support is still missing.
This slide was outdated and didn't explain the current state of stable
correctly.
2024-03-06 16:37:48 -05:00
Frances Wingerter
42f6e1186e
Do not show trait vtables as located in the heap in memory diagram (#1882)
This diagram is misleading and I often explain that the character data
of string literals resides in the executable's static data, with vtables
working the same.
2024-03-06 16:22:16 -05:00
Frances Wingerter
976f6f6f24
concurrency: Add detailed teaching notes for welcome and threads slides (#1885)
These follow the flow of what I actually teach, which spends a
significant amount of time on the latter slide. I think it's worthwhile
to have a real flow documented in the teaching notes, both to make sure
nothing gets forgotten and to structure the experience of teaching.
2024-03-06 21:11:52 +00:00
Frances Wingerter
429694fa63
Tweak solution to iter exercise (#1884)
Because `.zip()` is limited to the shorter length, the `.take()` call
here is unnecessary. When explaining this solution I don't want to have
to explain a call to a method that, used as it is, does nothing.
2024-03-06 20:18:31 +00:00
Martin Geisler
c866c13b68
Retire @duyguisler as a Turkish reviewer (#1880)
Thanks for the work so far, feel free to come back if you have more
time!
2024-03-06 17:04:53 +00:00
Yuri Astrakhan
9404a22b15
Make diagram consistent with code (#1855) 2024-03-06 17:12:09 +01:00
Manichand Kondapaka
f00981c663
Divided Array and tuples (#1859)
#1824 PR Changes
2024-03-06 09:24:01 -05:00
Enes Aydın
a1dc31b9d7
tr: cr2 update changes (#1865)
updated for cr2 and added some translations

Part of #500
2024-03-06 13:50:53 +01:00
Henri F
437b73b24f
es: Merge CR v.2 Spanish translation back into main (#1879)
This PR merges the Spanish (es) v.2 translation back to main.
This requires just a syntactical review, as the partial PRs into this
branch were reviewed already.

You can skim this PR with the [GitHub CLI](https://cli.github.com/):

gh pr diff 1879 | bat -l patch

#1463 #284

---------

Co-authored-by: David Martínez Martí <deavid@google.com>
2024-03-05 14:38:58 -08:00
geekvest
13cf920e08
Fix some typos (#1864)
Signed-off-by: geekvest <cuimoman@sohu.com>
2024-03-05 16:28:55 -05:00
dependabot[bot]
259a8ac08e
cargo: bump mio from 0.8.10 to 0.8.11 (#1877)
Bumps [mio](https://github.com/tokio-rs/mio) from 0.8.10 to 0.8.11.
2024-03-05 11:53:17 +01:00
Manichand Kondapaka
0761f936ca
Add a dev theme to help with slide aspect ratio (#1842)
Added a dev theme to help with slide aspect ratio while updating content
or for reviewing PRs.

Fixes #1796.

---------

Co-authored-by: Dustin J. Mitchell <djmitche@google.com>
Co-authored-by: Martin Geisler <martin@geisler.net>
2024-03-05 10:33:42 +00:00
Martin Geisler
c509dbd9e4
Always install and run mdbook-pandoc (#1713)
Before, we only installed and ran `mdbook-pandoc` when publishing the
course — which means that a PR change could accidentally break the
publish workflow. We now test that it works on every PR.

From a discussion in #1704.
2024-03-04 16:25:58 +01:00
Martin Geisler
1b3984df20
Move Mockall and GoogleTest slides to Android section (#1533)
After #1528 and #1532, we now have actual slides which showcase the
crates in action. So we can reclaim a few minutes by removing the slide
which mentions Mockall and GoogleTest slide.

The slide mentioned [proptest](https://docs.rs/proptest) and
[rstest](https://docs.rs/rstest) as well. While I'm sure the libraries
are useful, we don't have them imported into AOSP and I've never
personally used them. We should therefore not advertise them yet at this
point since they won't be useful to Android engineers.

Of course we can mention things that are not in AOSP (or in Chromium),
but I think we should do it in the speaker notes at most.
2024-03-04 16:25:35 +01:00
Gergely Risko
c763932288
Small formatting fix (#1866)
This is a typo, that actually @mgeisler stopped in my previous PR, I was
just not around to fix it fast enough to make it to the previous merge.
Thanks for the catch!
2024-03-04 09:46:59 -05:00
Gergely Risko
e74a8b77bd
URGENT: Fix course schedule watcher github action (#1867)
@djmitche Currently all PRs are marked as schedule change PRs.

This is my try to propose a fix for this, but please review diligently,
I'm no github actions expert, and I don't have an environment to test.
2024-03-04 09:39:30 -05:00
dependabot[bot]
9a72b87fa9
cargo: bump the minor group with 2 updates (#1870)
Bumps the minor group with 2 updates:
[scraper](https://github.com/causal-agent/scraper) and
[tokio-websockets](https://github.com/Gelbpunkt/tokio-websockets).

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-03-04 11:37:43 +00:00
dependabot[bot]
e2c38d106e
cargo: bump the patch group in /src/exercises/bare-metal/rtc with 1 update (#1874)
Bumps the patch group in /src/exercises/bare-metal/rtc with 1 update:
[log](https://github.com/rust-lang/log).

Updates `log` from 0.4.20 to 0.4.21

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-03-04 11:00:43 +00:00
dependabot[bot]
1e6fa1cb49
cargo: bump the patch group with 4 updates (#1873)
Bumps the patch group with 4 updates:
[log](https://github.com/rust-lang/log),
[tempfile](https://github.com/Stebalien/tempfile),
[cxx](https://github.com/dtolnay/cxx) and
[cxx-build](https://github.com/dtolnay/cxx).

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-03-04 10:55:27 +00:00
dependabot[bot]
2bed943920
build(deps): bump crate-ci/typos from 1.18.2 to 1.19.0 (#1872)
Bumps [crate-ci/typos](https://github.com/crate-ci/typos) from 1.18.2 to
1.19.0.

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-03-04 10:54:38 +00:00
dependabot[bot]
64e3a88d80
cargo: bump the patch group in /src/bare-metal/aps/examples with 1 update (#1871)
Bumps the patch group in /src/bare-metal/aps/examples with 1 update:
[log](https://github.com/rust-lang/log).

Updates `log` from 0.4.20 to 0.4.21

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-03-04 10:54:04 +00:00
Dustin J. Mitchell
adff70d025
Update course-schedule PR comments in-place (#1856)
Instead of always adding a new comment, just update the existing comment
if one exists.

This fixes #1834.
2024-02-29 10:51:37 -05:00
Nicole L
c1e605df25
Rework introduction of pattern matching (#1843) 2024-02-28 11:14:53 -08:00
Martin Geisler
9b57c48615
Sort mdbook redirects (#1761)
There were a few comments, but I think it’s better to make it all
uniform and avoid these comments. The comment was about the v2 rewrite,
but this is now done and so the comment is less useful.

I also normalized the quotes to double-quotes instead of single-quotes.
The latter is a literal string in TOML, but we don’t actually have any
special characters to escape here.
2024-02-27 17:20:41 +00:00
Martin Geisler
dc4a1eb53b
Skip translation of large bare-metal code blocks (#1853)
This was done a bit inconsistently before. We now skip all of these
large blocks which are meant to be used as-is by the students.

This removes 700 lines from the PO files. I found this during the review
of #1651.
2024-02-27 16:53:05 +01:00
Max Heller
3e7ce5e6ee
Link to PDF version of course from first page (#1836)
Re
https://github.com/google/comprehensive-rust/pull/1805#pullrequestreview-1888804528

---------

Co-authored-by: Martin Geisler <martin@geisler.net>
2024-02-26 13:24:28 +01:00
Andriy Redko
926a5c6fd0
uk: Day 3: afternoon (#1849)
uk: Day 3: afternoon

Signed-off-by: Andriy Redko <drreta@gmail.com>
2024-02-26 12:01:00 +00:00
dependabot[bot]
afe9814ef0
cargo: bump the patch group in /src/exercises/bare-metal/rtc with 1 update (#1852)
Bumps the patch group in /src/exercises/bare-metal/rtc with 1 update:
[cc](https://github.com/rust-lang/cc-rs).

Updates `cc` from 1.0.83 to 1.0.88

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-02-26 10:51:48 +00:00
dependabot[bot]
a5d86d36df
cargo: bump the patch group in /src/bare-metal/aps/examples with 1 update (#1851)
Bumps the patch group in /src/bare-metal/aps/examples with 1 update:
[cc](https://github.com/rust-lang/cc-rs).

Updates `cc` from 1.0.83 to 1.0.88

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-02-26 10:51:06 +00:00
dependabot[bot]
cbcf599588
cargo: bump the patch group with 6 updates (#1850)
Bumps the patch group with 6 updates

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-02-26 10:50:09 +00:00
Adrian Taylor
3afdabf391
Update cargo.md to fix typos (#1848) 2024-02-23 11:18:04 -08:00
Nicole L
5ecdddf9c8
Remove tangential text from if slide (#1840) 2024-02-23 08:53:26 -08:00
Martin Geisler
099ca497f2
Fix typo in cargo.md (#1847) 2024-02-23 14:15:58 +00:00
Henri F
847e1a038e
Fix definition of Rust Fundamentals in glossary.md (#1844)
Small nitpick: Days 1 to **4** are Rust Fundamentals
2024-02-23 10:06:44 +01:00
Henri F
6a7fd259a3
pt-BR: Merge CR v.2 pt-BR translation back into main (#1846)
This PR merges the pt-BR v.2 translation back to main.
Also, it refreshes the .po file format removing the line numbers.
This requires just a syntactical review, as the partial PRs into this
branch were reviewed already.

You can skim this PR with the [GitHub CLI](https://cli.github.com/):

gh pr diff 1846 | bat -l patch

#317 #1463

---------

Co-authored-by: João Victor Mendes <mendesjoaovic@gmail.com>
Co-authored-by: azevedoalice <158203674+azevedoalice@users.noreply.github.com>
2024-02-23 09:56:53 +01:00
Nicole L
d75dd5d681
Flesh out for loop example (#1841)
* Add example of iterating over a collection.
* Update speaker notes to call out the use of iterators.

I think it's useful to call out that `for` loops primarily are used to
iterate over a collection of objects, even though we haven't yet talked
about any concrete collection types at this point. I think using the
array literal syntax is simple enough to understand that it should be
quick to explain when we get to this slide.
2024-02-22 10:49:49 -05:00
Nicole L
9023dd9caa
Tweak timings of exercises to better reflect teaching times (#1839)
A few of the early exercises had much larger estimates than were
actually necessary for the super simple early exercises. I've gone
through and reviewed the time estimates for exercises and tweaked the
estimates based on how much time students have actually needed in my
classes so far.
2024-02-22 10:21:39 -05:00
Martin Geisler
8670d2f9d9
Add translation comment to glossary (#1831)
With https://github.com/google/mdbook-i18n-helpers/pull/107 merged, we
can begin adding comments for the translators to our Markdown files.
2024-02-22 15:10:01 +01:00
Nicole L
e7076af00f
Move hello world example to second section (#1838)
The current location for the hello world example is awkward since the
two surrounding pages are both talking about Rust from a high level
without talking about syntax at all. I think starting the second section
(types and values) with the hello world example would help the first
section flow more smoothly.
2024-02-21 16:54:11 -05:00
Michael Graf
7fb4ad9ed2
Update user-defined-types/exercise.md (#1835)
Allow us to edit so we can complete the exercise :)
2024-02-20 22:08:39 +00:00