summaryrefslogtreecommitdiff
path: root/puzzles/21_literal_enum_name.py
blob: a74316815fc1469224ac9993c2e12e57d9b517bb (plain)
1
2
3
4
5
6
7
8
import enum
from typing import Literal

class Color(enum.Enum):
    Red = enum.auto()
    Blue = enum.auto()

c: Literal[Color.Red] = Color.Blue # error