Skip to content

Commit 4db1029

Browse files
committed
link to the Box docs in related lint documentation.
1 parent 8b54f1e commit 4db1029

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

clippy_lints/src/types.rs

+3
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@ use crate::utils::{
3737

3838
declare_clippy_lint! {
3939
/// **What it does:** Checks for use of `Box<Vec<_>>` anywhere in the code.
40+
/// Check the [Box documentation](https://doc.rust-lang.org/std/boxed/index.html) for more information.
4041
///
4142
/// **Why is this bad?** `Vec` already keeps its contents in a separate area on
4243
/// the heap. So if you `Box` it, you just add another level of indirection
@@ -65,6 +66,7 @@ declare_clippy_lint! {
6566

6667
declare_clippy_lint! {
6768
/// **What it does:** Checks for use of `Vec<Box<T>>` where T: Sized anywhere in the code.
69+
/// Check the [Box documentation](https://doc.rust-lang.org/std/boxed/index.html) for more information.
6870
///
6971
/// **Why is this bad?** `Vec` already keeps its contents in a separate area on
7072
/// the heap. So if you `Box` its contents, you just add another level of indirection.
@@ -167,6 +169,7 @@ declare_clippy_lint! {
167169

168170
declare_clippy_lint! {
169171
/// **What it does:** Checks for use of `&Box<T>` anywhere in the code.
172+
/// Check the [Box documentation](https://doc.rust-lang.org/std/boxed/index.html) for more information.
170173
///
171174
/// **Why is this bad?** Any `&Box<T>` can also be a `&T`, which is more
172175
/// general.

0 commit comments

Comments
 (0)