- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I see that the concurrent_unordered_map hews pretty close to std::unordered_map while being safe for concurrency. I also know that unsafe_erase is not concurrent-safe with insert etc. The iterator docs also state that any existing iterators are still valid with insert, find etc.
The question is, does unsafe_erase invalidate any other iterator than the one it is asked to erase?
std::unordered_map and std::map certainly have this behavior, but it's not specified in the concurrent_unordered_map docs anywhere.
Cheers
Glen Low
Pixelglow Software
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
My advice is to add some tests to src/test/test_concurrent_unordered.cpp, submit this as a contribution, and ask to amend the documentation to remove any doubt. (I've had a quick look at the implementation, but it didn't seem obvious.)

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page