def _add_args(compiler, arg_list, arg_cat, arg_type, args_names):
    """Updates arguments list with API specific arguments

    Parameters
    ----------
    arg_list : list of str
        List of arguments to update.
    arg_cat : {'api', 'option'}
        Category of argument.
    arg_type : {'link', 'compile'}
        Type of argument.
    args_names : list of str
        Arguments names to use."""
    if args_names:
        for name in args_names:
            try:
                arg_list.append(compiler[arg_cat][name][arg_type])
            except KeyError:
                continue
