diff --git a/crates/ruff_linter/src/rules/pylint/rules/comparison_with_itself.rs b/crates/ruff_linter/src/rules/pylint/rules/comparison_with_itself.rs index 9c38b10839af0..79f80ba26225b 100644 --- a/crates/ruff_linter/src/rules/pylint/rules/comparison_with_itself.rs +++ b/crates/ruff_linter/src/rules/pylint/rules/comparison_with_itself.rs @@ -12,8 +12,8 @@ use crate::fix::snippet::SourceCodeSnippet; /// Checks for operations that compare a name to itself. /// /// ## Why is this bad? -/// Comparing a name to itself always results in the same value, and is likely -/// a mistake. +/// Comparing a name to itself is likely a mistake, as `__eq__` may be +/// overridden to return a non-trivial value. /// /// ## Example /// ```python