Lines Matching refs:Flag
10 'Enum', 'IntEnum', 'StrEnum', 'Flag', 'IntFlag', 'ReprEnum',
18 # Dummy value for Enum and Flag as there are explicit checks for them
21 Enum = Flag = EJECT = _stdlib_enums = ReprEnum = None
277 if Flag is not None and issubclass(enum_class, Flag):
300 Flag is None
301 or not issubclass(enum_class, Flag)
306 Flag is not None
307 and issubclass(enum_class, Flag)
548 # Flag structures (will be removed if final class is not a Flag
603 # for Flag, add __or__, __and__, __xor__, and __invert__
604 if Flag is not None and issubclass(enum_class, Flag):
611 enum_method = getattr(Flag, name)
627 # - if enum_class is a Flag:
637 # remove Flag structures if final class is not a Flag
639 Flag is None and cls != 'Flag'
640 or Flag is not None and not issubclass(enum_class, Flag)
647 elif Flag is not None and issubclass(enum_class, Flag):
814 if Flag is not None and issubclass(cls, Flag):
1121 Flag is not None and issubclass(cls, Flag)
1300 "strict" -> error is raised [default for Flag]
1312 class Flag(Enum, boundary=STRICT):
1429 # normal Flag?
1552 class IntFlag(int, ReprEnum, Flag, boundary=KEEP):
1632 if issubclass(cls, Flag):
1680 if issubclass(etype, Flag):
1686 body['__or__'] = Flag.__or__
1687 body['__xor__'] = Flag.__xor__
1688 body['__and__'] = Flag.__and__
1689 body['__ror__'] = Flag.__ror__
1690 body['__rxor__'] = Flag.__rxor__
1691 body['__rand__'] = Flag.__rand__
1692 body['__invert__'] = Flag.__invert__
1718 if issubclass(enum_class, Flag):
1719 # Flag / IntFlag
1825 if Flag is not None and issubclass(enumeration, Flag):
1830 raise TypeError("the 'verify' decorator only works with Enum and Flag")
1896 'invalid Flag %r: %s %s [use enum.show_flag_values(value) for details]'