def warn_config_absent(sections, argument, log_printer):
    """
    Checks if the given argument is present somewhere in the sections and emits
    a warning that code analysis can not be run without it.

    :param sections:    A dictionary of sections.
    :param argument:    The argument to check for, e.g. "files".
    :param log_printer: A log printer to emit the warning to.
    """
    if all(argument not in section for section in sections.values()):
        log_printer.warn('coala will not run any analysis. Did you forget '
                         'to give the `--{}` argument?'.format(argument))
        return True

    return False