about summary refs log tree commit diff
diff options
context:
space:
mode:
authorTimo <30553356+y21@users.noreply.github.com>2024-12-23 02:21:16 +0000
committerGitHub <noreply@github.com>2024-12-23 02:21:16 +0000
commit592fd34c1b1dd5e810e3da264c99f9eda6bf1aa9 (patch)
tree35cd2da59506e8dad9aa982c12fded0a2c020b38
parentb3fadd5a8ef45bcd24e9dc31d32926cb7ad26444 (diff)
parent1f8ba334a56455ba19570d75cc3575773a12a469 (diff)
Fix `has_iter_method` documentation (#13867)
changelog: none
-rw-r--r--clippy_utils/src/ty/mod.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/clippy_utils/src/ty/mod.rs b/clippy_utils/src/ty/mod.rs
index 260d1b801e3..670c1661ddc 100644
--- a/clippy_utils/src/ty/mod.rs
+++ b/clippy_utils/src/ty/mod.rs
@@ -171,7 +171,7 @@ pub fn should_call_clone_as_function(cx: &LateContext<'_>, ty: Ty<'_>) -> bool {
     )
 }
 
-/// Returns true if ty has `iter` or `iter_mut` methods
+/// If `ty` is known to have a `iter` or `iter_mut` method, returns a symbol representing the type.
 pub fn has_iter_method(cx: &LateContext<'_>, probably_ref_ty: Ty<'_>) -> Option<Symbol> {
     // FIXME: instead of this hard-coded list, we should check if `<adt>::iter`
     // exists and has the desired signature. Unfortunately FnCtxt is not exported