def METHOD_NAME(args, out):
    if isinstance(args, tuple):
        for arg in args:
            METHOD_NAME(arg, out)
    else:
        # Combine consecutive Ellipsis.
        if args is Ellipsis and out and out[-1] is Ellipsis:
            return
        out.append(args)