T = TypeVar('T') def foo(f: Callable[[int, *Ts, T], Tuple[T, *Ts]]): ...