Review

0x00 Rust Review and Calibration

Rust 知识复习与校准 #

本文档用于复习知识结构、校准内容准确性、并标记待补充知识点。
最后更新:2025-02

一、知识结构总览 #

当前 0x045-Rust 目录覆盖了 The Rust Book 主线 + 部分进阶与生态,结构如下。

1. 基础 (Fundamentals) #

文档内容概要
0x01 Rust overview环境、Cargo、生态(CLI/GUI/后端/WASM)、国内源、文档注释
0x03a Data Types标量(整型/浮点/bool/char)、复合(tuple/array)、字面量
0x03b Functions函数定义、语句与表达式、返回值
0x03c Control Flowifloop/while/for
0x05 Struct结构体定义、字段、方法、关联函数
0x06 Enums and Pattern Matching枚举变体、matchif let、模式

2. 所有权与类型系统 (Core) #

文档内容概要
0x04 Ownership三规则、move、Copy、drop、函数传参
0x04 References and Borrowing引用、借用规则、可变/不可变、切片、data race
0x10a Generic Types, Traits, and Lifetimes泛型 struct/enum/impl、泛型函数
0x10b Traitstrait 定义与实现、trait bounds、多态
0x10c Lifetimes显式生命周期注解、struct/impl、'static、与泛型组合

3. 工程与错误 (Project & Error) #

文档内容概要
0x07 Packages, Crates, and Modulespackage/crate/mod、路径、use、workspace
0x08a Common CollectionsVec 等
0x08b StringString 与 str、UTF-8
0x08c Hash MapHashMap
0x09 Error HandlingResult/Option?unwrap/expectmain 返回 Result

4. 进阶 (Advanced) #

文档内容概要
0x11 Automated Tests测试(未在本次逐字审阅)
0x13a Iterators and Closures闭包、捕获、Fn/FnMut/FnOnce、move
0x13b Iterators惰性、iter/into_iter/iter_mut、map/filter/collect/sum
0x15 Smart PointersBox、Deref、Drop、Rc、RefCell、内部可变性
0x16 Concurrency线程、JoinHandle、move、mpsc、Mutex、Arc
0x10c Lifetimes见上
Macros声明宏 vs 过程宏(简述)
Unsafe Rust五类 unsafe 操作列举

5. 生态与工具 (Overview 中) #

  • CLI:clap、structopt、termion、serde 等
  • GUI:Tauri、Iced、Dioxus、Slint、egui 等
  • 后端:Rocket、Actix、Axum、Pingora 等
  • WASM:wasm-bindgen、wasm-pack

二、校准项(已修正与建议) #

已修正 #

  1. 0x01-Rust overview.md

    ...