pub fn assign_generations(nodes: Vec<CommitNode>) -> Vec<CommitNode>Expand description
Assign generation numbers to nodes (which need not be in any order) and
return them sorted by (generation, oid) — parents before children, which is
also the order the reachability pass wants.
Iterative, never recursive: a linear commit history is a chain thousands deep and a recursive walk would blow the stack on a real repository.