'Iterate over the *nodes* in topological order (ignoring back edges).
The sort isn\'t guaranteed to be stable.'

def topo_sort(self, nodes, reverse=False):

    nodes = set(nodes)
    it = self._topo_order
    if reverse:
        it = reversed(it)
    for n in it:
        if (n in nodes):
            (yield n)
