about summary refs log tree commit diff
diff options
context:
space:
mode:
authorSamuel Tardieu <sam@rfc1149.net>2024-11-30 15:57:39 +0100
committerSamuel Tardieu <sam@rfc1149.net>2024-11-30 21:57:16 +0100
commitce9c4f8dd14b8b5b85bf796c26cedbdd517f162f (patch)
treeb4cdefa3b5053f40958f18d58f870d2c537408b6
parent650e0c8d3deeffc38cb7ca3f1eb4c7ac42b46d48 (diff)
downloadrust-ce9c4f8dd14b8b5b85bf796c26cedbdd517f162f.tar.gz
rust-ce9c4f8dd14b8b5b85bf796c26cedbdd517f162f.zip
Mention `string_slice` in `indexing_slicing` documentation
-rw-r--r--clippy_lints/src/indexing_slicing.rs4
1 files changed, 4 insertions, 0 deletions
diff --git a/clippy_lints/src/indexing_slicing.rs b/clippy_lints/src/indexing_slicing.rs
index ae2c3e0491f..15203b35b13 100644
--- a/clippy_lints/src/indexing_slicing.rs
+++ b/clippy_lints/src/indexing_slicing.rs
@@ -51,6 +51,10 @@ declare_clippy_lint! {
     /// There are “checked” alternatives which do not panic, and can be used with `unwrap()` to make
     /// an explicit panic when it is desired.
     ///
+    /// ### Limitations
+    /// This lint does not check for the usage of indexing or slicing on strings. These are covered
+    /// by the more specific `string_slice` lint.
+    ///
     /// ### Example
     /// ```rust,no_run
     /// // Vector