Merge pull request #1553 from josephzxy/fix-typo

fix: fix typo in persistent-stack/drop-arc.md
pull/1569/head
Sunface 2 months ago committed by GitHub
commit f4c520b1fe
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

@ -31,7 +31,7 @@ impl<T> Drop for List<T> {
}
```
这里有一个没见过的方法 `Rc::Try_unwrap` ,该方法会判断当前的 `Rc` 是否只有一个强引用,若是,则返回 `Rc` 持有的值,否则返回一个错误。
这里有一个没见过的方法 `Rc::try_unwrap` ,该方法会判断当前的 `Rc` 是否只有一个强引用,若是,则返回 `Rc` 持有的值,否则返回一个错误。
可以看出,我们会一直 drop 到第一个被其它链表所引用的节点:
```shell

Loading…
Cancel
Save