Skip to content

Commit

Permalink
Fix has_iter_method documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
samueltardieu committed Dec 22, 2024
1 parent b3fadd5 commit 1f8ba33
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion clippy_utils/src/ty/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down

0 comments on commit 1f8ba33

Please sign in to comment.