Use visitors to avoid allocating slices to hold nodes during traversal (and to allow short-circuiting)
Benchmarked at 95% space savings traversing nodes with many edges.
Implements graph.Directed capable of storing at most one edge between any two nodes.
Uses the Undirected implementation for space efficiency (~30% space savings).