def METHOD_NAME(dirs):
    """strip the ignored directories out of the provided list"""
    index = len(dirs) - 1
    for i, d in enumerate(reversed(dirs)):
        if d in dir_ignore:
            del dirs[index - i]