Rust Training by Ferrous Systems
250 pages
English
PDF
4.5

Rust Training by Ferrous Systems

Rust Training by Ferrous Systems

Author:

Year:

Summary:

Introduction

The book "Rust Training by Ferrous Systems" (original title Ferrous Systems Rust Training) is a practical guide to the Rust programming language, developed by the team at Ferrous Systems — a well-known consulting company specializing in the adoption of Rust in industrial projects. Published in 2021, the book is about 250 pages long and presents a structured course that allows you to learn Rust from scratch to a confident level. Unlike many academic textbooks, this material is practice-oriented: each concept is accompanied by code examples, exercises, and explanations based on the authors' real-world experience.

What the book is about

The book covers all key aspects of Rust, starting with the basics of syntax and ending with advanced topics such as safe memory management, ownership, borrowing, lifetimes, generics, traits, error handling, multithreading, and asynchronous programming. Special attention is paid to the unique ownership and borrowing system, which ensures memory safety without a garbage collector. The authors consistently explain how the Rust compiler helps avoid entire classes of errors and how to write efficient, reliable code.

Main sections of the book

  • Introduction to Rust: installation, basic syntax, variables, data types, functions.
  • Ownership and Borrowing: ownership rules, references, mutable and immutable borrows, slice types.
  • Lifetimes: lifetime annotations, elision, structures with lifetimes.
  • Traits and Generics: defining and implementing traits, generic functions and structures, dispatch.
  • Error Handling: panic, Result, Option, combinators, custom error types.
  • Collections and Iterators: Vec, HashMap, String, iterators, adapters, lazy evaluation.
  • Multithreading: threads, mutexes, channels, Send and Sync, atomic operations.
  • Asynchronous Programming: async/await, futures, tokio, async streams.
  • Project Management: Cargo, modules, testing, documentation.

Who this book is for

The book is aimed at beginner and intermediate developers who already have basic programming experience in any imperative language (C, C++, Java, Python, JavaScript) and want to learn Rust. It will also be useful for those who have already tried Rust but want to systematize their knowledge and fill gaps, especially in complex topics such as lifetimes and multithreading. Due to its practical focus, the book is suitable for self-study and can be used as a textbook in courses.

What the reader will learn

  • Understand the philosophy of Rust: safety, speed, concurrency without data races.
  • Learn to manage memory without a garbage collector using the ownership and borrowing system.
  • Master working with lifetimes and learn to write correct annotations.
  • Be able to use traits and generics to create flexible and reusable components.
  • Learn to handle errors idiomatically.
  • Master multithreaded and asynchronous programming in Rust.
  • Gain skills in working with Cargo, the module system, and testing.
  • Be able to read and understand Rust compiler messages, effectively fix errors.
  • Gain confidence for writing real-world projects in Rust.

Strengths of the book

One of the main advantages of the book is its practical focus. Each chapter contains numerous code examples that can be run and experimented with immediately. The authors not only explain the theory but also show how a particular construct works in practice.

Recommendations