logoalt Hacker News

secondcomingyesterday at 4:27 PM0 repliesview on HN

I think it's possible with an atomic<shared_ptr> too (C++20)?

A shared_mutex comes in useful when you can't really have multiple copies of the shared data due to perhaps memory usage, so readers fail to acquire it when the writer is updating it.