This lets us use range based for loops, and generally makes the interface much closer to
normal pred iterators.
Details
Diff Detail
Event Timeline
Looks reasonable.
Optional: Rather than having range access as a free function and begin/end as member functions, I'd be inclined to put them at the same level, or possibly even go without begin/end entirely and just have:
PredCache.predecessors(BB);
(or s/predecessors/cached_predecessors/ - though of course both names are somewhat redundant with the name of the object... - maybe it should just be PredCache.get(BB); or something? )
The redundancy is why i made it a free function, but happy to make it
a member function.
The liklihood we would ever have cached_predecessors(something else) seems low.
:)
I don't see any loops that use begin()/end(), so i'll delete them for now.
I'll make cached_predecessors a member function named get, and if we
find a use for begin/end later, we can add them then.