Closed
Description
This code:
from typing import NamedTuple
from enum import Enum
Foo = NamedTuple('Foo', [('bar', int)])
class MyEnum(Foo, Enum):
CONSTANT = Foo(bar=1)
def f(x):
# type: (MyEnum) -> None
pass
f(MyEnum.CONSTANT)
leads to:
error: Argument 1 to "f" has incompatible type "test.MyEnum"; expected "MyEnum"