def requires(*parent_predicates):
    """
    Decorate a predicate to say it requires other predicates to be True first.

    :param parent_predicates: A list of predicates that have to be true for
    this predicate to be true as well.
    """

    def decorator(function):
        function.requires = parent_predicates
        return function

    return decorator