Sujet : Re: Atomic caching of smart pointers
De : Muttley (at) *nospam* dastardlyhq.com
Groupes : comp.lang.c++Date : 16. Sep 2024, 08:26:44
Autres entêtes
Organisation : A noiseless patient Spider
Message-ID : <vc8mjk$2ni31$1@dont-email.me>
References : 1
On Sun, 15 Sep 2024 21:54:50 +0300
Paavo Helde <
eesnimi@osa.pri.ee> boringly babbled:
So, what do you think? Should I just use std::atomic<std::shared_ptr>
instead? Any other suggestions? Did I get the memory order parameters
right in compare_exchange_weak()?
Looks to me like you're simply protecting the pointers rather than the data
they're actually pointing to but I only skim read it.