def pull_up_bool(argument_table, event_handler, **kwargs):
    # List of tuples of (positive_bool, negative_bool)
    # This is used to validate that we don't specify
    # an --option and a --no-option.
    boolean_pairs = []
    event_handler.register(
        'operation-args-parsed.ec2.*',
        partial(validate_boolean_mutex_groups,
                boolean_pairs=boolean_pairs))
    for key, value in list(argument_table.items()):
        if hasattr(value, 'argument_model'):
            arg_model = value.argument_model
            if _qualifies_for_simplification(arg_model):
                # Swap out the existing CLIArgument for two args:
                # one that supports --option and --option <some value>
                # and another arg of --no-option.
                new_arg = PositiveBooleanArgument(
                    value.name, arg_model, value._operation_model,
                    value._event_emitter,
                    group_name=value.name,
                    serialized_name=value._serialized_name)
                argument_table[value.name] = new_arg
                negative_name = 'no-%s' % value.name
                negative_arg = NegativeBooleanParameter(
                    negative_name, arg_model, value._operation_model,
                    value._event_emitter,
                    action='store_true', dest='no_%s' % new_arg.py_name,
                    group_name=value.name,
                    serialized_name=value._serialized_name)
                argument_table[negative_name] = negative_arg
                # If we've pulled up a structure(scalar) arg
                # into a pair of top level boolean args, we need
                # to validate that a user only provides the argument
                # once.  They can't say --option/--no-option, nor
                # can they say --option --option Value=false.
                boolean_pairs.append((new_arg, negative_arg))
dataset/ETHPy150Open aws/aws-cli/awscli/customizations/toplevelbool.py/pull_up_bool/original