Or bindings to a C graph library? I'm trying NOT to have to write an entire set of bindings for igraph (I hate writing bindings). A nimble search graphdoesn't show anything useful.
I had a decent one using optimized sparse bitsets but lost the code. True story. ;-) That said, the sparse bit setmade it into the stdlib and might be a solid foundation. Depends completely of what you mean by "graph"of course.