misname-getters: Fix documentation

This commit is contained in:
Sosthène Guédon 2022-11-20 13:46:30 +01:00
parent d9993cb133
commit 6178ddaded

View File

@ -270,6 +270,7 @@
/// It is most likely that such a method is a bug caused by a typo or by copy-pasting.
///
/// ### Example
/// ```rust
/// struct A {
/// a: String,
@ -281,7 +282,7 @@
/// &self.b
/// }
/// }
/// // example code where clippy issues a warning
/// ```
/// Use instead:
/// ```rust
@ -296,7 +297,7 @@
/// }
/// }
/// ```
#[clippy::version = "1.66.0"]
#[clippy::version = "1.67.0"]
pub MISNAMED_GETTERS,
suspicious,
"getter method returning the wrong field"