mirror of
https://github.com/astral-sh/ruff.git
synced 2025-09-29 21:35:58 +00:00
[red-knot] Remove an unnecessary branch and a confusing TODO comment (#14915)
This commit is contained in:
parent
0c85023cd9
commit
ef153a0cce
1 changed files with 0 additions and 6 deletions
|
@ -1660,12 +1660,6 @@ impl<'db> Type<'db> {
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
if matches!(self, Type::Unknown | Type::Any | Type::Todo(_)) {
|
|
||||||
// Explicit handling of `Unknown` and `Any` necessary until `type[Unknown]` and
|
|
||||||
// `type[Any]` are not defined as `Todo` anymore.
|
|
||||||
return IterationOutcome::Iterable { element_ty: self };
|
|
||||||
}
|
|
||||||
|
|
||||||
let dunder_iter_result = self.call_dunder(db, "__iter__", &[self]);
|
let dunder_iter_result = self.call_dunder(db, "__iter__", &[self]);
|
||||||
match dunder_iter_result {
|
match dunder_iter_result {
|
||||||
CallDunderResult::CallOutcome(ref call_outcome)
|
CallDunderResult::CallOutcome(ref call_outcome)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue