mirror of https://github.com/astral-sh/ruff
Clarify behavior of `PLW3201` (#6657)
Otherwise it is unclear that violations will be raised for methods like `_foo_`
This commit is contained in:
parent
a8d7bbae6f
commit
82e0a97b34
|
|
@ -7,11 +7,14 @@ use crate::checkers::ast::Checker;
|
||||||
|
|
||||||
/// ## What it does
|
/// ## What it does
|
||||||
/// Checks for any misspelled dunder name method and for any method
|
/// Checks for any misspelled dunder name method and for any method
|
||||||
/// defined with `__...__` that's not one of the pre-defined methods.
|
/// defined with `_..._` that's not one of the pre-defined methods
|
||||||
///
|
///
|
||||||
/// The pre-defined methods encompass all of Python's standard dunder
|
/// The pre-defined methods encompass all of Python's standard dunder
|
||||||
/// methods.
|
/// methods.
|
||||||
///
|
///
|
||||||
|
/// Note this includes all methods starting and ending with at least
|
||||||
|
/// one underscore to detect mistakes.
|
||||||
|
///
|
||||||
/// ## Why is this bad?
|
/// ## Why is this bad?
|
||||||
/// Misspelled dunder name methods may cause your code to not function
|
/// Misspelled dunder name methods may cause your code to not function
|
||||||
/// as expected.
|
/// as expected.
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue