# Path: sigtools/_util.py
# def get_funcsigs():
#     def __repr__(self):
# def noop(func):
# def qualname(obj):
#     def __init__(self, *args, **kwargs):
#             def cg(func, **kwargs):
#     def __get__(self, instance, owner):
# def safe_get(obj, instance, owner):
# def iter_call(obj):
# def get_introspectable(obj, forged=True, af_hint=True, partial=True):
# def get_ast(func):
# class _Unset(object):
# class OverrideableDataDesc(object):
# UNSET = _Unset()
# 
# Path: sigtools/signatures.py

# 
# Path: sigtools/specifiers.py
# class _AsForged(object):
# class _ForgerWrapper(object):
#     def __init__(self):
#     def __get__(self, instance, owner):
# def set_signature_forger(obj, forger, emulate=None):
# def _transform(obj, meta):
#     def __init__(self, obj, forger):
#     def _sigtools__forger(self, obj):
#     def __call__(self, *args, **kwargs):
#     def __get__(self, instance, owner):
# def forger_function(func):
#     def _apply_forger(emulate=None, *args, **kwargs):
#         def _applier(obj):
# def forwards(wrapper, wrapped, *args, **kwargs):
# def forwards_to_function(obj, *args, **kwargs):
# def forwards_to_method(obj, wrapped_name, *args, **kwargs):
# def _get_origin_class(obj, cls):
# def forwards_to_super(obj, cls=None, *args, **kwargs):
# def apply_forwards_to_super(num_args=0, named_args=(), *member_names,
#                             **kwargs):
# def _apply_forwards_to_super(member_names, m_args, m_kwargs, cls):


from functools import partial, update_wrapper, wraps
from sigtools import _util, signatures, specifiers
-----------------------------------------------

The functions here help you combine multiple functions into a new callable
which will automatically advertise the correct signature.

"""



class Combination(object):
    """Creates a callable that passes the first argument through each
    callable, using the result of each pass as the argument to the next
    """
    def __init__(self, *functions):
        funcs = self.functions = []
        for function in functions:
            if isinstance(function, Combination):
                funcs.extend(function.functions)
            else:
                funcs.append(function)
        specifiers.set_signature_forger(self, self.get_signature,
                                        emulate=False)

    def __call__(self, arg, *args, **kwargs):
        for function in self.functions:
            arg = function(arg, *args, **kwargs)
        return arg

    def get_signature(self, obj):
        return signatures.merge(

# Path: sigtools/_util.py
# def get_funcsigs():
#     def __repr__(self):
# def noop(func):
# def qualname(obj):
#     def __init__(self, *args, **kwargs):
#             def cg(func, **kwargs):
#     def __get__(self, instance, owner):
# def safe_get(obj, instance, owner):
# def iter_call(obj):
# def get_introspectable(obj, forged=True, af_hint=True, partial=True):
# def get_ast(func):
# class _Unset(object):
# class OverrideableDataDesc(object):
# UNSET = _Unset()
# 
# Path: sigtools/signatures.py

# 
# Path: sigtools/specifiers.py
# class _AsForged(object):
# class _ForgerWrapper(object):
#     def __init__(self):
#     def __get__(self, instance, owner):
# def set_signature_forger(obj, forger, emulate=None):
# def _transform(obj, meta):
#     def __init__(self, obj, forger):
#     def _sigtools__forger(self, obj):
#     def __call__(self, *args, **kwargs):
#     def __get__(self, instance, owner):
# def forger_function(func):
#     def _apply_forger(emulate=None, *args, **kwargs):
#         def _applier(obj):
# def forwards(wrapper, wrapped, *args, **kwargs):
# def forwards_to_function(obj, *args, **kwargs):
# def forwards_to_method(obj, wrapped_name, *args, **kwargs):
# def _get_origin_class(obj, cls):
# def forwards_to_super(obj, cls=None, *args, **kwargs):
# def apply_forwards_to_super(num_args=0, named_args=(), *member_names,
#                             **kwargs):
# def _apply_forwards_to_super(member_names, m_args, m_kwargs, cls):


# Path: sigtools/wrappers.py
from functools import partial, update_wrapper, wraps
from sigtools import _util, signatures, specifiers

-----------------------------------------------

The functions here help you combine multiple functions into a new callable
which will automatically advertise the correct signature.

"""



class Combination(object):
    """Creates a callable that passes the first argument through each
    callable, using the result of each pass as the argument to the next
    """
    def __init__(self, *functions):
        funcs = self.functions = []
        for function in functions:
            if isinstance(function, Combination):
                funcs.extend(function.functions)
            else:
                funcs.append(function)
        specifiers.set_signature_forger(self, self.get_signature,
                                        emulate=False)

    def __call__(self, arg, *args, **kwargs):
        for function in self.functions:
            arg = function(arg, *args, **kwargs)
        return arg

    def get_signature(self, obj):
        return signatures.merge(

            signatures.signature(self),