def phase_dependent(meth):
    """
    Decorator to mark the method as requiring the current
    transaction phase as its first argument.

    These are methods that can only be called after ``tpc_begin``
    and delegate to the ``tpc_phase`` object.
    """
    meth.phase_dependent = True
    return meth
