Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
def __new__(cls, types: Iterable):
return tuple.__new__(cls, map(subtype, types))
def __eq__(self, other):
return isinstance(other, subtype) and self.__getstate__() == other.__getstate__()
def get_type(arg: Iterable):
"""Return generic type checking first value."""
return subtype(type(arg), *map(get_type, itertools.islice(arg, 1)))