Optimize add_children.

I think this change preserves the correctness of the algorithm.
Basically, if there's a diagonal edge in the edit graph, always take it
and don't bother generating the alternatives.