
Andrew Sutton-2 wrote:
I'm wondering if the documentation is incorrect. Perhaps it is just imprecise, and removing any edge from the source vertex of an adjacency_iterator invalidates that iterator?
Anyone with additional insight would be very helpful.
That behavior should actually be correct since an adjacency iterator is just a wrapper around an out edge iterator. I haven't looked at the documentation on adjacency iterator invalidation, so it the docs may be incorrect.
That makes things a bit clearer. However, in the code I provided, I'm incrementing the adjacency_iterator prior to deleting the out edge to which it corresponds. My assumption was that (when using listS) deletion of an out edge would invalidate an out_edge iterator or an edge descriptor if and only if the iterator or descriptor were pointing to the deleted element at the time of its deletion. It seems, however, that deletion of any out edge invalidates the iterator. Is that truly the case, or have I made a mistake? If it is the case, can anyone explain why that limitation is required? -- View this message in context: http://old.nabble.com/-BGL--adjacency_iterator-invalidation-with-adjacency_l... Sent from the Boost - Users mailing list archive at Nabble.com.