mirror of
https://github.com/astral-sh/ruff.git
synced 2025-07-07 21:25:08 +00:00
[flake8-self
] Ignore attribute accesses on instance-like variables (SLF001
) (#16149)
This commit is contained in:
parent
aa88f2dbe5
commit
c814745643
8 changed files with 243 additions and 134 deletions
|
@ -572,7 +572,7 @@ pub trait TypeChecker {
|
|||
/// NOTE: this function doesn't perform more serious type inference, so it won't be able
|
||||
/// to understand if the value gets initialized from a call to a function always returning
|
||||
/// lists. This also implies no interfile analysis.
|
||||
fn check_type<T: TypeChecker>(binding: &Binding, semantic: &SemanticModel) -> bool {
|
||||
pub fn check_type<T: TypeChecker>(binding: &Binding, semantic: &SemanticModel) -> bool {
|
||||
match binding.kind {
|
||||
BindingKind::Assignment => match binding.statement(semantic) {
|
||||
// Given:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue