mirror of https://github.com/astral-sh/ruff
add mapping for lower bound too
This commit is contained in:
parent
f624bfdf63
commit
4bcca58c3a
|
|
@ -1571,6 +1571,8 @@ impl<'db> SpecializationBuilder<'db> {
|
|||
let upper = constraint.upper(self.db);
|
||||
if !upper.is_object() {
|
||||
self.add_type_mapping(typevar, upper, variance, &mut f);
|
||||
} else if !lower.is_never() {
|
||||
self.add_type_mapping(typevar, lower, variance, &mut f);
|
||||
}
|
||||
if let Type::TypeVar(lower_bound_typevar) = lower {
|
||||
self.add_type_mapping(
|
||||
|
|
|
|||
Loading…
Reference in New Issue