class Base:
def foo(self): pass
class Mix: pass
class A(Mix, Base): pass
class B(Mix, Base): pass
def foo() -> None:
a = [A(), B()]
reveal_type(a) # Shows Mix
a.foo() # E: "Mix" has no attribute "foo"
Could we do something better here? Ideally the inferred type of a should be an anonymous subclass of Mix and Base.
Could we do something better here? Ideally the inferred type of
ashould be an anonymous subclass ofMixandBase.