2022-12-21 17:36:30 +02:00
|
|
|
# Welcome to Comprehensive Rust 🦀
|
|
|
|
|
|
|
|
This is a four day Rust course developed by the Android team. The course covers
|
|
|
|
the full spectrum of Rust, from basic syntax to advanced topics like generics
|
|
|
|
and error handling. It also includes Android-specific content on the last day.
|
|
|
|
|
2022-12-22 19:33:02 +02:00
|
|
|
The goal of the course is to teach you Rust. We assume you don't know anything
|
2022-12-21 19:20:30 +02:00
|
|
|
about Rust and hope to:
|
2022-12-21 17:36:30 +02:00
|
|
|
|
|
|
|
* Give you a comprehensive understanding of the Rust syntax and language.
|
|
|
|
* Enable you to modify existing programs and write new programs in Rust.
|
|
|
|
* Show you common Rust idioms.
|
|
|
|
|
2022-12-21 19:20:30 +02:00
|
|
|
On Day 4, we will cover Android-specific things such as:
|
2022-12-21 17:36:30 +02:00
|
|
|
|
|
|
|
* Building Android components in Rust.
|
|
|
|
* AIDL servers and clients.
|
|
|
|
* Interoperability with C, C++, and Java.
|
|
|
|
|
|
|
|
## Non-Goals
|
|
|
|
|
2022-12-22 19:33:02 +02:00
|
|
|
Rust is a large language and we won't be able to cover all of it in a few days.
|
2022-12-21 17:36:30 +02:00
|
|
|
Some non-goals of this course are:
|
|
|
|
|
|
|
|
* Learn how to use async Rust --- we'll only talk a bit about async Rust when
|
|
|
|
covering traditional concurrency primitives. Please see [Asynchronous
|
|
|
|
Programming in Rust](https://rust-lang.github.io/async-book/) instead for
|
|
|
|
details on this topic.
|
|
|
|
* Learn how to develop macros, please see [Chapter 19.5 in the Rust
|
|
|
|
Book](https://doc.rust-lang.org/book/ch19-06-macros.html) and [Rust by
|
|
|
|
Example](https://doc.rust-lang.org/rust-by-example/macros.html) instead.
|
|
|
|
* Learn the details of how to write unsafe Rust. We will talk about unsafe Rust
|
2022-12-21 19:58:29 +02:00
|
|
|
on Day 3, but we do not cover the subtle details. Please see [Chapter 19.1 in
|
|
|
|
the Rust Book](https://doc.rust-lang.org/book/ch19-01-unsafe-rust.html) and
|
|
|
|
the [Rustonomicon](https://doc.rust-lang.org/nomicon/) instead.
|
2022-12-21 17:36:30 +02:00
|
|
|
|
|
|
|
## Assumptions
|
|
|
|
|
|
|
|
The course assumes that you already know how to program. Rust is a statically
|
|
|
|
typed language and we will sometimes make comparisons with C and C++ to better
|
|
|
|
explain or contrast the Rust approach.
|
|
|
|
|
|
|
|
If you know how to program in a dynamically typed language such as Python or
|
|
|
|
JavaScript, then you will be able to follow along just fine too.
|