From cac45c15d1d77d1c076f9fb6d2e796d76760351b Mon Sep 17 00:00:00 2001 From: Unisko PENG Date: Sat, 6 May 2023 10:12:39 +0800 Subject: [PATCH] Improve Ch15 --- src/Ch15_Smart_Pointers.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Ch15_Smart_Pointers.md b/src/Ch15_Smart_Pointers.md index d21cc97..d491bd7 100644 --- a/src/Ch15_Smart_Pointers.md +++ b/src/Ch15_Smart_Pointers.md @@ -16,7 +16,7 @@ - 用于在内存堆上分配值的 `Box`; - `Rc`,一个引用计数类型,可以实现多重所有权,`Rc`, a reference counting type that enables multiple ownership; -- `Ref` 和 `RefMut`,通过 `RefCell` 访问,该类型在运行时而不是编译时执行借用规则检查,Ref` and `RefMut`, accessed through `RefCell`, a type that enforces the borrowing rules at runtime instead of compile time。 +- `Ref` 和 `RefMut`,通过 `RefCell` 访问,该类型在运行时而不是编译时执行借用规则检查,`Ref` and `RefMut`, accessed through `RefCell`, a type that enforces the borrowing rules at runtime instead of compile time。 此外,咱们还将讨论 *内部可变性,interior mutability* 模式,在这种模式下,不可变的类型会暴露出一个用于改变内部值的 API。我们还将讨论引用循环:他们如何泄漏内存以及如何防止他们。