From 04616a672be7db005a653a21e19e6dade9131c49 Mon Sep 17 00:00:00 2001 From: Yuki Okushi Date: Sat, 19 Jun 2021 12:20:59 +0900 Subject: [PATCH] Move Vec chapters into the subdir --- book.toml | 15 +++++++++++++++ src/SUMMARY.md | 24 ++++++++++++------------ src/{ => vec}/vec-alloc.md | 0 src/{ => vec}/vec-dealloc.md | 0 src/{ => vec}/vec-deref.md | 0 src/{ => vec}/vec-drain.md | 0 src/{ => vec}/vec-final.md | 0 src/{ => vec}/vec-insert-remove.md | 0 src/{ => vec}/vec-into-iter.md | 0 src/{ => vec}/vec-layout.md | 0 src/{ => vec}/vec-push-pop.md | 0 src/{ => vec}/vec-raw.md | 0 src/{ => vec}/vec-zsts.md | 0 src/{ => vec}/vec.md | 0 14 files changed, 27 insertions(+), 12 deletions(-) rename src/{ => vec}/vec-alloc.md (100%) rename src/{ => vec}/vec-dealloc.md (100%) rename src/{ => vec}/vec-deref.md (100%) rename src/{ => vec}/vec-drain.md (100%) rename src/{ => vec}/vec-final.md (100%) rename src/{ => vec}/vec-insert-remove.md (100%) rename src/{ => vec}/vec-into-iter.md (100%) rename src/{ => vec}/vec-layout.md (100%) rename src/{ => vec}/vec-push-pop.md (100%) rename src/{ => vec}/vec-raw.md (100%) rename src/{ => vec}/vec-zsts.md (100%) rename src/{ => vec}/vec.md (100%) diff --git a/book.toml b/book.toml index fa3715f..85f443a 100644 --- a/book.toml +++ b/book.toml @@ -6,5 +6,20 @@ description = "The Dark Arts of Advanced and Unsafe Rust Programming" [output.html] git-repository-url = "https://github.com/rust-lang/nomicon" +[output.html.redirect] +# Vec-related chapters. +"/vec-alloc.html" = "/vec/vec-alloc.html" +"/vec-dealloc.html" = "/vec/vec-dealloc.html" +"/vec-deref.html" = "/vec/vec-deref.html" +"/vec-drain.html" = "/vec/vec-drain.html" +"/vec-final.html" = "/vec/vec-final.html" +"/vec-insert-remove.html" = "/vec/vec-insert-remove.html" +"/vec-into-iter.html" = "/vec/vec-into-iter.html" +"/vec-layout.html" = "/vec/vec-layout.html" +"/vec-push-pop.html" = "/vec/vec-push-pop.html" +"/vec-raw.html" = "/vec/vec-raw.html" +"/vec-zsts.html" = "/vec/vec-zsts.html" +"/vec.html" = "/vec/vec.html" + [rust] edition = "2018" diff --git a/src/SUMMARY.md b/src/SUMMARY.md index 72f92f4..34b1405 100644 --- a/src/SUMMARY.md +++ b/src/SUMMARY.md @@ -42,18 +42,18 @@ * [Races](races.md) * [Send and Sync](send-and-sync.md) * [Atomics](atomics.md) -* [Implementing Vec](vec.md) - * [Layout](vec-layout.md) - * [Allocating](vec-alloc.md) - * [Push and Pop](vec-push-pop.md) - * [Deallocating](vec-dealloc.md) - * [Deref](vec-deref.md) - * [Insert and Remove](vec-insert-remove.md) - * [IntoIter](vec-into-iter.md) - * [RawVec](vec-raw.md) - * [Drain](vec-drain.md) - * [Handling Zero-Sized Types](vec-zsts.md) - * [Final Code](vec-final.md) +* [Implementing Vec](./vec/vec.md) + * [Layout](./vec/vec-layout.md) + * [Allocating](./vec/vec-alloc.md) + * [Push and Pop](./vec/vec-push-pop.md) + * [Deallocating](./vec/vec-dealloc.md) + * [Deref](./vec/vec-deref.md) + * [Insert and Remove](./vec/vec-insert-remove.md) + * [IntoIter](./vec/vec-into-iter.md) + * [RawVec](./vec/vec-raw.md) + * [Drain](./vec/vec-drain.md) + * [Handling Zero-Sized Types](./vec/vec-zsts.md) + * [Final Code](./vec/vec-final.md) * [Implementing Arc and Mutex](arc-and-mutex.md) * [Arc](arc.md) * [Layout](arc-layout.md) diff --git a/src/vec-alloc.md b/src/vec/vec-alloc.md similarity index 100% rename from src/vec-alloc.md rename to src/vec/vec-alloc.md diff --git a/src/vec-dealloc.md b/src/vec/vec-dealloc.md similarity index 100% rename from src/vec-dealloc.md rename to src/vec/vec-dealloc.md diff --git a/src/vec-deref.md b/src/vec/vec-deref.md similarity index 100% rename from src/vec-deref.md rename to src/vec/vec-deref.md diff --git a/src/vec-drain.md b/src/vec/vec-drain.md similarity index 100% rename from src/vec-drain.md rename to src/vec/vec-drain.md diff --git a/src/vec-final.md b/src/vec/vec-final.md similarity index 100% rename from src/vec-final.md rename to src/vec/vec-final.md diff --git a/src/vec-insert-remove.md b/src/vec/vec-insert-remove.md similarity index 100% rename from src/vec-insert-remove.md rename to src/vec/vec-insert-remove.md diff --git a/src/vec-into-iter.md b/src/vec/vec-into-iter.md similarity index 100% rename from src/vec-into-iter.md rename to src/vec/vec-into-iter.md diff --git a/src/vec-layout.md b/src/vec/vec-layout.md similarity index 100% rename from src/vec-layout.md rename to src/vec/vec-layout.md diff --git a/src/vec-push-pop.md b/src/vec/vec-push-pop.md similarity index 100% rename from src/vec-push-pop.md rename to src/vec/vec-push-pop.md diff --git a/src/vec-raw.md b/src/vec/vec-raw.md similarity index 100% rename from src/vec-raw.md rename to src/vec/vec-raw.md diff --git a/src/vec-zsts.md b/src/vec/vec-zsts.md similarity index 100% rename from src/vec-zsts.md rename to src/vec/vec-zsts.md diff --git a/src/vec.md b/src/vec/vec.md similarity index 100% rename from src/vec.md rename to src/vec/vec.md