Acknowledgements
Introduction
Who should read this book
About this book
About the code
Online resources
Part I - Fundamentals of Rust
1.
Chapter 1
1.1.
Learning Rust by comparing to Ruby
1.2.
Appreciation for Ruby
1.3.
The Case for Rust
1.4.
Getting Started With Rust
1.4.1.
Installation
1.4.2.
Cargo
1.4.3.
Your first compiled Rust code
1.5.
Summary
2.
Chapter 2
2.1.
New Language, New Syntax
2.2.
Is Rust Object Oriented like Ruby?
2.3.
Type System
2.4.
Scalar Types
2.5.
Numbers
2.6.
Booleans
2.7.
Characters
2.8.
Strings
2.9.
References
2.10.
Summary
3.
Chapter 3
3.1.
Variables
3.2.
Control Flow
3.3.
Options
3.4.
Functions
3.5.
Results
3.6.
Ownership
3.7.
Borrowing
3.8.
Summary
4.
Chapter 4
4.1.
Data Types
4.2.
Tuples
4.3.
Arrays
4.4.
Vectors
4.5.
Keymaps
4.6.
HashSets
4.7.
Summary
5.
Chapter 5
5.1.
Structure Types
5.2.
Structs
5.3.
Enums
5.4.
Generics
5.5.
Lifetimes
5.6.
Summary
6.
Chapter 6
6.1.
Code structure
6.2.
Pattern Matching
6.3.
Traits vs Mixins
6.4.
Summary
7.
Chapter 7
7.1.
Errors
7.2.
Panics
7.3.
Summary
8.
Chapter 8
8.1.
Code helpers
8.2.
Debugging
8.3.
Tests
8.4.
Logging
8.5.
Compiler
8.6.
Summary
9.
Chapter 9
9.1.
Project Structure
9.2.
Modules
9.3.
Libraries
9.4.
Summary
10.
Part 2 - Write a Ruby gem in Rust
10.1.
Wrapping Rust in Ruby
10.2.
Project Setup
10.3.
Parsing URLs
10.4.
Native Code compilation
10.5.
Calling Rust from Ruby
Light
Rust
Coal
Navy
Ayu
From Ruby To Rust
Acknowledgements