MCPcopy Index your code
hub / github.com/python/cpython / _get_value

Method _get_value

Lib/enum.py:1607–1612  ·  view source on GitHub ↗
(self, flag)

Source from the content-addressed store, hash-verified

1605 return bool(self._value_)
1606
1607 def _get_value(self, flag):
1608 if isinstance(flag, self.__class__):
1609 return flag._value_
1610 elif self._member_type_ is not object and isinstance(flag, self._member_type_):
1611 return flag
1612 return NotImplemented
1613
1614 def __or__(self, other):
1615 other_value = self._get_value(other)

Callers 4

__or__Method · 0.95
__and__Method · 0.95
__xor__Method · 0.95
__invert__Method · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected